14 #include <boost/unordered_set.hpp>
23 class DtCacheSettingsRecord;
29 class DtRecordSettingsBackupInterface;
31 class DtTextureInterface;
85 virtual void initSingletonDependencies();
92 virtual bool getCachedNodeFile(
const std::string& filePathIn,
93 const FilePathList& paths, std::string& cachedFilePathOut,
98 virtual bool getCachedImageFile(
const std::string& filePathIn,
99 const FilePathList& paths, std::string& cachedFilePathOut,
103 virtual void setCachingEnabled(
bool flag);
106 virtual bool acceleratedCachingEnabled()
const;
112 virtual void setCompressTextures(
bool compress);
115 virtual bool compressTexturesEnabled()
const;
118 virtual void releaseResources();
121 virtual void clearAccelerationCache();
124 virtual void setInstancingEnabled(
bool enabled);
127 virtual bool instancingEnabled()
const;
130 bool clearInstancesOnNewScene()
const;
133 void setClearInstancesOnNewScene(
bool clearInstances);
136 void clearInstancingCache();
143 void flushInstanceCache(
bool multipass,
bool flushNodes,
144 bool flushTextures,
bool flushImages);
148 unsigned int flushCycleCount();
151 virtual void ts_clearInstancingCache();
161 virtual void getSplitRecord(std::vector<makArchives::DtCacheSettingsRecord>& rec,
162 std::vector<std::string>& fileNames) {};
170 void loadDefaults(
bool loadOnlyFactorySettings =
false);
173 void saveAsDefaults();
176 void exportSettings(
const std::string& fileName);
179 void importSettings(
const std::string& fileName);
182 virtual ExcludedExtensions& excludedExtensions();
187 return ts_isExcludedExtension(ext);
192 return mySettingsBackup;
197 return mySettingsBackup;
210 virtual void ts_flushInstancingCache(
bool multiPass,
211 bool flushNodes,
bool flushTextures,
bool flushImages);
224 virtual void autoSaveDefaultsIfNeeded();
227 virtual bool ts_isExcludedExtension(
const std::string& ext)
const;
231 virtual void addExcludedExtension(
const std::string &ext);
235 virtual void removeExcludedExtension(
const std::string &ext);
244 virtual bool save(
const std::string& origFilename,
245 const std::string& cachedFilename,
bool optimize);
DtDe & myDe
Definition: DtFileCache.h:250
DT_DLL_EXAMPLESCENEROOTPLUGIN void init(DtDe &anIG)
unsigned int myCacheHint
Definition: DtFileCache.h:48
std::deque< std::string > FilePathList
Definition: DtFileCache.h:43
Virtual base class. Allows for RTTI and proper virtual destruction. Used by Creators, Factories, Providers, Assemblers and User Interfaces.
Definition: DtVirtualBaseClass.h:19
bool myFlipDDSTexturesFlag
Definition: DtFileCache.h:66
bool myCachingEnabled
Definition: DtFileCache.h:251
bool myUseMemoryImageCacheFlag
Definition: DtFileCache.h:59
boost::unordered_set< std::string > ExcludedExtensions
A set of extensions excluded from the cache.
Definition: DtFileCache.h:42
std::string myCacheDir
Definition: DtFileCache.h:53
bool myInstancingEnabled
Definition: DtFileCache.h:254
bool myCompressTexturesFlag
Definition: DtFileCache.h:61
bool myInstanceTexturesFlag
Definition: DtFileCache.h:60
std::multimap< std::string, void * > customPluginData
Definition: DtFileCache.h:51
bool myUseAccelerationCacheFlag
Definition: DtFileCache.h:56
The abstract creator for the abstract DtFileCache class.
Definition: DtFileCache.h:266
ExcludedExtensions myExcludedExtensionMap
Definition: DtFileCache.h:259
bool myCompressTextureFlag
Definition: DtFileCache.h:252
Interface for a texture. Used to pass in a texture to vrvGraphics.
Definition: DtTextureInterface.h:24
virtual void addRecords(makArchives::DtCacheSettingsRecord &recs, makArchives::DtCacheSettingsRecord &combinedRec)
To support writing element definitions in folders as multiple files not implemented for DtFileCache...
Definition: DtFileCache.h:166
bool myHasNoOptions
Definition: DtFileCache.h:55
bool myCDBSource
Definition: DtFileCache.h:67
bool myOptimizeDataFlag
Definition: DtFileCache.h:64
bool myUnloadImageDataFlag
Definition: DtFileCache.h:62
std::string myOriginalPath
Definition: DtFileCache.h:54
Contains makVrv::DtVirtualBaseClass class.
DtRecordSettingsBackupInterface * mySettingsBackup
Definition: DtFileCache.h:261
The DtDeSharedState represents all the data that is shared between the master and its slaves...
Definition: DtDeSharedState.h:45
#define DT_DLL_VRVCORE
Definition: vrvCore.h:20
DtDe & getDe()
Definition: DtFileCache.h:200
Class to manage disconnection of boost connections on deletion.
Definition: DtSignalConnectionManager.h:20
std::multimap< std::string, std::string > customOptionStrings
Definition: DtFileCache.h:50
DtRecordSettingsBackupInterface * settingsBackup()
Definition: DtFileCache.h:195
Definition: DtFileCache.h:45
int myOptimizeFileLevel
Definition: DtFileCache.h:65
Record for the settings associated with the VRV caching.
Definition: DtCacheSettingsRecord.h:17
bool myInstanceNodesFlag
Definition: DtFileCache.h:58
bool myClearInstancesOnNewSceneFlag
Definition: DtFileCache.h:253
Base class to provide boost signal/slot management.
bool isExcludedExtension(const std::string &ext) const
Check if the extension is in the list of excluded file types.
Definition: DtFileCache.h:185
DtSignalConnectionManager myConnectionManager
Definition: DtFileCache.h:257
virtual void getSplitRecord(std::vector< makArchives::DtCacheSettingsRecord > &rec, std::vector< std::string > &fileNames)
To support writing element definitions in folders as multiple files not implemented for DtFileCache...
Definition: DtFileCache.h:161
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:72
const DtRecordSettingsBackupInterface * settingsBackup() const
Definition: DtFileCache.h:190
The makVrv::DtRecordSettingsBackupInterface provides an interface to record-based backups...
Definition: DtRecordSettingsBackup.h:24
FilePathList myDatabasePaths
Definition: DtFileCache.h:47
Handles the caching of files. Includes functions for excluding files with certain extensions from bei...
Definition: DtFileCache.h:37
unsigned int myFlushCycleCount
Definition: DtFileCache.h:255
boost::signalslib::signal< void()> signal_clearInstanceCache
Signal emmitted when clearCache is called, used to allow other caches to be cleared.
Definition: DtFileCache.h:207
Contains DLL export macros.