#include "SIM_API.h"#include "SIM_Options.h"#include <UT/UT_IStream.h>#include <UT/UT_Ramp.h>Go to the source code of this file.
Classes | |
| class | SIM_OptionsUser |
Defines | |
| #define | GET_DATA_FUNC_I(DataName, FuncName) |
| #define | GET_DATA_FUNC_E(DataName, FuncName, EnumType) |
| #define | GET_DATA_FUNC_B(DataName, FuncName) |
| #define | GET_DATA_FUNC_F(DataName, FuncName) |
| #define | GET_DATA_FUNC_RAMP(DataName, FuncName) |
| #define | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, BaseType, Accessor) |
| #define | GET_DATA_FUNC_V2(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector2, V2); |
| #define | GET_DATA_FUNC_V2D(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector2D, V2); |
| #define | GET_DATA_FUNC_UV(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector2, V2); |
| #define | GET_DATA_FUNC_V3(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector3, V3); |
| #define | GET_DATA_FUNC_V3D(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector3D, V3); |
| #define | GET_DATA_FUNC_UVW(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector3, V3); |
| #define | GET_DATA_FUNC_V4(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector4, V4); |
| #define | GET_DATA_FUNC_V4D(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector4D, V4); |
| #define | GET_DATA_FUNC_Q(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Quaternion, Q); |
| #define | GET_DATA_FUNC_QD(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_QuaternionD, Q); |
| #define | GET_DATA_FUNC_M3(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Matrix3, M3); |
| #define | GET_DATA_FUNC_M4(DataName, FuncName) _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Matrix4, M4); |
| #define | GET_DATA_FUNC_S(DataName, FuncName) |
| #define | _BUILD_SIM_OPTION_GUIDE_GETTERS(DataName, FuncName, Default, BaseType, Accessor) |
| #define | GET_GUIDE_FUNC_I(DataName, FuncName, Default) |
| #define | GET_GUIDE_FUNC_E(DataName, FuncName, EnumType, Default) |
| #define | GET_GUIDE_FUNC_B(DataName, FuncName, Default) |
| #define | GET_GUIDE_FUNC_F(DataName, FuncName, Default) |
| #define | GET_GUIDE_FUNC_V2(DataName, FuncName, Default) _BUILD_SIM_OPTION_GUIDE_GETTERS(DataName, FuncName, Default, UT_Vector2, V2) |
| #define | GET_GUIDE_FUNC_V3(DataName, FuncName, Default) _BUILD_SIM_OPTION_GUIDE_GETTERS(DataName, FuncName, Default, UT_Vector3, V3) |
| #define | GET_GUIDE_FUNC_V4(DataName, FuncName, Default) _BUILD_SIM_OPTION_GUIDE_GETTERS(DataName, FuncName, Default, UT_Vector4, V4) |
| #define | GET_GUIDE_FUNC_S(DataName, FuncName, Default) |
| #define | GET_GUIDE_FUNC_RAMP(DataName, FuncName) |
| #define | SET_DATA_FUNC_I(DataName, FuncName) |
| #define | SET_DATA_FUNC_E(DataName, FuncName, EnumType) |
| #define | SET_DATA_FUNC_B(DataName, FuncName) |
| #define | SET_DATA_FUNC_F(DataName, FuncName) |
| #define | SET_DATA_FUNC_V2(DataName, FuncName) |
| #define | SET_DATA_FUNC_UV(DataName, FuncName) |
| #define | SET_DATA_FUNC_V3(DataName, FuncName) |
| #define | SET_DATA_FUNC_UVW(DataName, FuncName) |
| #define | SET_DATA_FUNC_V4(DataName, FuncName) |
| #define | SET_DATA_FUNC_Q(DataName, FuncName) |
| #define | SET_DATA_FUNC_M3(DataName, FuncName) |
| #define | SET_DATA_FUNC_M4(DataName, FuncName) |
| #define | SET_DATA_FUNC_S(DataName, FuncName) |
| #define | SET_DATA_FUNC_RAMP(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_I(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_E(DataName, FuncName, EnumType) |
| #define | GETSET_DATA_FUNCS_B(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_F(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_V2(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_UV(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_V3(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_UVW(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_V4(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_Q(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_M3(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_M4(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_S(DataName, FuncName) |
| #define | GETSET_DATA_FUNCS_RAMP(DataName, FuncName) |
| #define _BUILD_SIM_OPTION_GETTERS | ( | DataName, | |||
| FuncName, | |||||
| BaseType, | |||||
| Accessor | ) |
Value:
const BaseType##D get##FuncName##D() const \ { return getOptions().getOption##Accessor(DataName); } \ const BaseType##F get##FuncName##F() const \ { return getOptions().getOption##Accessor(DataName); } \ const BaseType##F get##FuncName() const \ { return getOptions().getOption##Accessor(DataName); }
Definition at line 72 of file SIM_OptionsUser.h.
| #define _BUILD_SIM_OPTION_GUIDE_GETTERS | ( | DataName, | |||
| FuncName, | |||||
| Default, | |||||
| BaseType, | |||||
| Accessor | ) |
Value:
const BaseType##D get##FuncName##D(const SIM_Options &options) const \ { return options.hasOption(DataName) \ ? options.getOption##Accessor(DataName) \ : BaseType##D Default; \ } \ const BaseType##F get##FuncName##F(const SIM_Options &options) const \ { return options.hasOption(DataName) \ ? options.getOption##Accessor(DataName) \ : BaseType##D Default; \ } \ const BaseType##F get##FuncName(const SIM_Options &options) const \ { return options.hasOption(DataName) \ ? options.getOption##Accessor(DataName) \ : BaseType##D Default; \ }
Definition at line 108 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_B | ( | DataName, | |||
| FuncName | ) |
Value:
bool get##FuncName() const \ { return getOptions().getOptionB(DataName); }
Definition at line 57 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_E | ( | DataName, | |||
| FuncName, | |||||
| EnumType | ) |
Value:
EnumType get##FuncName() const \ { return static_cast<EnumType> \ (getOptions().getOptionI(DataName)); }
Definition at line 53 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_F | ( | DataName, | |||
| FuncName | ) |
Value:
fpreal64 get##FuncName() const \ { return getOptions().getOptionF(DataName); }
Definition at line 60 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_I | ( | DataName, | |||
| FuncName | ) |
Value:
int64 get##FuncName() const \ { return getOptions().getOptionI(DataName); }
Definition at line 50 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_M3 | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Matrix3, M3); |
Definition at line 100 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_M4 | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Matrix4, M4); |
Definition at line 102 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_Q | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Quaternion, Q); |
Definition at line 96 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_QD | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_QuaternionD, Q); |
Definition at line 98 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_RAMP | ( | DataName, | |||
| FuncName | ) |
Value:
bool get##FuncName(UT_Ramp &ramp) const \ { UT_String rs; \ getOptions().getOptionS(DataName, rs); \ UT_IStream is((const char *) rs, rs.length(), UT_ISTREAM_ASCII); \ return ramp.load(is); } \ }
Definition at line 64 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_S | ( | DataName, | |||
| FuncName | ) |
Value:
Definition at line 104 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_UV | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector2, V2); |
Definition at line 84 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_UVW | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector3, V3); |
Definition at line 90 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_V2 | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector2, V2); |
Definition at line 80 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_V2D | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector2D, V2); |
Definition at line 82 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_V3 | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector3, V3); |
Definition at line 86 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_V3D | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector3D, V3); |
Definition at line 88 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_V4 | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector4, V4); |
Definition at line 92 of file SIM_OptionsUser.h.
| #define GET_DATA_FUNC_V4D | ( | DataName, | |||
| FuncName | ) | _BUILD_SIM_OPTION_GETTERS(DataName, FuncName, UT_Vector4D, V4); |
Definition at line 94 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_B | ( | DataName, | |||
| FuncName, | |||||
| Default | ) |
Value:
bool get##FuncName(const SIM_Options &options) const \ { return options.hasOption(DataName) \ ? options.getOptionB(DataName) \ : Default; \ }
Definition at line 137 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_E | ( | DataName, | |||
| FuncName, | |||||
| EnumType, | |||||
| Default | ) |
Value:
EnumType get##FuncName(const SIM_Options &options) const \ { return static_cast<EnumType> (options.hasOption(DataName) \ ? options.getOptionI(DataName) \ : Default); \ }
Definition at line 131 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_F | ( | DataName, | |||
| FuncName, | |||||
| Default | ) |
Value:
fpreal64 get##FuncName(const SIM_Options &options) const \ { return options.hasOption(DataName) \ ? options.getOptionF(DataName) \ : Default; \ }
Definition at line 143 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_I | ( | DataName, | |||
| FuncName, | |||||
| Default | ) |
Value:
int64 get##FuncName(const SIM_Options &options) const \ { return options.hasOption(DataName) \ ? options.getOptionI(DataName) \ : Default; \ }
Definition at line 125 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_RAMP | ( | DataName, | |||
| FuncName | ) |
Value:
bool get##FuncName(UT_Ramp &ramp, const SIM_Options &options) const \ { if (options.hasOption(DataName)) \ { UT_String rs; \ options.getOptionS(DataName, rs); \ UT_IStream is((const char *) rs, rs.length(), UT_ISTREAM_ASCII); \ return ramp.load(is); } \ return false; \ }
Definition at line 164 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_S | ( | DataName, | |||
| FuncName, | |||||
| Default | ) |
Value:
void get##FuncName(UT_String &value, const SIM_Options &options) const \ { if (options.hasOption(DataName)) \ options.getOptionS(DataName, value); \ else \ value = Default; \ }
Definition at line 156 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_V2 | ( | DataName, | |||
| FuncName, | |||||
| Default | ) | _BUILD_SIM_OPTION_GUIDE_GETTERS(DataName, FuncName, Default, UT_Vector2, V2) |
Definition at line 149 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_V3 | ( | DataName, | |||
| FuncName, | |||||
| Default | ) | _BUILD_SIM_OPTION_GUIDE_GETTERS(DataName, FuncName, Default, UT_Vector3, V3) |
Definition at line 151 of file SIM_OptionsUser.h.
| #define GET_GUIDE_FUNC_V4 | ( | DataName, | |||
| FuncName, | |||||
| Default | ) | _BUILD_SIM_OPTION_GUIDE_GETTERS(DataName, FuncName, Default, UT_Vector4, V4) |
Definition at line 153 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_B | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_B(DataName, FuncName) \ SET_DATA_FUNC_B(DataName, FuncName)
Definition at line 246 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_E | ( | DataName, | |||
| FuncName, | |||||
| EnumType | ) |
Value:
GET_DATA_FUNC_E(DataName, FuncName, EnumType) \ SET_DATA_FUNC_E(DataName, FuncName, EnumType)
Definition at line 243 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_F | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_F(DataName, FuncName) \ SET_DATA_FUNC_F(DataName, FuncName)
Definition at line 249 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_I | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_I(DataName, FuncName) \ SET_DATA_FUNC_I(DataName, FuncName)
Definition at line 240 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_M3 | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_M3(DataName, FuncName) \ SET_DATA_FUNC_M3(DataName, FuncName)
Definition at line 270 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_M4 | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_M4(DataName, FuncName) \ SET_DATA_FUNC_M4(DataName, FuncName)
Definition at line 273 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_Q | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_Q(DataName, FuncName) \ SET_DATA_FUNC_Q(DataName, FuncName)
Definition at line 267 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_RAMP | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_RAMP(DataName, FuncName) \ SET_DATA_FUNC_RAMP(DataName, FuncName)
Definition at line 279 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_S | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_S(DataName, FuncName) \ SET_DATA_FUNC_S(DataName, FuncName)
Definition at line 276 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_UV | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_UV(DataName, FuncName) \ SET_DATA_FUNC_UV(DataName, FuncName)
Definition at line 255 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_UVW | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_UVW(DataName, FuncName) \ SET_DATA_FUNC_UVW(DataName, FuncName)
Definition at line 261 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_V2 | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_V2(DataName, FuncName) \ SET_DATA_FUNC_V2(DataName, FuncName)
Definition at line 252 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_V3 | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_V3(DataName, FuncName) \ SET_DATA_FUNC_V3(DataName, FuncName)
Definition at line 258 of file SIM_OptionsUser.h.
| #define GETSET_DATA_FUNCS_V4 | ( | DataName, | |||
| FuncName | ) |
Value:
GET_DATA_FUNC_V4(DataName, FuncName) \ SET_DATA_FUNC_V4(DataName, FuncName)
Definition at line 264 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_B | ( | DataName, | |||
| FuncName | ) |
Value:
Definition at line 181 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_E | ( | DataName, | |||
| FuncName, | |||||
| EnumType | ) |
Value:
void set##FuncName(const EnumType value) \ { getOptions().setOptionI(DataName, \ static_cast<int>(value)); }
Definition at line 177 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_F | ( | DataName, | |||
| FuncName | ) |
Value:
Definition at line 184 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_I | ( | DataName, | |||
| FuncName | ) |
Value:
Definition at line 174 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_M3 | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_Matrix3F &value) \ { getOptions().setOptionM3(DataName, value); } \ void set##FuncName(const UT_Matrix3D &value) \ { getOptions().setOptionM3(DataName, value); }
Definition at line 217 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_M4 | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_Matrix4F &value) \ { getOptions().setOptionM4(DataName, value); } \ void set##FuncName(const UT_Matrix4D &value) \ { getOptions().setOptionM4(DataName, value); }
Definition at line 222 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_Q | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_QuaternionF &value) \ { getOptions().setOptionQ(DataName, value); } \ void set##FuncName(const UT_QuaternionD &value) \ { getOptions().setOptionQ(DataName, value); }
Definition at line 212 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_RAMP | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_Ramp &ramp) const \ { UT_OStrStream os; \ ramp.save(os); \ os << ends; \ getOptions().setOptionS(DataName, os.str()); \ os.rdbuf()->freeze(0); \ }
Definition at line 231 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_S | ( | DataName, | |||
| FuncName | ) |
Value:
Definition at line 227 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_UV | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_Vector2F &value) \ { getOptions().setOptionUV(DataName, value); } \ void set##FuncName(const UT_Vector2D &value) \ { getOptions().setOptionUV(DataName, value); }
Definition at line 192 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_UVW | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_Vector3F &value) \ { getOptions().setOptionUVW(DataName, value); } \ void set##FuncName(const UT_Vector3D &value) \ { getOptions().setOptionUVW(DataName, value); }
Definition at line 202 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_V2 | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_Vector2F &value) \ { getOptions().setOptionV2(DataName, value); } \ void set##FuncName(const UT_Vector2D &value) \ { getOptions().setOptionV2(DataName, value); }
Definition at line 187 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_V3 | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_Vector3F &value) \ { getOptions().setOptionV3(DataName, value); } \ void set##FuncName(const UT_Vector3D &value) \ { getOptions().setOptionV3(DataName, value); }
Definition at line 197 of file SIM_OptionsUser.h.
| #define SET_DATA_FUNC_V4 | ( | DataName, | |||
| FuncName | ) |
Value:
void set##FuncName(const UT_Vector4F &value) \ { getOptions().setOptionV4(DataName, value); } \ void set##FuncName(const UT_Vector4D &value) \ { getOptions().setOptionV4(DataName, value); }
Definition at line 207 of file SIM_OptionsUser.h.
1.5.9