mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-13 03:33:48 +00:00
RenderMeshExample won't render transparent materials properly, this commit will fix it.
This commit is contained in:
parent
0b6b7f73c5
commit
b0974e6647
1 changed files with 7 additions and 0 deletions
|
|
@ -284,6 +284,13 @@ void RenderMeshExample::prepRenderImage( SceneRenderState *state )
|
|||
// Set our RenderInst as a standard mesh render
|
||||
ri->type = RenderPassManager::RIT_Mesh;
|
||||
|
||||
//If our material has transparency set on this will redirect it to proper render bin
|
||||
if ( matInst->getMaterial()->isTranslucent() )
|
||||
{
|
||||
ri->type = RenderPassManager::RIT_Translucent;
|
||||
ri->translucentSort = true;
|
||||
}
|
||||
|
||||
// Calculate our sorting point
|
||||
if ( state )
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue