T3D 1.1 Beta 3 - River surface and groundCover objects render black - RESOLVED
by Christian S · in Torque 3D Professional · 10/18/2010 (1:40 pm) · 25 replies
Build: 1.1 Beta 3
(what platform/OS did this happen on?)
Platform: Windows XP Pro.
The bug is seen in game and in editor mode both
(what is the bug)

As you can see the riwer surface renders black when seen from below, except from under water/ground.

As you can see the ground cover meshes renders odd when backed by objects, and black when seen against the sky.
Steps to Repeat:
1. Launch the game
2. Add riwer or objects
Suggested Fix: Havent a clue
(what platform/OS did this happen on?)
Platform: Windows XP Pro.
The bug is seen in game and in editor mode both
(what is the bug)

As you can see the riwer surface renders black when seen from below, except from under water/ground.

As you can see the ground cover meshes renders odd when backed by objects, and black when seen against the sky.
Steps to Repeat:
1. Launch the game
2. Add riwer or objects
Suggested Fix: Havent a clue
#22
02/09/2011 (10:39 am)
I get stuff fixed by unchecking transparent z-write.. i must investigate what happened yesterday when i tried that without success...
#23
The issue here was seeing the backside of rivers from over water would sometimes render black, or odd data. There's not something really valid to render here, as rendering a separate reflection for the backside of the river is a bit unnecessary. We decided the best thing to do is not to render the backside of the river at all. Here's the fix:
In gamecorescriptsclientwater.cs:
I know they're comin...but let me know if there are any problems with this fix so that we can address them quickly.
I was only able to fix this for rivers/water planes. I'm still looking into it for groundCover, which I'm having a lot of trouble reproducing on my side. I'll keep tweaking with settings to see what I can get.
EDIT: Sending the e-mail in my profile a .mis file for the FPS Example with a level/camera bookmark showing the problem would monumentally help.
02/10/2011 (3:08 pm)
Thanks for working with me, everybody. I've got the issue fixed and checked in for 1.1 final.Quote:if its been an issue since before 2009, I dont see anyone caring enough about it to actually fix it.- Think again ;)
The issue here was seeing the backside of rivers from over water would sometimes render black, or odd data. There's not something really valid to render here, as rendering a separate reflection for the backside of the river is a bit unnecessary. We decided the best thing to do is not to render the backside of the river at all. Here's the fix:
In gamecorescriptsclientwater.cs:
singleton GFXStateBlockData( WaterStateBlock )
{
samplersDefined = true;
samplerStates[0] = WaterSampler; // noise
samplerStates[1] = SamplerClampPoint; // #prepass
samplerStates[2] = SamplerClampPoint; // $reflectbuff
samplerStates[3] = SamplerClampPoint; // $backbuff
samplerStates[4] = SamplerWrapLinear; // $cubemap
samplerStates[5] = SamplerWrapLinear; // foam
samplerStates[6] = SamplerClampLinear; // depthMap ( color gradient )
cullDefined = true;
cullMode = "GFXCullCCW"; //CULLMODE CHANGE
};
//NEW STATEBLOCK, copy and paste this in.
singleton GFXStateBlockData( UnderWaterStateBlock : WaterStateBlock )
{
cullMode = "GFXCullCW";
};
/////////////////////////////////////////////////////////////
singleton CustomMaterial( Underwater )
{
// These samplers are set in code not here.
// This is to allow different WaterObject instances
// to use this same material but override these textures
// per instance.
//sampler["bumpMap"] = "core/art/water/noise02";
//sampler["foamMap"] = "core/art/water/foam";
sampler["prepassTex"] = "#prepass";
sampler["refractBuff"] = "$backbuff";
shader = UnderWaterShader;
stateBlock = UnderWaterStateBlock; //USE NEW STATEBLOCK HERE.
specular = "0.75 0.75 0.75 1.0";
specularPower = 48.0;
version = 3.0;
};
/////////////////////////////////////////////////////////////
singleton GFXStateBlockData( WaterBasicStateBlock )
{
samplersDefined = true;
samplerStates[0] = WaterSampler; // noise
samplerStates[2] = SamplerClampPoint; // $reflectbuff
samplerStates[3] = SamplerClampPoint; // $backbuff
samplerStates[4] = SamplerWrapLinear; // $cubemap
cullDefined = true;
cullMode = "GFXCullCCW"; //CULL MODE CHANGED
};
//NEW STATEBLOCK, copy and paste in this entire thing.
singleton GFXStateBlockData( UnderWaterBasicStateBlock : WaterBasicStateBlock )
{
cullMode = "GFXCullCW";
};
/////////////////////////////////////////////////////////////
singleton CustomMaterial( UnderwaterBasic )
{
// These samplers are set in code not here.
// This is to allow different WaterObject instances
// to use this same material but override these textures
// per instance.
//sampler["bumpMap"] = "core/art/water/noise02";
//samplers["skyMap"] = "$cubemap";
//sampler["prepassTex"] = "#prepass";
sampler["refractBuff"] = "$backbuff";
shader = UnderWaterBasicShader;
stateBlock = UnderWaterBasicStateBlock; //USE NEW STATEBLOCK HERE
version = 2.0;
};I know they're comin...but let me know if there are any problems with this fix so that we can address them quickly.
I was only able to fix this for rivers/water planes. I'm still looking into it for groundCover, which I'm having a lot of trouble reproducing on my side. I'll keep tweaking with settings to see what I can get.
EDIT: Sending the e-mail in my profile a .mis file for the FPS Example with a level/camera bookmark showing the problem would monumentally help.
#24
02/10/2011 (4:00 pm)
Thanks Ray! I will play around with ground cover and see if I can get a reproducible error.
#25
04/13/2011 (5:26 pm)
Fixed in 1.1 Final and Preview.
Torque 3D Owner Paul Yoskowitz
WinterLeaf Entertainment
curiousity.....
do you have a list? maybe running them through again wouldnt hurt....