Reaper Grimm
Register | User Profile | Member List | F.A.Q | Privacy Policy | New Blog | Search Forums | Forums Home
Doomworld Forums : Powered by vBulletin version 2.2.5 Doomworld Forums > Classic Doom > Doom Editing > TRANMAP abuse in Boom: additive blending, inversion, grayscale, and more!
 
Author
All times are GMT. The time now is 16:23. Post New Thread    Post A Reply
esselfortium
A Major Doomworld Concern


Posts: 6640
Registered: 01-02


I discovered tonight that Boom's TRANMAP lumps (precalculated translucency tables) are effectively 256x256 flats, meaning they can be edited in Photoshop, Paint.NET, or any other decent image editor that supports layers. This means that they can be manually created and used for all sorts of cool things that basic translucency can't do. With it I've created Boom-compatible additive blending, grayscaling effects, color inversion, hue-shifting, and all sorts of other useful things. They work perfectly in PrBoom and Eternity, but ZDoom completely ignores the TRANMAP lumps, totally breaking the effects. (I've put in a feature request for this, since it seems most people just use ZDoom for everything regardless of intended port.)

A few examples:
http://sl4.poned.com/screens/tranmap-fx/etrn425.png Hue shift, inversion, and grayscale
http://sl4.poned.com/screens/tranmap-fx/etrn413.png Additive blending
http://sl4.poned.com/screens/tranmap-fx/etrn411.png Grayscale
http://sl4.poned.com/screens/tranmap-fx/etrn419.png Inverted midtextures and stuff behind them
http://sl4.poned.com/screens/tranmap-fx/etrn418.png Inverted stuff behind midtextures only

The screenshots were taken in Eternity, but this feature was in Boom itself.

I used http://sl4.poned.com/screens/tranma...ps/TRANS100.bmp as a base, a 0% opacity table.

To create a tranmap, open TRANS100.bmp in your image editor of choice, and create a new layer with those same color bars from TRANS100.bmp in it (just copy and paste, or duplicate the layer). Then rotate it 90 degrees counter-clockwise (putting the purples on the right), and set its opacity to the amount of translucency you want. Changing the brightness or coloring of the horizontal bars will affect what's behind the midtexture, and changing the vertical bars in the transparent layer will affect the transparent midtexture itself.

Now import it into your wad with whatever lump name you want, and use the Save As Doom Flat menu item in XWE to put it into the correct format.

To use it in a map, tag all the lines you want to make translucent, but do not set special 260 (translucent line) on them. Put a line in a dummy sector somewhere that has special 260 and that sector tag, with your tranmap lump's name as its middle texture. If you've done it right and you're using a Boom-compatible port that's not ZDoom, it should work.

Here are a few sample tranmaps. They need to be converted to Doom flats in XWE before you can use them:
http://sl4.poned.com/screens/tranma...ps/TRANSB_W.png - Turns everything behind the midtexture into grayscale, without actually making the midtexture itself visible.

http://sl4.poned.com/screens/tranma...ps/TRANSBW2.png - Makes the midtexture and everything behind it grayscale.

http://sl4.poned.com/screens/tranma...ps/TRANSAD2.png - Bright additive blending.

http://sl4.poned.com/screens/tranma...ps/TRANSIN2.png - Inverts the colors of everything behind the midtexture, without displaying the midtexture itself.

http://sl4.poned.com/screens/tranma...ps/TRANSIN3.png - Inverts the colors of the midtexture and everything behind it.

http://sl4.poned.com/screens/tranma...ps/TRANSINV.png - Inverts the midtexture only, but not what's behind it.

Have fun!

__________________
essel.spork-chan.net - doom stuff, artwork, and music by esselfortium

Last edited by esselfortium on 09-06-08 at 06:56

Old Post 09-06-08 06:33 #
esselfortium is offline Profile || Blog || PM || Email || Homepage || Search || Add Buddy IP || Edit || Quote
lupinx-Kassman
Senior Member


Posts: 1409
Registered: 10-06


Your awesome Essel.

Old Post 09-06-08 06:56 #
lupinx-Kassman is offline Profile || Blog || PM || Email || Search || Add Buddy IP || Edit || Quote
Death-Destiny
Forum Regular


Posts: 934
Registered: 12-07


Cool. More toys to play with the next time I make a Boom map. Thanks a ton Essel! I still play maps in the ports they're intended for, so I can appreciate this. =D

Old Post 09-06-08 07:19 #
Death-Destiny is offline Profile || Blog || PM || Homepage || Search || Add Buddy IP || Edit || Quote
Graf Zahl
Why don't I have a custom title by now?!


Posts: 7787
Registered: 01-03


Just a note:

OpenGL ports can not recreate such effects at all for obvious technical reasons so anyone using GZDoom or PrBoom's GL renderer won't be able to use it.

Old Post 09-06-08 08:21 #
Graf Zahl is online now Profile || Blog || PM || Email || Search || Add Buddy IP || Edit || Quote
TomoAlien
Member


Posts: 320
Registered: 06-08


Cool, i've made some effects with it (Red glass effect, tinter, invulnerability sphere effect). Nice find Essel.

Old Post 09-06-08 11:09 #
TomoAlien is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
andrewj
Senior Member


Posts: 1641
Registered: 04-02



Graf Zahl said:
OpenGL ports can not recreate such effects at all for obvious technical reasons so anyone using GZDoom or PrBoom's GL renderer won't be able to use it.

You could support some of these effects (those that are possible in GL) by performing an analysis of the TRANMAP lump being used. But there's probably no one in the world willing to write that analysis code :)

Old Post 09-06-08 13:28 #
andrewj is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
TomoAlien
Member


Posts: 320
Registered: 06-08



Ajapted said:

You could support some of these effects (those that are possible in GL) by performing an analysis of the TRANMAP lump being used. But there's probably no one in the world willing to write that analysis code :)



It would require use of Pixel Shaders since they can do that.

Old Post 09-06-08 14:19 #
TomoAlien is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
Graf Zahl
Why don't I have a custom title by now?!


Posts: 7787
Registered: 01-03



Ajapted said:

You could support some of these effects (those that are possible in GL) by performing an analysis of the TRANMAP lump being used. But there's probably no one in the world willing to write that analysis code :)



I think you nailed the problem. ;)


TomoAlien said:


It would require use of Pixel Shaders since they can do that.



No, they can't. Pixel shaders don't control the blending with the background, only how the source data is generated. And besides, the destination is always true color so the TRANMAP data would have no reference of what color index to use for it.

Old Post 09-06-08 14:51 #
Graf Zahl is online now Profile || Blog || PM || Email || Search || Add Buddy IP || Edit || Quote
TomoAlien
Member


Posts: 320
Registered: 06-08



Graf Zahl said:

No, they can't. Pixel shaders don't control the blending with the background, only how the source data is generated. And besides, the destination is always true color so the TRANMAP data would have no reference of what color index to use for it.



Stupid me.

Old Post 09-06-08 16:04 #
TomoAlien is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
leileilol
dork stalker


Posts: 2726
Registered: 06-04


Heretic and Hexen has tranmaps as well, IIRC

Old Post 09-06-08 16:53 #
leileilol is offline Profile || Blog || PM || Homepage || Search || Add Buddy IP || Edit || Quote
Mechadon
Senior Member


Posts: 2226
Registered: 12-06


Jesus that's awesome essel :O

Old Post 09-06-08 18:54 #
Mechadon is offline Profile || Blog || PM || Email || Homepage || Search || Add Buddy IP || Edit || Quote
Use3D
Forum Legend


Posts: 4714
Registered: 04-02


Yes, secret technology developed for a secret doom project full of secrets....


o.-

Old Post 09-06-08 23:52 #
Use3D is offline Profile || Blog || PM || Email || Homepage || Search || Add Buddy IP || Edit || Quote
entryway
Forum Staple


Posts: 2739
Registered: 01-04


Firefox can't find the server at sl4.poned.com :(

Do you still have these screnshots locally?

Old Post 12-20-12 09:33 #
entryway is offline Profile || Blog || PM || Homepage || Search || Add Buddy IP || Edit || Quote
Mad Butcher
Member


Posts: 254
Registered: 05-03


All the images are at archive.org.

http://wayback.archive.org/web/*/http://sl4.poned.com/*

Old Post 12-20-12 09:46 #
Mad Butcher is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
wesleyjohnson
Senior Member


Posts: 1056
Registered: 04-09


I have done some tranmap analysis in DoomLegacy, to support RGB draw modes and opengl rendering.
The analysis can detect average translucency, can draw translucent and opaque pixels.
Other effects will be lost.
More strange uses of these tranmaps will require that the ports have a normal tranmap application before RGB conversion. This will not work with textures and sprites that already are RGB, nor with RGB draw screens, which creates a conflict.
At least we still have a palette draw mode, which should be able to handle these.

Old Post 12-21-12 04:04 #
wesleyjohnson is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
hawkwind
Senior Member


Posts: 1015
Registered: 04-04



Graf Zahl said:
Just a note:

OpenGL ports can not recreate such effects at all for obvious technical reasons so anyone using GZDoom or PrBoom's GL renderer won't be able to use it.



Ditto for Risen3D

Old Post 12-21-12 10:55 #
hawkwind is offline Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
Memfis
Forum Spammer


Posts: 5800
Registered: 04-07


I don't know if this is the correct place to ask but...
I'm looking at orange sky through translucent waterfall texture and I see some purple pixels:
http://thumb1.wuala.com/previewImage/kuchitsu/Doom_SCREEN/DEV/doom1495.jpg

Do I need some custom TRANMAP to get rid of them? If so, how do I make it? The map is for prboom-plus -complevel 9 (I don't mind if it will not work in opengl)

Old Post 03-07-13 17:45 #
Memfis is offline Profile || Blog || PM || Email || Search || Add Buddy IP || Edit || Quote
Gez
Why don't I have a custom title by now?!


Posts: 11390
Registered: 07-07


The problem probably doesn't happen in OpenGL anyway.

Old Post 03-07-13 18:35 #
Gez is online now Profile || Blog || PM || Search || Add Buddy IP || Edit || Quote
All times are GMT. The time now is 16:23. Post New Thread    Post A Reply
 
Doomworld Forums : Powered by vBulletin version 2.2.5 Doomworld Forums > Classic Doom > Doom Editing > TRANMAP abuse in Boom: additive blending, inversion, grayscale, and more!

Show Printable Version | Email this Page | Subscribe to this Thread

 

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are OFF
[IMG] code is ON
 

< Contact Us - Doomworld >

Powered by: vBulletin Version 2.2.5
Copyright ©2000, 2001, Jelsoft Enterprises Limited.