void LD3dsExporter::initSettings(void) const { addSetting(LDExporterSetting(ls(_UC("3dsSeams")), m_seams, udKey("Seams").c_str())); LDExporterSetting *pGroup = &m_settings.back(); addSetting(pGroup, LDExporterSetting(ls(_UC("3dsSeamWidth")), m_seamWidth, udKey("SeamWidth").c_str())); }
void LDExporter::setFloatForKey( float value, const char* key, bool sessionSpecific /*= true*/) { TCUserDefaults::setFloatForKey(value, udKey(key).c_str(), sessionSpecific); }
float LDExporter::floatForKey( const char* key, float defaultValue /*= 0.0f*/, bool sessionSpecific /*= true*/) { return TCUserDefaults::floatForKey(udKey(key).c_str(), defaultValue, sessionSpecific); }
bool LDExporter::boolForKey( const char *key, bool defaultValue /*= false*/, bool sessionSpecific /*= true*/) { return TCUserDefaults::boolForKey(udKey(key).c_str(), defaultValue, sessionSpecific); }
long LDExporter::longForKey( const char* key, long defaultValue /*= 0*/, bool sessionSpecific /*= true*/) { return TCUserDefaults::longForKey(udKey(key).c_str(), defaultValue, sessionSpecific); }
char* LDExporter::stringForKey( const char* key, const char* defaultValue /*= NULL*/, bool sessionSpecific /*= true*/) { return TCUserDefaults::stringForKey(udKey(key).c_str(), defaultValue, sessionSpecific); }
LDExporterSetting *LDExporter::addEdgesSetting(LDExporterSetting *pGroup) const { if (addSetting(pGroup, LDExporterSetting(ls(_UC("LDXEdges")), m_edges, udKey("Edges").c_str()))) { return &m_settings.back(); } else { return NULL; } }
std::string LDExporter::pathForKey( const char *key, const char *defaultValue /*= NULL*/, bool sessionSpecific /*= true*/) { char *value = TCUserDefaults::pathForKey(udKey(key).c_str(), defaultValue, sessionSpecific); std::string retValue; if (value != NULL) { retValue = value; delete[] value; } return retValue; }
void LDExporter::addConditionalEdgesSetting(LDExporterSetting *pGroup) const { addSetting(pGroup, LDExporterSetting(ls(_UC("LDXConditionalEdges")), m_conditionalEdges, udKey("ConditionalEdges").c_str())); }
void LDExporter::addSeamWidthSetting(LDExporterSetting *pGroup) const { addSetting(pGroup, ls(_UC("LDXSeamWidth")), m_seamWidth, udKey("SeamWidth").c_str(), 0.0f, 5.0f); }
void LDExporter::addPrimSubSetting(LDExporterSetting *pGroup) const { addSetting(pGroup, LDExporterSetting(ls(_UC("LDXPrimSub")), m_primSub, udKey("PrimitiveSubstitution").c_str())); }