Announcement: Be excellent to each other.


Caravel Forum : DROD Boards : Bugs : TSS 5.1.1 (Beta binary available for testing)
12
Page 3 of 3
New Topic New Poll Post Reply
Poster Message
bbb
Level: Master Delver
Rank Points: 175
Registered: 10-07-2013
IP: Logged
icon Re: TSS 5.1.1 (0)  
Thanks.

There are actually 4 types of png files. Grayscale, RGB, RGBA, and palette. RGB being 24 bit color but no alpha channel. An alpha channel can be created in these images by choosing some color to be transparent. From some debugging I tried, it seems that some of the loaded images are RGB and not RGBA, and couldn't find any place where the trans_values varaible was set.

I'll try to look at it later.

[Last edited by bbb at 11-25-2020 04:35 PM]
11-25-2020 at 04:35 PM
View Profile Send Private Message to User Show all user's posts High Scores Quote Reply
mrimer
Level: Legendary Smitemaster
Avatar
Rank Points: 4729
Registered: 02-04-2003
IP: Logged
icon Re: TSS 5.1.1 (0)  
bbb wrote:
From some debugging I tried, it seems that some of the loaded images are RGB and not RGBA, and couldn't find any place where the trans_values varaible was set.
I recall tripping over that issue at some points in the past (edit: probably when getting things to work with SDL2 for Steam). Adding the alpha channel to these images was how I corrected this issue.

(Hmm...if there are still PNGs without an alpha channel, I'm not sure how this has been working on Windows and in Steam builds up to this point.)

If it makes sense and is possible, feel free to add code to implicitly convert loaded RGB PNGs to RGBA.

I'm unsure whether that might cause other issues in various in-game transparency handling. If it does, a fallback option is to provide the list of PNG images that don't have an alpha channel and I'll correct all of these in the canonical repo.

____________________________
Gandalf? Yes... That's what they used to call me.
Gandalf the Grey. That was my name.
I am Gandalf the White.
And I come back to you now at the turn of the tide.

[Last edited by mrimer at 11-25-2020 07:06 PM]
11-25-2020 at 06:22 PM
View Profile Send Private Message to User Send Email to User Show all user's posts High Scores This architect's holds Quote Reply
bbb
Level: Master Delver
Rank Points: 175
Registered: 10-07-2013
IP: Logged
icon Re: TSS 5.1.1 (+1)  
I think my data file is from an old demo. That could be the problem.

It would still be a good idea to try to fix it, because you don't control all PNGs which can be used with the game. I'll try some more.

The SDL version moved to SDL2 since my active compiled version.

[Last edited by bbb at 11-25-2020 07:06 PM]
11-25-2020 at 06:50 PM
View Profile Send Private Message to User Show all user's posts High Scores Quote Reply
mrimer
Level: Legendary Smitemaster
Avatar
Rank Points: 4729
Registered: 02-04-2003
IP: Logged
icon Re: TSS 5.1.1 (0)  
bbb wrote:
I think my data file is from an old demo. That could be the problem.
Ah, gotcha. Then it's possible there isn't any code regression in play here. If you can reproduce the issue with current published 1.2.7+ data files, please share.

____________________________
Gandalf? Yes... That's what they used to call me.
Gandalf the Grey. That was my name.
I am Gandalf the White.
And I come back to you now at the turn of the tide.

[Last edited by mrimer at 11-25-2020 07:08 PM]
11-25-2020 at 07:08 PM
View Profile Send Private Message to User Send Email to User Show all user's posts High Scores This architect's holds Quote Reply
bbb
Level: Master Delver
Rank Points: 175
Registered: 10-07-2013
IP: Logged
icon Re: TSS 5.1.1 (0)  
Is it possible to download the data files without downloading and installing the demo?

Is there a reason the code for reading the PNG images is mixed with the code for creating the surface?

[Last edited by bbb at 11-25-2020 08:14 PM]
11-25-2020 at 07:40 PM
View Profile Send Private Message to User Show all user's posts High Scores Quote Reply
mrimer
Level: Legendary Smitemaster
Avatar
Rank Points: 4729
Registered: 02-04-2003
IP: Logged
icon Re: TSS 5.1.1 (+1)  
bbb wrote:
Is it possible to download the data files without downloading and installing the demo?
No, sorry.
Is there a reason the code for reading the PNG images is mixed with the code for creating the surface?
IIRC, this functionality was implemented by Trick once upon a time, and I don't recall what the design decisions were for the implementation. However, I don't really understand what reading a PNG image would mean outside of the context of putting it into a surface. Where else would the image be placed?

____________________________
Gandalf? Yes... That's what they used to call me.
Gandalf the Grey. That was my name.
I am Gandalf the White.
And I come back to you now at the turn of the tide.
11-25-2020 at 11:40 PM
View Profile Send Private Message to User Send Email to User Show all user's posts High Scores This architect's holds Quote Reply
kieranmillar
Level: Smitemaster
Rank Points: 2273
Registered: 07-11-2014
IP: Logged
icon Re: TSS 5.1.1 (0)  
mrimer wrote:
kieranmillar wrote:
SDL2.dll and SDL2_ttf.dll are missing from the installer and DROD will not run. Previous stable version uses SDL1 (I think Steam always uses SDL2, am surprised the non-Steam version did not until now).
Thanks for reporting this.

Here is an updated installer including all the .dll files, plus the newest fixes.
Can we try another patch based on whatever the latest codebase is? I haven't been able to verify any changes since the move to SDL2 because of patch installer problems and nobody else is doing it, it would be a shame for development to stall out now given how close we are.
12-10-2020 at 06:20 PM
View Profile Send Private Message to User Show all user's posts High Scores This architect's holds Quote Reply
mrimer
Level: Legendary Smitemaster
Avatar
Rank Points: 4729
Registered: 02-04-2003
IP: Logged

File: drod.5.1.1.beta.2020-12-14.zip (2.7 MB)
Downloaded 9 times.
License: Public Domain
icon Re: TSS 5.1.1 (0)  
Yes, of course. Thank you! Here's a new simple zipped patch with all merged changes (up to PR #371).

Edit: I think skell's taking some time away from DROD development for a bit. I'm unsure of the status on overall 5.1.1 demo validation, but when he's back, I expect we'll make the final push to get 5.1.1 out the door.

____________________________
Gandalf? Yes... That's what they used to call me.
Gandalf the Grey. That was my name.
I am Gandalf the White.
And I come back to you now at the turn of the tide.

[Last edited by mrimer at 12-14-2020 01:45 PM]
12-14-2020 at 01:43 PM
View Profile Send Private Message to User Send Email to User Show all user's posts High Scores This architect's holds Quote Reply
12
Page 3 of 3
New Topic New Poll Post Reply
Caravel Forum : DROD Boards : Bugs : TSS 5.1.1 (Beta binary available for testing)
Surf To:


Forum Rules:
Can I post a new topic? No
Can I reply? No
Can I read? Yes
HTML Enabled? No
UBBC Enabled? Yes
Words Filter Enable? No

Contact Us | CaravelGames.com

Powered by: tForum tForumHacks Edition b0.98.8
Originally created by Toan Huynh (Copyright © 2000)
Enhanced by the tForumHacks team and the Caravel team.