Commit 02e1d92a by NTAuthority

alphatest and re-enable transparent models

parent a8ad3dd7
Pipeline #68 skipped
......@@ -105,7 +105,10 @@ void Camera::BeginUpdate( void *gpuContext )
device->SetRenderState(D3DRS_CULLMODE, D3DCULL_NONE);
device->SetRenderState(D3DRS_SRCBLEND, D3DBLEND_SRCALPHA);
device->SetRenderState(D3DRS_DESTBLEND, D3DBLEND_INVSRCALPHA);
device->SetRenderState(D3DRS_ALPHABLENDENABLE, 1);
device->SetRenderState(D3DRS_ALPHABLENDENABLE, 0);
device->SetRenderState(D3DRS_ALPHATESTENABLE, 1);
device->SetRenderState(D3DRS_ALPHAREF, 128);
device->SetRenderState(D3DRS_ALPHAFUNC, D3DCMP_GREATEREQUAL);
device->SetTextureStageState(0, D3DTSS_ALPHAOP, D3DTOP_MODULATE);
// Set projection stuff.
......
......@@ -56,8 +56,8 @@ void World::PutEntitiesOnGrid( void )
// Try putting all the world entities on the grid.
LIST_FOREACH_BEGIN( Entity, this->entityList.root, worldNode )
// ignore LODs and transparent models (the latter as there's no depth sorting yet)
if (item->GetModelInfo() && item->GetModelInfo()->GetLODDistance() < 300.0f && (item->GetModelInfo()->GetFlags() & 12) == 0)
// ignore LODs
if (item->GetModelInfo() && item->GetModelInfo()->GetLODDistance() < 300.0f)
{
this->staticEntityGrid.PutEntity(item);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment