Hello polycounters,
I made sure I checked the search function before posting this so I think im good, then again I could fail super hard at the interwebs and it could have been the first search result and I was just too dumb to realize it.
Anyway I have a model that I wish to glow using an emissive. Did the whole jazz of creating the emissive and got it to make it look kinda like a light bulb in max but not glow. Didnt care to much about that since I knew you could do it in UT3.
On my model I wanted a kinda back computerish screen to glow blue, and white text and a palm print to glow white. There were some other side lights to glow blue and other text to glow white also.
Problem is that when I hook up my emissive map in UT3 its making my model glow the color of the emissive map instead of making the textures from the difuse glow. I assumed that the emissive map would just make the colored textures on my difuse glow depending on the intensity of white/grey on the emissive.
To check if this was acutely the case I hooked up a Constant3Vector with a blue color and a multiply and used this with my emissive. Sure enough everything glowed blue and totaly ignored the colors of my difuse.
So my question is, is this this even possible to get these multiple colors to glow? Or can an emissive only do one color? Checked for tuts online but every example i could find used 1 color in there emissive so it didnt really help. If anyone knows I would extreamly appreciate some insight on this.
Here is a quick render of what my object looks like in Max (its not really glowing, its just kinda lit, couldn't figure out how to make it appear glowing) And of what it looks like in UT3 with the emissive hooked up.
Thanks again for any help.
-Anthony
Replies
You can just import your diffuse map again, (black out everything but that panel) plug it to diffuse and it might not glow much; ramp up the power with a constant and itll glow more. Thats the least amount of work.
To reiterate - you can put anything on your emissive. I'd even advise doing so, as using a flat color creates false looking glows imo (though I'm not sure if this is more expensive... I doubt it. A pixel value is a pixel value.)
uhm.. it is more expensive if you need a whole another texture lookup. well you could store the emissive map as black and white in the alpha channel and use it as a mask instead and just mask out the diffuse map in the shader/material.. if the diffuse map has the right colors... which might be what you suggested.
then we have the texture size problem. a DXT1 compressed texture takes like half the space of a DXT5. DXT1 is RGB and DXT5 is RGBA. So you could store multiple greyscales in the RGB channels in another texture.. if you need multiple greyscales that is. That way you can save some space (not lookups though!). Just tossing it in... each situation is always unique.
but then I believe DXT1 compression is a little crappier for greyscales in the RGB versus DXT5 in alpha.... but usually that won't matter much. not sure about this one though. actually Im not sure about anything... so it is if my memory serves me right look it up if you want to be 100% sure.
In this case using grayscale makes a lot of sense since there's only one hue (blue), you can easily multiply you map by a constant color in the shader as you did, extreme values should naturally clamp to white.
The masking solution Kawe propose is a clever solution as well, but having a separate map would allow you to animate it: pulsing light, change of color when access is granted etc.
Brice, thats real nice information about how channels compress. Gonna store that myself.