Notifications
Clear all

[Closed] RTT with alpha

Hi

I have been asked to script/automate/make easier the baking for the artist here and for the most part have succeeded,
I have a bunch of outputs from the Render to texture all working well, they are opened and composted in PS with some layer
types (overlay add etc…) and some opacity settings BUT getting a diffuse bake out with an alpha channel eludes me.
If you do it manually and pick 32 bit on a tga when choosing the name and folder to save in the RTT window it saves with and alpha,
but this has to be done once by hand and then all scripted outputs use 32 bit, but thats a bit naf as some people
may not want always 24 bit or always 32 bit.

When supplying the RTT with a file name/path is it possible to set the depth of the tga?

cheers brainsplode

3 Replies

You need to use the TARGA Interface and define the desired settings prior to processing the RTT. Basically if you manually set the values it is changing the TGA Interface values for those parameters, so you need to do it the same way through scripting.

-Eric

nice that did the trick

Thanks!

You might find it hasn’t entirely.

In my circumstance I needed opacity maps to go into my diffuse map alpha, during a network bake (that’s another story and a complete mess).

The problems that I encountered:

[ol]
[li]Opacity as alpha at RTT with scanline doesn’t edge pad (your transperancy might have weird seams)[/li][li]Opacity set when rendering normal maps overlays at RTT … also with scanline[/li][/ol]

I had to use Scanline so I wrote a work around (since you mention you automate photoshop too this will help you):

[ol]
[li]My script creates a clone of the high poly mesh & lods when .opacity or .opacitymap is enabled[/li][li]It then creates a new Full white Diffuse map, with black where it discovered the above values[/li][li]It then deletes the opacity maps and values from the original material[/li][li]It then bakes all lods (regular bakes & opacity bakes) as separate maps.[/li][li]I then use photoshop to insert the alpha into the diffuse map[/li][/ol]