Transparency in PNGs

Advanced OpenGL source port fork from ZDoom, picking up where ZDoomGL left off.
[Home] [Download] [Git builds (Win)] [Git builds (Mac)] [Wiki] [Repo] [Bugs&Suggestions]

Moderator: Graf Zahl

DaniJ
Posts: 130
Joined: Sat Oct 08, 2005 19:22

Post by DaniJ »

I'd rather put the offset in the texture definition in HIRESTEX (and if it ever becomes reality NTEXTURE.)
IMO that is a far better idea anyway. Embedding offsets into graphic files just seems wrong in my book, it also requires the use of (yet another) app to get the job done.
User avatar
Enjay
Developer
Developer
Posts: 4748
Joined: Tue Aug 30, 2005 23:19
Location: Scotland
Contact:

Post by Enjay »

But that's how Doom does it, and (G)Zdoom already does it with PNGs - offsets in the graphic. By going for offsets elsewhere you end up with 2 systems.
User avatar
Caligari_87
Posts: 45
Joined: Tue Nov 08, 2005 18:26
Location: Salt Lake City, Utah
Contact:

Post by Caligari_87 »

Graf Zahl wrote:In that case your best way of action is to put a dummy 8 bit texture in the WAD and then replace it using HIRESTEX.
Like Nash said: Will that work for sprites?

I'm assuming it would be something like this:

PISGA0 <---- The dummy 8-bit sprite
PISTOL <----- My alpha-mapped PNG, replacing the dummy texture. Set offsets in HIRESTEX?

8-)
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Post by Graf Zahl »

If you replace a graphic this way both in-game resolution and offset are taken from the lo-res version. The hires version is scaled to fit the same area.
User avatar
Caligari_87
Posts: 45
Joined: Tue Nov 08, 2005 18:26
Location: Salt Lake City, Utah
Contact:

Post by Caligari_87 »

HEY! It...sort of worked :D The alpha mapping is definitely there.

(crappy quick-test graphic screenshot)
Attachments
DOOM0002.jpg
DOOM0002.jpg (18.97 KiB) Viewed 1966 times
User avatar
Tormentor667
Stronghold Team
Posts: 3555
Joined: Sun Nov 13, 2005 23:15
Location: Germany
Contact:

Post by Tormentor667 »

It's time that XWE supports PNG-Alpha stuffage!
User avatar
chopkinsca
Posts: 183
Joined: Thu Dec 29, 2005 8:09

Post by chopkinsca »

Tormentor667 wrote:It's time that XWE supports PNG-Alpha stuffage!
According to Csabo, the PNG support will be fixed up before he releases a new version. Hopefully that new version comes out soon.
User avatar
Tormentor667
Stronghold Team
Posts: 3555
Joined: Sun Nov 13, 2005 23:15
Location: Germany
Contact:

Post by Tormentor667 »

That is great news indeed :)
User avatar
Nash
Developer
Developer
Posts: 1226
Joined: Sun Sep 25, 2005 1:49
Location: Kuala Lumpur, Malaysia
Contact:

Post by Nash »

Nice Cals!

That also means high res HUD weapons graphics are pretty much possible too, eh?

EDIT: Yep, it works. HIRESTEX pwnz!
DaniJ
Posts: 130
Joined: Sat Oct 08, 2005 19:22

Post by DaniJ »

This would all be much easier if you just put your hires graphics in a ZIP and loaded that with GZDoom, rather than trying to force XWE into importing them correctly.
User avatar
Caligari_87
Posts: 45
Joined: Tue Nov 08, 2005 18:26
Location: Salt Lake City, Utah
Contact:

Post by Caligari_87 »

Only one problem: For each graphic that I want to be alpha-mapped, I need a seperate dummy texture/spirte, right? Somewhere along the lines of 15 or more blank 320x240 graphics

Man, Haloguns is going to be huge...

8)
User avatar
Graf Zahl
GZDoom Developer
GZDoom Developer
Posts: 7148
Joined: Wed Jul 20, 2005 9:48
Location: Germany
Contact:

Post by Graf Zahl »

If you use a .zip instead of a .WAD empty graphics will be packed to almost nothing so it shouldn't matter.
User avatar
wildweasel
DRD Team Admin (Inactive)
Posts: 2132
Joined: Wed Jun 29, 2005 22:00
Location: the Admincave!
Contact:

Post by wildweasel »

Caligari_87 wrote:Somewhere along the lines of 15 or more blank 320x240 graphics
They don't need to be that big. You can make them smaller, and you can just use the same offsets as a 320x240 graphic. You could, theoretically, make all your dummy graphics as small as 1 pixel and HIRESTEX would still display them correctly.
User avatar
BlackFish
Posts: 108
Joined: Thu Sep 01, 2005 18:33

Post by BlackFish »

can you release a sample wad with the hires hud weapons?
User avatar
Caligari_87
Posts: 45
Joined: Tue Nov 08, 2005 18:26
Location: Salt Lake City, Utah
Contact:

Post by Caligari_87 »

@WW: No, it seems that HIRESTEX remaps based on the attributes of the dummy graphic, including size.

I'll transfer them over to a zip when I'm finished, though. That will help.

8)
Locked

Return to “GZDoom”