update OsgRender

git-svn-id: https://svn.code.sf.net/p/speed-dreams/code/trunk@5589 30fe4595-0a0c-4342-8851-515496e4dcbd

Former-commit-id: 0cce3c0c9f93d2272fad622e498661908af62b10
Former-commit-id: ee85aedeb43289b2ab7204b9758264e8c60c9f7c
This commit is contained in:
torcs-ng 2013-07-13 19:06:22 +00:00
parent 073d7ec0fb
commit fe03b36aa2
2 changed files with 4 additions and 1 deletions

View file

@ -417,6 +417,7 @@ void SDRender::ShadowedScene()
new osgShadow::LightSpacePerspectiveShadowMapCB; new osgShadow::LightSpacePerspectiveShadowMapCB;
unsigned int baseTexUnit = 0; unsigned int baseTexUnit = 0;
unsigned int baseTexUnit2 = 1;
unsigned int shadowTexUnit = 3; unsigned int shadowTexUnit = 3;
lspsm->setMinLightMargin(10.0f); lspsm->setMinLightMargin(10.0f);
@ -424,7 +425,9 @@ void SDRender::ShadowedScene()
lspsm->setTextureSize(osg::Vec2s(4096, 4096)); lspsm->setTextureSize(osg::Vec2s(4096, 4096));
lspsm->setShadowTextureCoordIndex(shadowTexUnit); lspsm->setShadowTextureCoordIndex(shadowTexUnit);
lspsm->setShadowTextureUnit(shadowTexUnit); lspsm->setShadowTextureUnit(shadowTexUnit);
lspsm->setBaseTextureCoordIndex(baseTexUnit2);
lspsm->setBaseTextureCoordIndex(baseTexUnit); lspsm->setBaseTextureCoordIndex(baseTexUnit);
lspsm->setBaseTextureUnit(baseTexUnit); lspsm->setBaseTextureUnit(baseTexUnit);
shadowRoot = new osgShadow::ShadowedScene; shadowRoot = new osgShadow::ShadowedScene;
shadowRoot->setReceivesShadowTraversalMask(rcvShadowMask); shadowRoot->setReceivesShadowTraversalMask(rcvShadowMask);

View file

@ -26,7 +26,7 @@
#include <track.h> //tTrack #include <track.h> //tTrack
#include <raceman.h> // tSituation #include <raceman.h> // tSituation
#define SHADOW_TECHNIQUE 0 #define SHADOW_TECHNIQUE 4
class SDSky; class SDSky;
class SDScenery; class SDScenery;