![]() |
Simplygon C++ API
8.3.35800.0
|
#include <SimplygonSDK.h>
Public Member Functions | |
virtual void | AppendArray (IArray *source)=0 |
virtual SGDEPRECATED void | AppendTuples (IArray *source)=0 |
virtual void | Clear ()=0 |
virtual int | CompareTuples (IArray *otherArray, rid tuple_id, rid other_tuple_id)=0 |
virtual void | CopyRange (IArray *source_array, rid start_dest_id, rid start_src_id, unsigned int count)=0 |
virtual void | CopyTuple (IArray *sourceArray, rid dest_id, rid src_id)=0 |
virtual void | DeepCopy (IArray *source)=0 |
virtual void | ExtractTuples (IArray *dest, rid start, unsigned int count)=0 |
virtual rstring | GetAlternativeName ()=0 |
virtual rid | GetBaseType ()=0 |
virtual const char * | GetClass () |
virtual unsigned int | GetItemCount ()=0 |
virtual rid | GetMaxItemId ()=0 |
virtual rid | GetMaxTupleId ()=0 |
virtual unsigned int | GetTupleCount ()=0 |
virtual unsigned int | GetTupleSize ()=0 |
virtual void | IndexedCopy (IArray *source, IRidArray *idtable, rid startId)=0 |
virtual bool | IsA (const char *type) const |
virtual bool | IsEmpty ()=0 |
virtual CountedPointer< IArray > | NewCopy (bool copy_data)=0 |
virtual CountedPointer< IArray > | NewPackedCopy (IRidArray *index_array)=0 |
virtual void | SetAlternativeName (const char *value)=0 |
virtual void | SetItemCount (unsigned int count)=0 |
virtual void | SetTupleCount (unsigned int tuplecount)=0 |
virtual void | SetTupleSize (unsigned int newsize)=0 |
![]() | |
virtual rid | AddObserver (robserver *Observer, rid EventId)=0 |
virtual void | AddRef ()=0 |
virtual rstring | GetName ()=0 |
virtual void * | GetUserComponentArea (rid userid)=0 |
virtual void | PrintInfo ()=0 |
virtual void | Release ()=0 |
virtual void | RemoveObserver (rid ObserverId)=0 |
virtual void | SetName (const char *Name)=0 |
Static Public Member Functions | |
static bool | IsClassA (const char *type) |
static IArray * | SafeCast (IObject *ptr) |
![]() | |
static bool | IsClassA (const char *type) |
static IObject * | SafeCast (IObject *ptr) |
IArray is the base class for the array objects. The object contains a dynamically allocated list of tuples of the same length, which can be specified before the list is filled with values.
Definition at line 1809 of file SimplygonSDK.h.
|
pure virtual |
Appends an array to this array. The array must be a descendant of ReValueArray. For best performance, append arrays of the same basic type.
source | the array to append to this array Value cannot be equal to null. |
|
pure virtual |
source | the array to append to this array. Value cannot be equal to null. |
|
pure virtual |
Clears the array and sets the tuple count to 0. Tuple size and name remains the same though.
|
pure virtual |
CompareTuples compares a tuple in this array with a tuple in another array
otherArray | the other array to compare with Value cannot be equal to null. |
tuple_id | the tuple from this array to use for comparison Value cannot be less than 0. Value cannot be greater than the value returned by GetMaxTupleId(). |
other_tuple_id | the tuple from the other array to use for comparison Value cannot be less than 0. |
|
pure virtual |
CopyRange copies a range of tuples from a source array into this array. The arrays must have the same tuple size and base type. This array must be resized to hold the tuples before copying. The basetypes are listed in SimplygonSDK::BaseTypes.
source_array | the source array to copy from |
start_dest_id | the first destination tuple id |
start_src_id | the first source tuple id |
count | the number of tuples to copy |
|
pure virtual |
CopyTuple copies one tuple in a source array to a tuple in this array. Both the dest_id and the source_id must exist in the arrays. This array can be used as the source array to copy within the array.
sourceArray | the source array to copy from Value cannot be equal to null. |
dest_id | the tuple index in this array to copy into Value cannot be less than 0. Value cannot be greater than the value returned by GetMaxTupleId(). |
src_id | the tuple index in the source array to copy from Value cannot be less than 0. |
|
pure virtual |
Copies data from another array. The arrays must have the same underlying data types.
source | the source array to copy from Value cannot be equal to null. |
|
pure virtual |
Extracts tuples from the array. Note that the destination array must have the same classtype and have the same tuple size as the source array. (If both arrays are decendants of ReValueArray, they can be of different types, but the conversion is slow).
dest | the array that will store the extracted tuples Value cannot be equal to null. |
start | this array tuple index where the extraction starts Value cannot be less than 0. Value cannot be greater than the value returned by GetMaxTupleId(). |
count | the number of tuples to extract Value cannot be greater than INT_MAX. |
|
pure virtual |
Get the AlternativeName, which can be used by users to set an alternative name to the array, when used as field data or in a collection.
|
pure virtual |
GetBaseType() returns the id of the basic type that the array is based on The ids are listed in the BaseTypes enumeration.
|
virtual |
GetClass returns the name of the class of the object.
Reimplemented from SimplygonSDK::IObject.
Reimplemented in SimplygonSDK::IUnsignedShortArray, SimplygonSDK::IUnsignedLongArray, SimplygonSDK::IUnsignedIntArray, SimplygonSDK::IUnsignedCharArray, SimplygonSDK::IShortArray, SimplygonSDK::IRidArray, SimplygonSDK::IRealArray, SimplygonSDK::ILongArray, SimplygonSDK::IIntArray, SimplygonSDK::IFloatArray, SimplygonSDK::IDoubleArray, SimplygonSDK::ICharArray, SimplygonSDK::IBoolArray, SimplygonSDK::IStringArray, and SimplygonSDK::IValueArray.
|
pure virtual |
Returns the number of items in the array Warning! Do not confuse this count with the count of tuples, they are only the same if TupleSize is equal to one, i.e. when the tuples are exactly one component each.
|
pure virtual |
Returns the id of the last item that is in the array. The id returned is equal to (ItemCount - 1). Warning! Do not confuse this id with the id of a tuple, they are only the same if TupleSize is equal to one, i.e. when the tuples are exactly one component each.
|
pure virtual |
Returns the id of the tuple last in the list. If the array is empty, the value is unspecified. Note: GetMaxTupleId() always returns (GetTupleCount()-1) as a signed id
|
pure virtual |
Returns the number of tuples in the list.
|
pure virtual |
Used to get the tuple size.
|
pure virtual |
Copies tuples from a source array through an id table. The id table dictates the order in which the tuples are to be copied to this array. E.g. If the first item in the id table has the value 14, then the tuple with id 14 in the source array will be copied to the first tuple in this array. Note: All ids in the id table must be valid ids of tuples in the source array. The id table is assumed to have a tuple size of 1. The source array and this array must have the same underlying data type, and have the same tuple size. The array must be large enough to hold the copied data.
source | is the array from which to copy tuples Value cannot be equal to null. |
idtable | is the array with the tuple indices to copy Value cannot be equal to null. |
startId | is the first tuple that will receive the copied values |
|
virtual |
The IsA function returns true if the object is a or is a descendant of the class named as the type parameter
type | is the name of the class to check if the object is, or is a descendant of |
Reimplemented from SimplygonSDK::IObject.
Reimplemented in SimplygonSDK::IUnsignedShortArray, SimplygonSDK::IUnsignedLongArray, SimplygonSDK::IUnsignedIntArray, SimplygonSDK::IUnsignedCharArray, SimplygonSDK::IShortArray, SimplygonSDK::IRidArray, SimplygonSDK::IRealArray, SimplygonSDK::ILongArray, SimplygonSDK::IIntArray, SimplygonSDK::IFloatArray, SimplygonSDK::IDoubleArray, SimplygonSDK::ICharArray, SimplygonSDK::IBoolArray, SimplygonSDK::IStringArray, and SimplygonSDK::IValueArray.
|
inlinestatic |
The IsClassA function returns true if IArray is a or is a descendant of the class named as the type parameter
type | is the name of the class to check if the class is, or is a descendant of |
Definition at line 1830 of file SimplygonSDK.h.
|
pure virtual |
Returns true if the list is empty.
|
pure virtual |
Creates a new array with the same underlying data type, size and tuple settings as this array. To also copy the actual data, set copy_data to true.
copy_data | If set, duplicate all the data. If cleared, return an empty array of the same type. |
|
pure virtual |
Like NewCopy, NewPackedCopy creates an array with the same underlying data and tuple settings as the source array. However, NewPackedCopy only copies unique tuples, and if the index_array parameter is set, this index array will contain the same number of tuples as the source array, and with the ids of a specific tuples within the new copy of the array.
index_array | the optional array that will receive the indices of the remapped tuples. |
SafeCast makes sure the pointer is of a class that can be cast into a IArray pointer, and if this is possible, returns the cast pointer.
ptr | is the pointer to be cast into a IArray pointer |
Definition at line 1843 of file SimplygonSDK.h.
|
pure virtual |
Set the AlternativeName, which can be used by users to set an alternative name to the array, when used as field data or in a collection.
value | the new alternative name |
|
pure virtual |
Resizes the list of items to the exact count specified. Warning! Do not confuse this count with the count of tuples, they are only the same if TupleSize is equal to 1, i.e. when the tuples are exactly one component each. Also note that the item count should be a multiple of TupleSize. Note that the total number of items cannot exceed INT_MAX.
count | the new number of items. Value cannot be greater than INT_MAX. |
|
pure virtual |
Resizes the list to the specified tuple count. If the list is enlarged, the new tuples will contain unspecified data. Note that the item count equals TupleCount multiplied by TupleSize and that the total number of items cannot exceed INT_MAX.
tuplecount | the new tuple count Value cannot be greater than INT_MAX. |
|
pure virtual |
Used to set the tuple size. Warning! Only use SetTupleSize before filling the list with values, as any added data in the array will be trashed.
newsize | the new tuple size Value cannot be less than 1. Value cannot be greater than 1024. |