- Timestamp:
- 03/21/12 18:36:20 (14 months ago)
- Files:
-
- 1 modified
Legend:
- Unmodified
- Added
- Removed
-
OpenSceneGraph/trunk/src/osgShadow/ViewDependentShadowTechnique.cpp
r12292 r13041 1 /* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield 1 /* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield 2 2 * 3 * This library is open source and may be redistributed and/or modified under 4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or 3 * This library is open source and may be redistributed and/or modified under 4 * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or 5 5 * (at your option) any later version. The full license is in LICENSE file 6 6 * included with this distribution, and on the openscenegraph.org website. 7 * 7 * 8 8 * This library is distributed in the hope that it will be useful, 9 9 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 10 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 11 11 * OpenSceneGraph Public License for more details. 12 12 * … … 44 44 45 45 void ViewDependentShadowTechnique::dirty() 46 { 46 { 47 47 OpenThreads::ScopedLock<OpenThreads::Mutex> lock(_viewDataMapMutex); 48 48 49 osgShadow::ShadowTechnique::_dirty = true; 49 osgShadow::ShadowTechnique::_dirty = true; 50 50 51 51 for( ViewDataMap::iterator mitr = _viewDataMap.begin(); … … 68 68 osgShadow::ShadowTechnique::_shadowedScene->osg::Group::traverse(nv); 69 69 } 70 70 71 71 void ViewDependentShadowTechnique::cull(osgUtil::CullVisitor& cv) 72 72 { 73 73 //osgShadow::ShadowTechnique::cull( cv ); 74 74 75 75 ViewData * vd = getViewDependentData( &cv ); 76 76 … … 87 87 } 88 88 } 89 89 90 90 void ViewDependentShadowTechnique::cleanSceneGraph() 91 { 91 { 92 92 //osgShadow::ShadowTechnique::cleanSceneGraph( ); 93 93 } … … 95 95 ViewDependentShadowTechnique::ViewData * 96 96 ViewDependentShadowTechnique::getViewDependentData( osgUtil::CullVisitor * cv ) 97 { 97 { 98 98 OpenThreads::ScopedLock<OpenThreads::Mutex> lock(_viewDataMapMutex); 99 99 return _viewDataMap[ cv ].get(); … … 102 102 void ViewDependentShadowTechnique::setViewDependentData 103 103 ( osgUtil::CullVisitor * cv, ViewData * data ) 104 { 104 { 105 105 OpenThreads::ScopedLock<OpenThreads::Mutex> lock(_viewDataMapMutex); 106 106 _viewDataMap[ cv ] = data; 107 107 } 108 108 109 void ViewDependentShadowTechnique::ViewData::dirty( bool flag ) 110 { 109 void ViewDependentShadowTechnique::ViewData::dirty( bool flag ) 110 { 111 111 OpenThreads::ScopedLock<OpenThreads::Mutex> lock(_mutex); 112 112 _dirty = flag; … … 121 121 } 122 122 123 void ViewDependentShadowTechnique::ViewData::cull( void ) 124 { 123 void ViewDependentShadowTechnique::ViewData::cull( void ) 124 { 125 125 126 126 }
