The main database of sliceOmatic is composed of a tree of classes of type "SliceO_Class".
The root of the tree is of type "SliceO_Root", and the leaves of the tree are of type "SliceO_Frames". The parent class "SliceO_Class" and the 2 children "SlceO_Root" and "SliceO_Frame" are part of sliceOmatic. But all the other classes of the tree are defined in modules. You can add your own class to the tree.
When you create a new class, you need to define the class itself. It is derived from the parent class "SliceO_Class". It must contain at least a constructor. You will also need to provide the functions:
As mentioned, your class must provide a constructor, but it can also provide a number of methods to replace the default virtual ones. The methods you can override are:
With each instance of a class is associated a 32 bit "ID" flag. This flag contain an 8 bit "Magic" number (CLASS_MAGIC = 0xAA000000), an 8 bit class ID number (0x00010000 to 0x00FF0000), a 16 bit class instance number (0x00000000 to 0x0000FFFF).
The "Magic" and instance numbers are assigned by sliceOmatic, you must provide the class ID value. The values 0x00010000 to 0x000F0000 and 0x00FF0000 reserved for TomoVision. This leave the values 0x0010000 to 0x0FE0000 free for your use.
This ID is set with the method "Class_Class_Set()" and retrieved with the method "Class_Class_Get()".
The function "Class_ID_Get()" return both the class ID and its instance number. This make it the perfect function to uniquely identify a class instance.
A lot more information on the SliceO_Class class can be found here.