74 const char *
name) = 0;
81 { callbackConst(data, name); }
90 #define SIM_DATA_RETURN_EXISTING 0x01
100 #define SIM_DATA_CREATE_UNIQUE_NAME 0x02
110 #define SIM_DATA_ADOPT_EXISTING_ON_DELETE 0x04
175 void interpolate(
const SIM_Data *source1,
180 int64 getMemorySize()
const;
185 bool getIsAlternateRepresentation()
const;
190 bool saveToFile(
const char *
filename,
192 bool saveToStream(std::ostream &os,
200 void appendFullDataPath(
const SIM_Data *subdata,
bool useobjectid,
206 bool loadFromFile(
const char *filename);
209 bool loadFromStream(
UT_IStream &is,
bool skiptype=
false);
215 static bool getDataTypeFromFile(
const char *filename,
217 static bool getDataTypeFromStream(
UT_IStream &is,
229 const void *getConstPointerToType(
const UT_StringRef &datatype)
const;
238 static const void *castConstPointerToType(
const SIM_Data *
data,
242 static void *castPointerToType(
SIM_Data *data,
246 int getNumSubData()
const;
251 int getSubDataIndex(
const SIM_Data *subdata)
const;
271 long getGuideParmVersion()
const;
279 virtual bool getGuideGeometryList(
const SIM_RootData &root,
280 const char *datapath,
287 const char *datapath,
300 const SIM_Data *getConstSubData(
int index)
const;
304 SIM_Data *getNamedSubData(
const char *dataname);
308 const SIM_Data *getConstNamedSubData(
const char *dataname)
const;
324 const char *startfrom,
338 const char *startfrom,
353 const char *startfrom,
366 const char *startfrom,
377 const char *startfrom,
386 const char *startfrom,
394 SIM_Data *createNamedSubData(
const char *dataname,
395 const char *datatype,
404 SIM_Data *getOrCreateAlternateRepresentation(
405 const char *dataname,
406 const char *datatype)
const;
411 void interpolateSubData(
const SIM_Data &source1,
421 void setNamedSubData(
const char *dataname,
430 void createUniqueSubDataName(
const SIM_Data *subdata,
434 void removeNamedSubData(
const char *dataname);
436 void removeSubData(
int index);
439 void moveNamedSubData(
const char *oldname,
440 const char *newname);
444 const UT_Guid &getUniqueId()
const;
447 long getReferenceCount()
const;
449 int getCreatorId()
const;
451 OP_Node *getCreatorNode()
const;
453 OP_Node *getOwnerNetwork()
const;
456 {
return myFactory->getEngine(); }
458 int getCreatorIndex()
const;
460 const SIM_Time &getCreationTime()
const;
463 bool getIsSelected()
const;
466 void setIsSelected(
bool selected)
const;
470 bool getSelectionRepresentsObject()
const;
476 void copyCreationInfoFrom(
const SIM_Data *source);
481 OP_Node &getNodePathsRelativeTo()
const;
483 OP_Node *getOPNode(
const char *
path,
bool addinterest)
const;
485 OBJ_Node *getOBJNode(
const char *
path,
bool addinterest)
const;
487 SOP_Node *getSOPNode(
const char *
path,
bool addinterest)
const;
489 DOP_Node *getDOPNode(
const char *
path,
bool addinterest)
const;
491 COP2_Node *getCOP2Node(
const char *
path,
bool addinterest)
const;
493 CHOP_Node *getCHOPNode(
const char *
path,
bool addinterest)
const;
495 void addOPInterest(
OP_Node *node)
const;
500 const char *errorparm,
523 void handleModification(
int code = -1);
530 void setNeedsToRecalculateMemorySize()
const;
533 void deleteQueryObjectIfNotBuilding()
const;
536 void deleteGuideObjectIfNotBuilding()
const;
542 void initAlternateRepresentation()
const;
545 void setNeedsInitialization(
bool needsinit)
const;
547 bool getNeedsInitialization()
const;
552 bool saveOptionPacket(std::ostream &os,
const char *
name,
562 bool getIsDoingSimplifiedSaveLoad()
const;
569 void initializeFromParmDefaults();
573 void setSelectionRepresentsObject(
bool representsobject);
577 virtual void setNeedsInitializationSubclass(
bool needsinit)
const;
582 virtual void initializeSubclass();
586 virtual void makeEqualSubclass(
const SIM_Data *source);
589 virtual void saveSubclass(std::ostream &os)
const;
609 virtual SIM_Query *createQueryObjectSubclass()
const;
613 virtual long getGuideParmVersionSubclass()
const;
617 virtual SIM_Guide *createGuideObjectSubclass()
const;
623 virtual void buildGuideGeometrySubclass(
const SIM_RootData &root,
634 virtual void setParametersSubclass(
const SIM_Options &parms);
640 virtual void setNamedSubDataSubclass(
const char *dataname,
645 virtual void removeNamedSubDataSubclass(
const char *dataname);
658 virtual void interpolateSubclass(
const SIM_Data *source1,
664 virtual int64 getMemorySizeSubclass()
const;
671 virtual void handleModificationSubclass(
int code);
680 virtual bool getIsAlternateRepresentationSubclass()
const;
685 virtual void initAlternateRepresentationSubclass(
const SIM_Data &);
693 virtual void *getCastToType(
const UT_StringRef &datatype)
const;
700 {
return myAlternateRepresentationOf; }
746 void decrementReferenceCount();
749 void incrementReferenceCount()
const;
758 void filterDataHelper(
SIM_Data *caller,
764 const char *startfrom,
767 void clearAllSubData();
772 void setUniqueId(
const UT_Guid &newid);
775 static void incrementNameReferenceCount(
778 static void decrementNameReferenceCount(
790 SIM_SubDataInfo *mySubDataInfo;
796 bool myHandlingModification;
797 bool mySelectionRepresentsObject;
798 mutable int64 myMemorySize;
799 mutable long myReferenceCount;
802 mutable const SIM_Data *myAlternateRepresentationOf;
803 mutable bool myNeedsInitialization : 1;
804 mutable bool myBuildingQueryObject : 1;
805 mutable bool myBuildingGuideObject : 1;
806 mutable bool myDoingSimplifiedSaveLoad : 1;
807 mutable bool myIsSelected : 1;
808 mutable bool myExistsOnDisk : 1;
812 friend class SIM_SimulationState;
GT_API const UT_StringHolder filename
virtual void callback(SIM_Data *data, const char *name)
GT_API const UT_StringHolder time
UT_ValArray< const SIM_Data * > SIM_ConstDataArray
This definition holds on to a collection of const SIM_Data pointers.
GLsizei const GLchar *const * path
const SIM_Engine & getEngine() const
Get the engine that created us (from our data factory).
void makeMemberDataUnique()
const SIM_Options * getConstUserOptions() const
const SIM_Data * getAlternateRepresentationOf() const
virtual bool callbackNeedsName() const
virtual ~SIM_EachDataCallback()
GLsizei GLsizei GLchar * source
SIM_Options * getUserOptions()
GLuint const GLchar * name
OPENVDB_API void initialize()
Global registration of native Grid, Transform, Metadata and Point attribute types. Also initializes blosc (if enabled).
virtual void makeMemberDataUniqueSubclass()
LeafData & operator=(const LeafData &)=delete
UT_ValArray< SIM_Data * > SIM_DataArray
This definition holds on to a collection of SIM_Data pointers.
This is the base class for all DOP nodes.
static void getDataTypeSuperclasses(UT_StringArray &)
GLint GLint GLint GLint GLint GLint GLint GLbitfield GLenum filter