[0.4.5]user defined art transparency issues

Moderator: Raze Developers

Forum rules
Please don't bump threads here if you have a problem - it will often be forgotten about if you do. Instead, make a new thread here.
Post Reply
User avatar
Photonic
Posts: 25
Joined: Sat Feb 08, 2020 3:34 pm

[0.4.5]user defined art transparency issues

Post by Photonic »

One of eduke32s very useful modding features is the ability to define new game images without .art files using the def command tilefromtexture.
In raze the art loaded this way behaves different and has a transparency glitch where although you can see through, sprites disappear behind these transparent pixels. Same for indexed or RGB .png files, oddly loading .bmp files this way show me the ugly pink pixels instead of any transparency at all.

debug map, and duke3d.def with 1 png, 1 bmp. the map consists of the same image (a broken glass texture) placed around but using the three different methods of loading, (from .art, from tiletotexture both bmp and png)
transparency-debug-1.zip
(4.46 KiB) Downloaded 46 times
Duke_0001.png
To test unzip contents into duke folder and run "raze.exe -map newboard.map"

added: To be clear, the behaviour of .bmp files with pink drawing is the same in eduke32, I just thought it was worth mentioning. The alpha for .pngs are behaving diferent here.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49053
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [0.4.5]user defined art transparency issues

Post by Graf Zahl »

BMPs have no transparent color so that part is hardly surprising.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49053
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [0.4.5]user defined art transparency issues

Post by Graf Zahl »

So what's wrong here? The transparent parts of the PNG allow everything to be seen that's behind and the BMP, having no transparency looks opaque as it should.
User avatar
Photonic
Posts: 25
Joined: Sat Feb 08, 2020 3:34 pm

Re: [0.4.5]user defined art transparency issues

Post by Photonic »

It's a horrible picture, and a poor bug report.
The transparent sprites you see in the picture [in the OP] are from the .art tiles.

This picture is better.
Untitled-1.png

I have tested some of this with the upscale pack. The plain "texture" command works, but only for tiles that have a base in .art files. If the tile is created new using "tilefromtexture" then the same transparency issue carries over to high res "texture" defined images too.
Last edited by Photonic on Tue Feb 18, 2020 1:06 pm, edited 1 time in total.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49053
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [0.4.5]user defined art transparency issues

Post by Graf Zahl »

No idea how you manage that, I don't. Where does that monster come from?
User avatar
Photonic
Posts: 25
Joined: Sat Feb 08, 2020 3:34 pm

Re: [0.4.5]user defined art transparency issues

Post by Photonic »

I put him into the map in OP using mapster. Just tested the "spawn liztroop" command works in raze you can get one running around in that debug map easily. Same happens either way. Only on new tiles created with tilefromtexture in def file.
Like this.

Code: Select all

tilefromtexture 5000 { file "5000.bmp" }
tilefromtexture 5001 { file "5001.png" }
The reason I brought up bmps is because it illustrates that the two methods of loading art behave differently, after all the .art file is just a collection of bitmaps, palette entry 256 is transparent, but the hint is in it not being so when loaded with def files. That pink is not a bug, just a hopefully helpful hint.
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49053
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [0.4.5]user defined art transparency issues

Post by Graf Zahl »

No, you got it wrong about ART files. ART files are not BMP files but raw pixels where 255 is defined to be the transparent color. BMPs do not define a transparent color so the pink is opaque. This is entirely defined and intended behavior.

I still do not get the glitch you experience. What's your hardware?
User avatar
Phredreeke
Posts: 293
Joined: Tue Apr 10, 2018 8:14 am

Re: [0.4.5]user defined art transparency issues

Post by Phredreeke »

I've got glitchy tilefromtextures as well. Noticable if you load my Powerslave or Life's a Beach pack and turn off truecolor textures. I recorded a short clip of it here

https://www.youtube.com/watch?v=6dg19TbaEy4

Edit: This is on an i5-3450 with a GTX 980 running Win 7
Last edited by Phredreeke on Tue Feb 18, 2020 2:16 pm, edited 1 time in total.
User avatar
Photonic
Posts: 25
Joined: Sat Feb 08, 2020 3:34 pm

Re: [0.4.5]user defined art transparency issues

Post by Photonic »

Graf Zahl wrote:I still do not get the glitch you experience. What's your hardware?
Intel core2duo E8400

OS: Windows 7 (NT 6.1) Build 7601

GL_VENDOR: NVIDIA Corporation
GL_RENDERER: GeForce GT 640/PCIe/SSE2
GL_VERSION: 4.4.0 (Core profile)
GL_SHADING_LANGUAGE_VERSION: 4.40 NVIDIA via Cg compiler

Max. texture size: 16384
Max. texture units: 32
Max. varying: 124
Max. combined shader storage blocks: 96
Max. vertex shader storage blocks: 16
Resolution: 1280 x 1024
User avatar
Photonic
Posts: 25
Joined: Sat Feb 08, 2020 3:34 pm

Re: [0.4.5]user defined art transparency issues

Post by Photonic »

Phredreeke wrote:I've got glitchy tilefromtextures as well. Noticable if you load my Powerslave or Life's a Beach pack and turn off truecolor textures. I recorded a short clip of it here

https://www.youtube.com/watch?v=6dg19TbaEy4

Edit: This is on an i5-3450 with a GTX 980 running Win 7
That looks very different from mine, your video looks like a form of corruption. On my end hud tiles defined with tilefromtexture render properly, same with my menu font. My bug is only on sprites within the game world.
User avatar
Photonic
Posts: 25
Joined: Sat Feb 08, 2020 3:34 pm

Re: [0.4.5]user defined art transparency issues

Post by Photonic »

Phredreeke wrote:I've got glitchy tilefromtextures as well. Noticable if you load my Powerslave or Life's a Beach pack and turn off truecolor textures. I recorded a short clip of it here

https://www.youtube.com/watch?v=6dg19TbaEy4

Edit: This is on an i5-3450 with a GTX 980 running Win 7
I can reproduce this here. Same conditions, any tilefromtexture image with truecolor off.
TEST_0001.png
User avatar
sinisterseed
Posts: 1349
Joined: Tue Nov 05, 2019 6:48 am
Preferred Pronouns: He/Him
Graphics Processor: nVidia with Vulkan support
Contact:

Re: [0.4.5]user defined art transparency issues

Post by sinisterseed »

Phredreeke wrote:I've got glitchy tilefromtextures as well. Noticable if you load my Powerslave or Life's a Beach pack and turn off truecolor textures. I recorded a short clip of it here

https://www.youtube.com/watch?v=6dg19TbaEy4

Edit: This is on an i5-3450 with a GTX 980 running Win 7
Can confirm this as well: https://i.imgur.com/8o1Tvne.png
User avatar
Graf Zahl
Lead GZDoom+Raze Developer
Lead GZDoom+Raze Developer
Posts: 49053
Joined: Sat Jul 19, 2003 10:19 am
Location: Germany

Re: [0.4.5]user defined art transparency issues

Post by Graf Zahl »

Is this still an issue? AFAIK the cause got fixed a few months back.
User avatar
mjr4077au
Posts: 829
Joined: Sun Jun 16, 2019 9:17 pm
Graphics Processor: nVidia with Vulkan support
Location: Gosford NSW, Australia
Contact:

Re: [0.4.5]user defined art transparency issues

Post by mjr4077au »

I'll test tonight unless someone else beats me to the punch. The test might not be conclusive until some of the sprite substitution works for the BigFont again as it was one of the things that glitched as well IIRC.
User avatar
mjr4077au
Posts: 829
Joined: Sun Jun 16, 2019 9:17 pm
Graphics Processor: nVidia with Vulkan support
Location: Gosford NSW, Australia
Contact:

Re: [0.4.5]user defined art transparency issues

Post by mjr4077au »

So the glitchiness when turning off true colour tiles doesn't seem to be there. The only issue observed was issues with upscaled HUD sprites as outlined here. Will close this for now, #100 is still open so I guess it'll be worked on in due course :).
Post Reply

Return to “Closed Bugs [Raze]”