16 #include <vlutil/vlString.h>
17 #include <matrix/vlVector.h>
22 #define ENABLE_DIGUY_PARTICLE_RENDERING 0
26 class DtCoordTransform;
30 class DtDiGuySettings;
75 void getAppearances(std::vector<DtString> &choiceValues,
int depth, std::vector<DtString> &retAppearances);
112 void initializeVisualComponent();
117 static DtDiGuyScenario *lightweight_instance(
const std::string& dataPath );
123 diguyScenario& scenario();
128 virtual osg::Node* characterRoot();
134 const char * mapEffect(
const char * diguy_effect_name);
137 std::string findCharacterName(
DtElementID parentSceneObjectID);
140 int getSupportsWeightVariations(
DtElementID parentSceneObjectID);
143 bool evalScript(
const std::string & script);
151 int getNumCharacterTypes();
153 const char * getCharacterTypeAtIndex(
int index);
155 int getCharacterTypeNumAppearances(
const char *
typeName);
157 const char *getCharacterTypeAppearanceAtIndex(
const char *
typeName,
int index);
159 int getCharacterTypeNumGestures(
const char *
typeName);
161 const char *getCharacterTypeGestureAtIndex(
const char *
typeName,
int index);
165 const char *getHandItemClass(
const char *
typeName);
166 int getNumHandItemsInClass(
const char *className);
168 const char *getHandItemFromClass(
const char *className,
int index);
171 int getCharacterTypeNumHeads(
const char *
typeName,
const char *appearanceName);
173 const char *getCharacterTypeHeadAtIndex(
const char *
typeName,
const char *appearanceName,
int index);
176 int getCharacterTypeNumActions(
const char *
typeName);
178 const char *getCharacterTypeActionAtIndex(
const char *
typeName,
int index);
181 float getCharacterTypeActionDuration(
const char *
typeName,
const char *actionName);
183 float getCharacterTypeActionSpeed(
const char *
typeName,
const char *actionName);
186 const char *getCharacterTypeActionPosture(
const char *
typeName,
const char *actionName);
190 const char *getCharacterTypeActionDirection(
const char *
typeName,
const char *actionName);
195 const char *getCharacterTypeActionPrimaryVariant(
const char *
typeName,
const char *actionName);
212 int getNumTypeMapEntries();
215 const char *getTypeMapCharacterType(
int index);
218 const char *getTypeMapCharacterAppearance(
int index);
221 const char *getTypeMapFieldValue(
int index,
const char *fieldName);
222 const char *getTypeMapFieldValue(
int index,
int fieldIndex);
226 int getNumTypeMapCharacterClasses();
227 const char* getTypeMapCharacterClassAtIndex(
int index);
231 int getNumTypeMapCategories(
const char* character_class);
232 const char* getTypeMapCategoryAtIndex(
const char* character_class,
int index);
235 int getNumTypeMapSubcategories(
const char* character_class,
236 const char* category);
237 const char* getTypeMapSubcategoryAtIndex(
const char* character_class,
238 const char* category,
243 virtual void getAppearancesMatchingDiGuyTypeMap(
const DtString &characterType, std::vector<DtString> &fields, std::vector<DtString> &retAppearances);
246 virtual void getAppearancesMatchingPartialDiGuyTypeMap(
const DtString &characterType, std::vector<DtString> &partialFields,
247 std::vector<int> &fieldIndices, std::vector<DtString> &retAppearances);
251 virtual void getTypeMapFieldOptions(
const DtString &characterType, std::vector<DtString> &fields, StringListVec &retValues);
253 virtual void getTypeMapPartialFieldOptions(
const DtString &characterType, std::vector<DtString> &partialFields, std::vector<int> &fieldIndices,
254 StringListVec &retValues);
256 virtual void initTypeMapNodes();
260 virtual void slot_windowDestroyed(
DtWindow* window);
263 virtual void slot_windowCreated(
DtWindow* window);
266 virtual void slot_reloadShader();
269 virtual void slot_preDraw();
272 virtual void slot_postDraw();
275 virtual void slot_postUpdate();
278 virtual void syncToSharedDiGuySettings();
281 virtual void slot_diGuyInstancingEnabledChanged(
bool enabled );
284 virtual void slot_diGuyInstancedLodChanged(
int lod );
287 virtual void slot_diGuyVisualizeInstancingChanged(
bool enabled );
290 virtual void slot_diGuyMaxDrawDistanceChanged(
float distance );
293 virtual void slot_diGuyMultiThreadUpdateChanged(
bool enabled );
298 diguyCharacter *getCharacter(
DtElementID parentSceneObjectID);
303 static DtDiGuyScenario *createNonVisualInstance(
const std::string& dataPath);
305 static void slot_displayToBeDestroyed(
const std::string& displayName,
DtDe *de);
308 void updateScenario(
double simTime);
309 void setComponentVisualizationMode(
int mode);
314 void createDiGuyScenario();
316 void reloadConfigInfo();