Game Development Community

How to implement Emissive Masks ?

by Necrode · in Torque 3D Professional · 03/15/2010 (12:30 am) · 7 replies

hey guys, I've been trying to figure out a way to implement emissive masks (so that you can control which part of a texture is fullbright). is there a legit way of implementing this, or do I need to do some hack using one of the other mask types (specular, normal, light, etc) ?

if anyone has figured this out, or knows how it would be accomplished, I'd be grateful. thanks

About the author

They locked me in here with a computer, and said I don't get to leave until I've completed a computer game.


#1
03/15/2010 (4:29 am)
I've had success adding in a mask in the diffuse slot on layer 1 of the material from within the material editor. I then select 'emissive' for the layer. Works great for glow masks ('Tron' type effects) if you want to check that as well.

sorry for the long link but here is an example on a model I did a week ago:

http://www.fovproject.com/index.php?supermode=gallery_view&previewm=1&a=In_Game_Views&image=100306124427_girl2_2010-03-06_01-17-47-06.jpg&screenres=1680-1050
#2
03/15/2010 (5:55 am)
@Aaron - Most Impressive :-)
#3
03/15/2010 (6:51 am)
I have to admit, the model is not mine but one of the Dex-Soft ones :) I was simply adding emissive/glow maps to it for my own purposes ;)
#4
03/15/2010 (12:55 pm)
hey Aaron, thanks for the reply

about your glow mask, and Layer 0 Diffuse map, can you give me some details on them ? what format were you using (tga, png ?) and were you using alpha transparency on your mask, or was it a black/white gradient ?

I'm trying what you recommended, without any luck. when I add the mask on Layer 1, I can't get any of the Layer 0 Diffuse to "come through" the mask.

if you could provide more details or perhaps even some sample files, I'd be in your debt
#5
03/15/2010 (1:12 pm)
I used transparent .PNG with the glow portion in whatever color I wanted it to be. Easily accomplished if you have paint.net.

Take the gideon textures for example, open them up in paint.net and convert them to black and white. Adjust the contrast and brightness to get the highlight parts to be as distinct as you can get. Use the magic wand tool and select the areas you want. Make a new empty layer, switch to it, and then fill or paint the areas selected with your color of choice. Once you are done, delete the original layer and save the image out as a png.

Place this file in with the rest of the textures and run the Material editor. Open up the gideon model, selecting either head or body, and select layer 1 instead of 0, then select the new image you made for the diffuse for that layer. Select the glow and emissive checkboxes for that layer, then save the material. You should have a tron like gideon character now.

Here is a set of those masks:
http://www.fovproject.com/Miscfiles/emissive.zip
#6
03/15/2010 (1:17 pm)
hey aaron, I just got it working. I was used to old "quake" style B&W masks, apparently all I needed was transparency on my PNG.

looks awesome, thanks again for your help
#7
03/15/2010 (1:19 pm)
Glad to hear that. I put a link up in my post above for the masks on my server if you need em.