VR-Forces 4.0.4 Class Documentation
Public Types | Public Member Functions | Protected Member Functions | Protected Attributes
makVrv::DtMergeDuplicateTextureVisitor Class Reference

Apply the same visitor to multiple models and it will merge all duplicate textures that refer to the same image file. More...

Inheritance diagram for makVrv::DtMergeDuplicateTextureVisitor:
Inheritance graph
[legend]

List of all members.

Public Types

typedef boost::unordered_map
< std::string, osg::ref_ptr
< DtOsgFileCache::TextureCollection > > 
TextureMap
typedef std::vector< std::pair
< std::string,
DtOsgFileCache::TextureCollection * > > 
TextureList

Public Member Functions

 DtMergeDuplicateTextureVisitor (TextureMap &textureMap, TextureList &textureList, const std::string &parentFilePath, bool replaceTexturesWithLoadOnDemandImages, bool compressTextures, bool followProxyNodes)
 CTOR.
virtual void apply (osg::Geode &geode)
 Apply to the geod.
virtual void apply (osg::Node &node)
 Apply to the node.
virtual void apply (osg::StateSet &stateset)
 Apply to the state set.
virtual void apply (osg::ProxyNode &node)
 Apply to the node.
void clearTextures ()
 Removes all current found textures.

Protected Member Functions

osg::ref_ptr< osg::Texture > findDuplicateTexture (osg::Texture &texture)
void processTexture (osg::Texture &texture, const osg::Image *img)

Protected Attributes

std::string myFilePath
TextureMapmyTextureMapRef
TextureListmyTextureList
bool myUnloadImageDataFlag
bool myCompressTextures
bool myProcessProxyNodes

Detailed Description

Apply the same visitor to multiple models and it will merge all duplicate textures that refer to the same image file.


Member Typedef Documentation

typedef boost::unordered_map<std::string,osg::ref_ptr<DtOsgFileCache::TextureCollection> > makVrv::DtMergeDuplicateTextureVisitor::TextureMap

Constructor & Destructor Documentation

makVrv::DtMergeDuplicateTextureVisitor::DtMergeDuplicateTextureVisitor ( TextureMap textureMap,
TextureList textureList,
const std::string &  parentFilePath,
bool  replaceTexturesWithLoadOnDemandImages,
bool  compressTextures,
bool  followProxyNodes 
)

CTOR.


Member Function Documentation

virtual void makVrv::DtMergeDuplicateTextureVisitor::apply ( osg::Geode &  geode) [virtual]

Apply to the geod.

virtual void makVrv::DtMergeDuplicateTextureVisitor::apply ( osg::Node &  node) [virtual]

Apply to the node.

virtual void makVrv::DtMergeDuplicateTextureVisitor::apply ( osg::StateSet &  stateset) [virtual]

Apply to the state set.

virtual void makVrv::DtMergeDuplicateTextureVisitor::apply ( osg::ProxyNode &  node) [virtual]

Apply to the node.

Removes all current found textures.

osg::ref_ptr<osg::Texture> makVrv::DtMergeDuplicateTextureVisitor::findDuplicateTexture ( osg::Texture &  texture) [protected]
void makVrv::DtMergeDuplicateTextureVisitor::processTexture ( osg::Texture &  texture,
const osg::Image *  img 
) [protected]

Member Data Documentation


The documentation for this class was generated from the following file:

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)