Update of /cvsroot/simspark/simspark/spark/kerosin/sceneserver
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv25407
Modified Files:
Tag: projectx
staticmesh.cpp
Log Message:
- added methods to set/get flags if a mesh based object should cast shadows.
This can be used by the graphics engine to disable/enable shadows for specific objects.
The default value is "enabled" for all mesh based objects.
Index: staticmesh.cpp
===================================================================
RCS file: /cvsroot/simspark/simspark/spark/kerosin/sceneserver/staticmesh.cpp,v
retrieving revision 1.2.2.3.2.1
retrieving revision 1.2.2.3.2.2
diff -C2 -d -r1.2.2.3.2.1 -r1.2.2.3.2.2
*** staticmesh.cpp 8 May 2007 03:35:14 -0000 1.2.2.3.2.1
--- staticmesh.cpp 10 May 2007 10:44:25 -0000 1.2.2.3.2.2
***************
*** 33,37 ****
using namespace oxygen;
! StaticMesh::StaticMesh() : mScale(1.0f,1.0f,1.0f)
{
}
--- 33,37 ----
using namespace oxygen;
! StaticMesh::StaticMesh() : mScale(1.0f,1.0f,1.0f), mCastShadows(true)
{
}
***************
*** 235,236 ****
--- 235,248 ----
return mMaterials;
}
+
+ bool
+ StaticMesh::CastShadows() const
+ {
+ return mCastShadows;
+ }
+
+ void
+ StaticMesh::SetCastShadows(bool shadows)
+ {
+ mCastShadows = shadows;
+ }
|