HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GA_ElementGroup Class Reference

#include <GA_ATIGroupBool.h>

+ Inheritance diagram for GA_ElementGroup:

Public Member Functions

virtual const GA_DetailgetDetail () const final
 
GA_DetailgetDetail ()
 
 GA_ElementGroup (const GA_Detail &detail, GA_AttributeOwner owner)
 
virtual ~GA_ElementGroup ()
 
virtual int64 getMemoryUsage (bool inclusive) const
 
virtual void countMemory (UT_MemoryCounter &counter, bool inclusive) const
 
virtual bool isOrdered () const final
 Returns true if the group is currently ordered. More...
 
bool setOrdered (bool ordered)
 
void makeOrdered ()
 
void makeUnordered ()
 
void clearOrdered ()
 Clear all order information, including any mixed entries. More...
 
bool copyMembership (const GA_ATIGroupBool &src, bool copy_ordering=true)
 
GA_Offset findOffsetAtGroupIndex (GA_Size i) const
 
SYS_FORCE_INLINE void setElement (GA_Offset ai, bool v)
 
SYS_FORCE_INLINE void setElement (const GA_Range &it, bool v)
 NOTE: This cannot be used in parallel on an ordered group. More...
 
void toggleElement (GA_Offset ai)
 
void toggleElement (const GA_Range &it)
 NOTE: This cannot be used in parallel on an ordered group. More...
 
virtual bool combine (const GA_Group *src) final
 
GA_ElementGroupoperator|= (const GA_ElementGroup &g)
 
SYS_FORCE_INLINE bool contains (GA_Offset offset) const
 
bool containsIndex (GA_Index ai) const
 
SYS_FORCE_INLINE bool containsOffset (GA_Offset offset) const
 
SYS_FORCE_INLINE bool containsAny (const GA_Range &range) const
 
SYS_FORCE_INLINE bool isGroupEmpty () const
 
SYS_FORCE_INLINE bool isEmpty () const
 Query whether the group is empty of primary elements. More...
 
bool isEmptyMix () const
 Query whether the group is empty of elements, primary or mixed. More...
 
virtual GA_Size entries () const final
 Will return the number of primary elements. More...
 
virtual GA_Size entriesMix () const final
 Will return the total number of elements, primary and mixed. More...
 
GA_Size getGroupEntries () const
 
GA_Size computeGroupEntries () const
 
virtual bool isMixed () const final
 Query if the group contains any mixed elements. More...
 
SYS_FORCE_INLINE void setOffset (GA_Offset ai, bool v)
 
void getConstantSpan (GA_Offset start, GA_Offset end, GA_Size &size, bool &value) const
 
void clear ()
 
void makeConstant (bool value)
 
void invalidateGroupEntries ()
 
virtual bool needDestruction () const
 Methods which can be overridden from GA_Attribute. More...
 
virtual void destructElement (GA_Offset offset)
 Callback invoked if needsDestruction() returns true. More...
 
virtual void reconstructElementBlock (GA_Offset offset, GA_Offset nelements)
 
virtual void addAll () final
 Add all elements to the group. More...
 
void setEntries ()
 Add all elements to the group, only writing to real elements' offsets. More...
 
void toggleEntries ()
 Toggle membership of all elements. More...
 
virtual WriteConcurrence getSupportedWriteConcurrence () const
 
virtual const GA_AIFCopyDatagetAIFCopyData () const
 Return the attribute's copy interface or NULL. More...
 
virtual const GA_AIFTuplegetAIFTuple () const
 Return the attribute's tuple interface or NULL. More...
 
virtual const GA_AIFInterp * getAIFInterp () const
 Return the attribute's interpolation interface or NULL. More...
 
virtual const GA_AIFMergegetAIFMerge () const
 Return the attribute's merge interface or NULL. More...
 
GA_ElementGroupOrdergetOrdered ()
 
const GA_ElementGroupOrdergetOrdered () const
 
GA_ElementGroupgetGroup ()
 
const GA_ElementGroupgetGroup () const
 
GA_ElementGroupgetAttribute ()
 
const GA_ElementGroupgetAttribute () const
 
bool loadGroupH9 (UT_IStream &is)
 
bool loadGroupByIndexOrderH9 (const UT_BitArray &array)
 
bool saveGroupH9 (std::ostream &os, bool binary) const
 
virtual bool debugValidateArrayCapacity (GA_Offset sz) const
 Debug validation of allocated array size. More...
 
bool jsonSave (UT_JSONWriter &w, const GA_SaveMap &map) const
 
bool jsonLoad (UT_JSONParser &p, const GA_LoadMap &map)
 Load from a JSON stream. More...
 
virtual bool jsonSaveData (UT_JSONWriter &w, const GA_SaveMap &map) const
 
virtual bool jsonLoadData (UT_JSONParser &p, const GA_LoadMap &map)
 Load from a JSON stream. More...
 
virtual bool stat (UT_WorkBuffer &info, uint level) const
 Compute detailed information. More...
 
virtual bool setArraySize (GA_Offset new_size)
 Grow or shrink the array size. More...
 
GA_Offset getArraySize () const
 
SYS_FORCE_INLINE GA_DataBitArraygetData ()
 
SYS_FORCE_INLINE const
GA_DataBitArray
getData () const
 Returns the read-only raw bit array. More...
 
SYS_FORCE_INLINE bool isPageConstant (GA_PageNum pagenum) const
 
SYS_FORCE_INLINE bool getPageValue (GA_PageNum pagenum) const
 
SYS_FORCE_INLINE void setPageConstant (GA_PageNum pagenum, const bool value)
 Sets all elements of the specified page to the given value. More...
 
virtual void tryCompressAllPages (GA_Offset start_offset=GA_Offset(0), GA_Offset end_offset=GA_INVALID_OFFSET)
 Try to compress data pages. More...
 
virtual void hardenAllPages (GA_Offset start_offset=GA_Offset(0), GA_Offset end_offset=GA_INVALID_OFFSET)
 Harden data pages. More...
 
virtual void copyNonStorageMetadata (const GA_Attribute *that) final
 
virtual void replace (const GA_Attribute &src) final
 
virtual void defragment (const GA_Defragment &defrag)
 
void orEqual (const GA_ATIGroupBool *src)
 
void andEqual (const GA_ATIGroupBool *src)
 
void xorEqual (const GA_ATIGroupBool *src)
 
void subEqual (const GA_ATIGroupBool *src)
 
void toggleAll (GA_Size numelements)
 
GA_ElementGroupoperator&= (const GA_ElementGroup &g)
 
GA_ElementGroupoperator-= (const GA_ElementGroup &g)
 
GA_ElementGroupoperator^= (const GA_ElementGroup &g)
 
GA_ElementGroupoperator= (const GA_ElementGroup &g)
 
SYS_FORCE_INLINE void addIndex (GA_Index ai)
 
SYS_FORCE_INLINE void toggleIndex (GA_Index ai)
 
SYS_FORCE_INLINE void removeIndex (GA_Index ai)
 
SYS_FORCE_INLINE void addOffset (GA_Offset ai)
 
SYS_FORCE_INLINE void toggleOffset (GA_Offset ai)
 
SYS_FORCE_INLINE void removeOffset (GA_Offset ai)
 
SYS_FORCE_INLINE void addRange (const GA_Range &it)
 
SYS_FORCE_INLINE void toggleRange (const GA_Range &it)
 
SYS_FORCE_INLINE void removeRange (const GA_Range &it)
 
virtual bool copy (GA_Offset desti, GA_Offset srci) final
 
virtual bool copy (GA_Offset desti, const GA_Attribute &src, GA_Offset srci) final
 
bool copy (GA_Offset desti, const GA_ATIGroupBool &src, GA_Offset srci)
 
virtual bool copy (const GA_Range &destrange, const GA_Range &srcrange) final
 
virtual bool copy (const GA_Range &destrange, const GA_Attribute &src, const GA_Range &srcrange) final
 
bool copy (const GA_Range &destrange, const GA_ATIGroupBool &src, const GA_Range &srcrange)
 
virtual bool fill (const GA_Range &destrange, GA_Offset srci) final
 
virtual bool fill (const GA_Range &destrange, const GA_Attribute &src, GA_Offset srci) final
 
bool fill (const GA_Range &destrange, const GA_ATIGroupBool &src, GA_Offset srci)
 
- Public Member Functions inherited from GA_Attribute
 GA_Attribute (const GA_AttributeType &type, const GA_IndexMap &index_map, GA_AttributeScope scope, const UT_StringHolder &name)
 
virtual ~GA_Attribute ()
 
const GA_AttributeTypegetType () const
 
const GA_IndexMapgetIndexMap () const
 
const GA_DetailgetDetail () const
 
GA_DetailgetDetail ()
 
GA_AttributeOwner getOwner () const
 
GA_AttributeScope getScope () const
 
SYS_FORCE_INLINE GA_TypeInfo getTypeInfo () const
 
SYS_FORCE_INLINE void setTypeInfo (GA_TypeInfo type)
 
bool shouldInterpretAsTexCoord (bool allow_float2=false) const
 
GA_StorageClass getStorageClass () const
 Returns the approximate type of the attribute. More...
 
int getTupleSize () const
 Size of the AIFTuple, if it exists. If it doesn't, 1. More...
 
const UT_StringHoldergetName () const
 
const UT_StringHoldergetFullName () const
 
SYS_FORCE_INLINE GA_DataId getDataId () const
 
SYS_FORCE_INLINE void assignNewDataId ()
 
SYS_FORCE_INLINE void bumpDataId ()
 
SYS_FORCE_INLINE void clearDataId ()
 
SYS_FORCE_INLINE void cloneDataId (const GA_Attribute &src, bool allow_clear=false)
 
SYS_FORCE_INLINE void cloneOrBumpDataId (const GA_Attribute &src, bool allow_clear=false)
 NOTE: Just call cloneDataId(src). More...
 
virtual const GA_AIFDeltagetAIFDelta () const
 Return the attribute's delta interface or NULL. More...
 
virtual const GA_AIFMathgetAIFMath () const
 Return the attribute's math interface or NULL. More...
 
virtual const GA_AIFBlobgetAIFBlob () const
 Return the attribute's blob interface or NULL. More...
 
virtual const GA_AIFBlobArraygetAIFBlobArray () const
 Return the attribute's blob array interface or NULL. More...
 
virtual const GA_AIFStringTuplegetAIFStringTuple () const
 Return the attribute's string tuple interface or NULL. More...
 
virtual const
GA_AIFSharedStringTuple
getAIFSharedStringTuple () const
 Return the attribute's shared string tuple interface or NULL. More...
 
virtual const
GA_AIFSharedStringArray
getAIFSharedStringArray () const
 Return the attribute's shared string array interface or NULL. More...
 
virtual const GA_AIFIndexPairgetAIFIndexPair () const
 Return the attribute's index pair interface or NULL. More...
 
virtual const GA_AIFBlindDatagetAIFBlindData () const
 Return the attribute's blind data interface or NULL. More...
 
virtual const GA_AIFEditgetAIFEdit () const
 Return the attribute's edit interface or NULL. More...
 
virtual const GA_AIFComparegetAIFCompare () const
 Return the attribute's comparison interface or NULL. More...
 
virtual const GA_AIFNumericArraygetAIFNumericArray () const
 Return the attribute's arraydata interface or NULL. More...
 
virtual const GA_AIFStatgetAIFStat () const
 
template<typename T >
const TgetAIF () const
 Generic method for getting an AIF by type. More...
 
const GA_AttributeOptionsgetOptions () const
 
GA_AttributeOptionsgetOptions ()
 
void setNonTransforming (bool val)
 
bool needsTransform (bool include_P=true) const
 
bool isDetached () const
 
void mergeOptions (const GA_AttributeOptions &src)
 Merge the options passed in with the options in the attribute. More...
 
bool importOption (const char *name, int &v) const
 
bool importOption (const char *name, bool &v) const
 
bool importOption (const char *name, fpreal32 &v) const
 
bool importOption (const char *name, fpreal64 &v) const
 
bool importOption (const char *name, UT_String &v) const
 
void setTailInitialization (bool onoff)
 
bool isTailInitialization () const
 Check whether the attribute is set to tail initialization. More...
 
void reconstructElement (GA_Offset offset)
 
virtual void compactStorage ()
 
virtual void batchDeletion ()
 
GA_Attributeclone (const GA_IndexMap &index_map, const UT_StringHolder &name, bool clone_options) const
 
bool jsonSaveDefinition (UT_JSONWriter &w) const
 Save the GA_Attribute-Definition section. More...
 
virtual const GA_AIFJSONgetAIFJSON () const
 Return the AIF to handle saving/loading of the private data section. More...
 
virtual int getSaveVersion () const
 
virtual bool matchesStorage (const GA_Attribute *that) const
 
GA_AttributeProxyHandle getProxy ()
 
GA_ConstAttributeProxyHandle getProxy () const
 
void setExportName (const char *external_name)
 
bool hasExportName () const
 
std::string getExportName () const
 
GA_CEAttributegetCEAttribute (GA_StorageClass storage, int &tuplesize, bool isarray, bool read, bool write)
 
void flushCEWriteCaches (bool clearwriteback=true)
 
bool hasPendingCEWriteBack () const
 
void flushCECaches ()
 Remove all CE Caches, copying back any marked as written to. More...
 
- Public Member Functions inherited from GA_Group
virtual ~GA_Group ()
 
const UT_StringHoldergetName () const
 
bool isInternal () const
 
bool getInternal () const
 
void setInternal (bool onOff)
 
bool isDetached () const
 
GA_GroupType classType (void) const
 
GA_GroupMaskType classMaskType () const
 
bool isElementGroup () const
 
SYS_FORCE_INLINE bool isEmpty () const
 
void clearEntries ()
 
virtual bool jsonShouldSave (const GA_SaveMap &map) const
 
bool jsonSaveDefinition (UT_JSONWriter &w, const char *type) const
 
void dump (std::ostream &os)
 A convenience function to do a JSON dump of the group contents. More...
 

Static Public Member Functions

static void registerType ()
 
static SYS_FORCE_INLINE const
UT_StringHolder
getTypeName ()
 
static SYS_FORCE_INLINE const
GA_AttributeType
getType ()
 
static SYS_FORCE_INLINE bool isType (const GA_Attribute *attrib)
 
static SYS_FORCE_INLINE
GA_ATIGroupBool
cast (GA_Attribute *attrib)
 
static SYS_FORCE_INLINE const
GA_ATIGroupBool
cast (const GA_Attribute *attrib)
 
static SYS_FORCE_INLINE bool isType (const GA_Group *group)
 
static SYS_FORCE_INLINE const
GA_ElementGroup
cast (const GA_Group *group)
 
static SYS_FORCE_INLINE
GA_ElementGroup
cast (GA_Group *group)
 
- Static Public Member Functions inherited from GA_Attribute
static bool jsonLoadDefinition (UT_JSONParser &p, GA_AttributeScope &scope, UT_WorkBuffer &type, UT_WorkBuffer &name, int64 &version, GA_AttributeOptions &options)
 Load the GA_Attribute-Definition section. More...
 
static GA_DataId nextDataId ()
 
- Static Public Member Functions inherited from GA_Group
static const char * groupType (GA_GroupType type)
 
static GA_GroupType groupType (const char *type)
 
static bool jsonLoadDefinition (UT_JSONParser &p, UT_WorkBuffer &type, UT_WorkBuffer &name, bool &internal)
 Load the GA_Group-Definition. More...
 

Protected Member Functions

 GA_ElementGroup (GA_Detail &detail, GA_AttributeOwner owner, const UT_StringHolder &name, bool internal, bool detached)
 
- Protected Member Functions inherited from GA_Attribute
int64 getBaseMemoryUsage () const
 
void setDetached (bool detached)
 Only called by GA_AttributeSet and GA_ElementGroup. More...
 
- Protected Member Functions inherited from GA_Group
 GA_Group (const UT_StringHolder &name, bool internal, GA_GroupType type, bool detached)
 

Friends

class GU_Group
 
class GU_ElementGroup
 
class GOP_GroupParse
 

Additional Inherited Members

- Public Types inherited from GA_Attribute
enum  WriteConcurrence { WRITE_CONCURRENCE_NONE, WRITE_CONCURRENCE_PAGE, WRITE_CONCURRENCE_ELEMENT }
 

Detailed Description

Definition at line 54 of file GA_ATIGroupBool.h.

Constructor & Destructor Documentation

GA_ElementGroup::GA_ElementGroup ( GA_Detail detail,
GA_AttributeOwner  owner,
const UT_StringHolder name,
bool  internal,
bool  detached 
)
protected
GA_ElementGroup::GA_ElementGroup ( const GA_Detail detail,
GA_AttributeOwner  owner 
)
virtual GA_ElementGroup::~GA_ElementGroup ( )
virtual

Member Function Documentation

virtual void GA_ElementGroup::addAll ( )
inlinefinalvirtual

Add all elements to the group.

Implements GA_Group.

Definition at line 413 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::addIndex ( GA_Index  ai)
inline

Access elements of the group by ordered index rather than offset. Internally, this method just find the data offset and calls appropriate method.

Definition at line 326 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::addOffset ( GA_Offset  ai)
inline

Access elements by their offset in the index map NOTE: When using addOffset, toggleOffset, removeOffset in parallel, you must call invalidateGroupEntries() afterward, else entries() may return an incorrect value. NOTE: These cannot be used in parallel on an ordered group.

Definition at line 352 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::addRange ( const GA_Range it)
inline

Access elements by a GA_Range These have the advantage of being able to operate a page at a time when applicable. NOTE: These cannot be used in parallel on an ordered group.

Definition at line 377 of file GA_ATIGroupBool.h.

void GA_ElementGroup::andEqual ( const GA_ATIGroupBool src)

These methods only work on unordered groups.

static SYS_FORCE_INLINE GA_ATIGroupBool* GA_ElementGroup::cast ( GA_Attribute attrib)
inlinestatic

Definition at line 87 of file GA_ATIGroupBool.h.

static SYS_FORCE_INLINE const GA_ATIGroupBool* GA_ElementGroup::cast ( const GA_Attribute attrib)
inlinestatic

Definition at line 94 of file GA_ATIGroupBool.h.

static SYS_FORCE_INLINE const GA_ElementGroup* GA_ElementGroup::cast ( const GA_Group group)
inlinestatic

Definition at line 109 of file GA_ATIGroupBool.h.

static SYS_FORCE_INLINE GA_ElementGroup* GA_ElementGroup::cast ( GA_Group group)
inlinestatic

Definition at line 116 of file GA_ATIGroupBool.h.

void GA_ElementGroup::clear ( )
virtual

Implements GA_Group.

void GA_ElementGroup::clearOrdered ( )

Clear all order information, including any mixed entries.

virtual bool GA_ElementGroup::combine ( const GA_Group src)
finalvirtual

Add all elements corresponding with src to this group. src can be a point, vertex, primitive, or edge group. Breakpoint groups won't crash, but may add more elements than required.

Reimplemented from GA_Group.

GA_Size GA_ElementGroup::computeGroupEntries ( ) const
SYS_FORCE_INLINE bool GA_ElementGroup::contains ( GA_Offset  offset) const
inline

Definition at line 253 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE bool GA_ElementGroup::containsAny ( const GA_Range range) const
inline

Definition at line 269 of file GA_ATIGroupBool.h.

bool GA_ElementGroup::containsIndex ( GA_Index  ai) const
inline

Definition at line 257 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE bool GA_ElementGroup::containsOffset ( GA_Offset  offset) const
inline
Examples:
tetprim/GEO_PrimTetra.C.

Definition at line 264 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::copy ( GA_Offset  desti,
GA_Offset  srci 
)
inlinefinalvirtual

Copy attribute values for a single element.

Reimplemented from GA_Attribute.

Definition at line 602 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::copy ( GA_Offset  desti,
const GA_Attribute src,
GA_Offset  srci 
)
inlinefinalvirtual

Copy attribute values for a single element.

Reimplemented from GA_Attribute.

Definition at line 607 of file GA_ATIGroupBool.h.

bool GA_ElementGroup::copy ( GA_Offset  desti,
const GA_ATIGroupBool src,
GA_Offset  srci 
)
inline

Copy attribute values for a single element.

Definition at line 614 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::copy ( const GA_Range destrange,
const GA_Range srcrange 
)
inlinefinalvirtual

Copy attribute values for a range of elements.

Reimplemented from GA_Attribute.

Definition at line 623 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::copy ( const GA_Range destrange,
const GA_Attribute src,
const GA_Range srcrange 
)
inlinefinalvirtual

Copy attribute values for a range of elements.

Reimplemented from GA_Attribute.

Definition at line 627 of file GA_ATIGroupBool.h.

bool GA_ElementGroup::copy ( const GA_Range destrange,
const GA_ATIGroupBool src,
const GA_Range srcrange 
)
inline

Copy attribute values for a range of elements.

Definition at line 633 of file GA_ATIGroupBool.h.

bool GA_ElementGroup::copyMembership ( const GA_ATIGroupBool src,
bool  copy_ordering = true 
)

Copy membership information from the source group. This will fail if the groups have different index maps. This will also copy over the ordered information if copy_ordering is set to true.

virtual void GA_ElementGroup::copyNonStorageMetadata ( const GA_Attribute that)
finalvirtual

In the case that we're copying from an attribute whose storage type matches this exactly, this function copies the metadata not associated with the storage, e.g. myOptions, excluding the name and the data ID.

Reimplemented from GA_Attribute.

virtual void GA_ElementGroup::countMemory ( UT_MemoryCounter counter,
bool  inclusive 
) const
virtual

Count memory usage using a UT_MemoryCounter in order to count shared memory correctly. If inclusive is true, the size of this object is counted, else only memory owned by this object is counted. If this is pointed to by the calling object, inclusive should be true. If this is contained in the calling object, inclusive should be false. (Its memory was already counted in the size of the calling object.)

NOTE: If you're implementing this in a direct subclass of GA_Attribute, call getBaseMemoryUsage() to get the amount of memory in the base class. If in a more distant descendant class, call Base::countMemory(counter, false) to count the memory in Base and above, excluding sizeof(Base).

Implements GA_Attribute.

virtual bool GA_ElementGroup::debugValidateArrayCapacity ( GA_Offset  sz) const
virtual

Debug validation of allocated array size.

Reimplemented from GA_Attribute.

virtual void GA_ElementGroup::defragment ( const GA_Defragment defrag)
virtual

Interface for defragmentation

Implements GA_Attribute.

virtual void GA_ElementGroup::destructElement ( GA_Offset  offset)
virtual

Callback invoked if needsDestruction() returns true.

Reimplemented from GA_Attribute.

virtual GA_Size GA_ElementGroup::entries ( ) const
inlinefinalvirtual

Will return the number of primary elements.

Implements GA_Group.

Definition at line 290 of file GA_ATIGroupBool.h.

virtual GA_Size GA_ElementGroup::entriesMix ( ) const
inlinefinalvirtual

Will return the total number of elements, primary and mixed.

Definition at line 293 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::fill ( const GA_Range destrange,
GA_Offset  srci 
)
inlinefinalvirtual

Assign all elements of a range from a single attribute value.

Reimplemented from GA_Attribute.

Definition at line 641 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::fill ( const GA_Range destrange,
const GA_Attribute src,
GA_Offset  srci 
)
inlinefinalvirtual

Assign all elements of a range from a single attribute value.

Reimplemented from GA_Attribute.

Definition at line 646 of file GA_ATIGroupBool.h.

bool GA_ElementGroup::fill ( const GA_Range destrange,
const GA_ATIGroupBool src,
GA_Offset  srci 
)
inline

Assign all elements of a range from a single attribute value.

Definition at line 653 of file GA_ATIGroupBool.h.

GA_Offset GA_ElementGroup::findOffsetAtGroupIndex ( GA_Size  i) const

Return GA offset of the Nth element of the group. NOTE: This may be quite expensive to compute. Returns GA_INVALID_OFFSET if there aren't enough elements in the group.

virtual const GA_AIFCopyData* GA_ElementGroup::getAIFCopyData ( ) const
inlinevirtual

Return the attribute's copy interface or NULL.

Reimplemented from GA_Attribute.

Definition at line 437 of file GA_ATIGroupBool.h.

virtual const GA_AIFInterp* GA_ElementGroup::getAIFInterp ( ) const
inlinevirtual

Return the attribute's interpolation interface or NULL.

Reimplemented from GA_Attribute.

Definition at line 439 of file GA_ATIGroupBool.h.

virtual const GA_AIFMerge* GA_ElementGroup::getAIFMerge ( ) const
inlinevirtual

Return the attribute's merge interface or NULL.

Reimplemented from GA_Attribute.

Definition at line 440 of file GA_ATIGroupBool.h.

virtual const GA_AIFTuple* GA_ElementGroup::getAIFTuple ( ) const
inlinevirtual

Return the attribute's tuple interface or NULL.

Reimplemented from GA_Attribute.

Definition at line 438 of file GA_ATIGroupBool.h.

GA_Offset GA_ElementGroup::getArraySize ( ) const
inline

Get the array size of the attribute. This is primarily here for checking detached groups, when the detail may have more elements added since the group was created.

Definition at line 533 of file GA_ATIGroupBool.h.

GA_ElementGroup* GA_ElementGroup::getAttribute ( )
inline

Definition at line 447 of file GA_ATIGroupBool.h.

const GA_ElementGroup* GA_ElementGroup::getAttribute ( ) const
inline

Definition at line 448 of file GA_ATIGroupBool.h.

void GA_ElementGroup::getConstantSpan ( GA_Offset  start,
GA_Offset  end,
GA_Size size,
bool &  value 
) const
inline

Query the length of repeated bit values starting from 'start' until 'end' or a change in bit values.

Definition at line 396 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE GA_DataBitArray& GA_ElementGroup::getData ( )
inline

Returns the writable raw bit array. WARNING: Only use this if this is an unordered group, and invalidateGroupEntries() has been called, so that writing doesn't cause problems.

Definition at line 541 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE const GA_DataBitArray& GA_ElementGroup::getData ( ) const
inline

Returns the read-only raw bit array.

Definition at line 549 of file GA_ATIGroupBool.h.

virtual const GA_Detail& GA_ElementGroup::getDetail ( ) const
inlinefinalvirtual

Implements GA_Group.

Definition at line 64 of file GA_ATIGroupBool.h.

GA_Detail& GA_ElementGroup::getDetail ( )
inline

Definition at line 68 of file GA_ATIGroupBool.h.

GA_ElementGroup* GA_ElementGroup::getGroup ( )
inline

Definition at line 445 of file GA_ATIGroupBool.h.

const GA_ElementGroup* GA_ElementGroup::getGroup ( ) const
inline

Definition at line 446 of file GA_ATIGroupBool.h.

GA_Size GA_ElementGroup::getGroupEntries ( ) const
inline

Definition at line 300 of file GA_ATIGroupBool.h.

virtual int64 GA_ElementGroup::getMemoryUsage ( bool  inclusive) const
virtual

Report the memory usage

NOTE: If you're implementing this in a direct subclass of GA_Attribute, call getBaseMemoryUsage() to get the amount of memory in the base class. If in a more distant descendant class, call Base::getMemoryUsage(false) to count the memory in Base and above, excluding sizeof(Base).

Implements GA_Attribute.

GA_ElementGroupOrder* GA_ElementGroup::getOrdered ( )
inline

Definition at line 443 of file GA_ATIGroupBool.h.

const GA_ElementGroupOrder* GA_ElementGroup::getOrdered ( ) const
inline

Definition at line 444 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE bool GA_ElementGroup::getPageValue ( GA_PageNum  pagenum) const
inline

If pagenum is a constant page, this returns the constant value of the page. Otherwise, this function shouldn't be called.

Definition at line 563 of file GA_ATIGroupBool.h.

virtual WriteConcurrence GA_ElementGroup::getSupportedWriteConcurrence ( ) const
inlinevirtual

Data is paged, so concurrent writes to separate pages supported, unless the group is ordered. Rather, that would be the case if the updates to myGroupEntries were thread-safe.

Implements GA_Attribute.

Definition at line 434 of file GA_ATIGroupBool.h.

static SYS_FORCE_INLINE const GA_AttributeType& GA_ElementGroup::getType ( void  )
inlinestatic

Definition at line 79 of file GA_ATIGroupBool.h.

static SYS_FORCE_INLINE const UT_StringHolder& GA_ElementGroup::getTypeName ( )
inlinestatic

Definition at line 76 of file GA_ATIGroupBool.h.

virtual void GA_ElementGroup::hardenAllPages ( GA_Offset  start_offset = GA_Offset(0),
GA_Offset  end_offset = GA_INVALID_OFFSET 
)
virtual

Harden data pages.

Implements GA_Attribute.

void GA_ElementGroup::invalidateGroupEntries ( )
inline

Definition at line 405 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE bool GA_ElementGroup::isEmpty ( ) const
inline

Query whether the group is empty of primary elements.

Examples:
SOP/SOP_Flatten.C, and SOP/SOP_PointWave.C.

Definition at line 280 of file GA_ATIGroupBool.h.

bool GA_ElementGroup::isEmptyMix ( ) const
inline

Query whether the group is empty of elements, primary or mixed.

Definition at line 285 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE bool GA_ElementGroup::isGroupEmpty ( ) const
inline

Definition at line 274 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::isMixed ( ) const
inlinefinalvirtual

Query if the group contains any mixed elements.

Implements GA_Group.

Definition at line 310 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::isOrdered ( ) const
inlinefinalvirtual

Returns true if the group is currently ordered.

Implements GA_Group.

Definition at line 140 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE bool GA_ElementGroup::isPageConstant ( GA_PageNum  pagenum) const
inline

Returns true iff the specified page is constant-compressed, where a single value is stored to represent GA_PAGE_SIZE values in the page, (or possibly fewer if only one page).

Definition at line 557 of file GA_ATIGroupBool.h.

static SYS_FORCE_INLINE bool GA_ElementGroup::isType ( const GA_Attribute attrib)
inlinestatic

Definition at line 82 of file GA_ATIGroupBool.h.

static SYS_FORCE_INLINE bool GA_ElementGroup::isType ( const GA_Group group)
inlinestatic

Definition at line 101 of file GA_ATIGroupBool.h.

bool GA_ElementGroup::jsonLoad ( UT_JSONParser p,
const GA_LoadMap map 
)

Load from a JSON stream.

virtual bool GA_ElementGroup::jsonLoadData ( UT_JSONParser p,
const GA_LoadMap map 
)
virtual

Load from a JSON stream.

Implements GA_Group.

bool GA_ElementGroup::jsonSave ( UT_JSONWriter w,
const GA_SaveMap map 
) const

Save data to a JSON file. We do not provide an GA_AIFJSON interface since the data is saved by the group (not the attribute). This method is called directly by GA_ElementGroup instead.

JSON Schema: GA_ATIGroupBool

{
"name" : "GA_ATIGroupBool",
"description" :
"Selection information for a GA_ElementGroup. There should
only be one of 'ordered' or 'unordered' depending on
whether the group is ordered or unordered.",
"type" : "orderedmap",
"properties": {
"defaults": {
"type" : { "$ref" : "GA_Defaults" }
"description" : "Default values",
},
"ordered": {
"type" : {"$ref":"GA_ElementGroupOrder"},
"optional" : true,
"description" : "Ordered group selection.",
},
"unordered": {
"type" : {"$ref":"GA_DataBitArray"},
"optional" : true,
"description" : "Unordered selection of group selection.",
},
},
}
See Also
JSON_FileFormat
virtual bool GA_ElementGroup::jsonSaveData ( UT_JSONWriter w,
const GA_SaveMap map 
) const
virtual

Save data to a JSON stream.

JSON Schema: GA_ElementGroup

Private data for an element group

{
"name" : "GA_ElementGroup-Data",
"description" : "Data for an element group.",
"type" : "orderedmap",
"properties": {
"selection": {
"type" : {"$ref" : "GA_ATIGroupBool" },
"description" : "Group memebership data",
"optional" : true
}
},
}
See Also
JSON_FileFormat, GA_GroupTable

Implements GA_Group.

bool GA_ElementGroup::loadGroupByIndexOrderH9 ( const UT_BitArray array)
bool GA_ElementGroup::loadGroupH9 ( UT_IStream is)
void GA_ElementGroup::makeConstant ( bool  value)
void GA_ElementGroup::makeOrdered ( )
void GA_ElementGroup::makeUnordered ( )
inline

Definition at line 167 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::needDestruction ( ) const
virtual

Methods which can be overridden from GA_Attribute.

Element destruction event. When an element is destroyed, the attribute may be notified of this event.

Reimplemented from GA_Attribute.

GA_ElementGroup& GA_ElementGroup::operator&= ( const GA_ElementGroup g)

These operators only support g having the same owner as this.

GA_ElementGroup& GA_ElementGroup::operator-= ( const GA_ElementGroup g)

These operators only support g having the same owner as this.

GA_ElementGroup& GA_ElementGroup::operator= ( const GA_ElementGroup g)
inline

These operators only support g having the same owner as this.

Definition at line 245 of file GA_ATIGroupBool.h.

GA_ElementGroup& GA_ElementGroup::operator^= ( const GA_ElementGroup g)

These operators only support g having the same owner as this.

GA_ElementGroup& GA_ElementGroup::operator|= ( const GA_ElementGroup g)

operator|= supports point, vertex, and primitive groups, regardless of this group type.

void GA_ElementGroup::orEqual ( const GA_ATIGroupBool src)

These methods only work on unordered groups.

virtual void GA_ElementGroup::reconstructElementBlock ( GA_Offset  offset,
GA_Offset  nelements 
)
virtual

When the array size is grown, attributes should initialize the value appropriately. When elements are reused, however, reconstructElementBlock is called. This happens if an element is deleted and then a new element is allocated (using the existing slot)

Reimplemented from GA_Attribute.

static void GA_ElementGroup::registerType ( )
static
SYS_FORCE_INLINE void GA_ElementGroup::removeIndex ( GA_Index  ai)
inline

Access elements of the group by ordered index rather than offset. Internally, this method just find the data offset and calls appropriate method.

Definition at line 338 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::removeOffset ( GA_Offset  ai)
inline

Access elements by their offset in the index map NOTE: When using addOffset, toggleOffset, removeOffset in parallel, you must call invalidateGroupEntries() afterward, else entries() may return an incorrect value. NOTE: These cannot be used in parallel on an ordered group.

Definition at line 364 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::removeRange ( const GA_Range it)
inline

Access elements by a GA_Range These have the advantage of being able to operate a page at a time when applicable. NOTE: These cannot be used in parallel on an ordered group.

Definition at line 387 of file GA_ATIGroupBool.h.

virtual void GA_ElementGroup::replace ( const GA_Attribute src)
finalvirtual

This replaces the entirety of this attribute's content and non- storage metadata (except the name) with that of the src attribute. This copies the src group order if present and destroys any if not. matchesStorage(src) should already return true. This is primarily for use by GA_AttributeSet::replace(). NOTE: The internal content sizes may not match exactly if the attribute type may overallocate, but the sizes should be such that any real data will fit in the destination, so be careful and deal with the myTailInitialize flag appropriately if any extra elements aren't equal to the default.

Implements GA_Attribute.

bool GA_ElementGroup::saveGroupH9 ( std::ostream &  os,
bool  binary 
) const
virtual bool GA_ElementGroup::setArraySize ( GA_Offset  new_size)
virtual

Grow or shrink the array size.

Implements GA_Attribute.

SYS_FORCE_INLINE void GA_ElementGroup::setElement ( GA_Offset  ai,
bool  v 
)
inline

NOTE: When using setElement(GA_Offset,bool) in parallel, you must call invalidateGroupEntries() afterward, else getGroupEntries() may return an incorrect value. NOTE: This cannot be used in parallel on an ordered group.

Definition at line 192 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::setElement ( const GA_Range it,
bool  v 
)
inline

NOTE: This cannot be used in parallel on an ordered group.

Definition at line 204 of file GA_ATIGroupBool.h.

void GA_ElementGroup::setEntries ( )
inline

Add all elements to the group, only writing to real elements' offsets.

Definition at line 418 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::setOffset ( GA_Offset  ai,
bool  v 
)
inline

Definition at line 316 of file GA_ATIGroupBool.h.

bool GA_ElementGroup::setOrdered ( bool  ordered)
inline

When ordered is set to true, convert this group to an ordered group, otherwise convert to an unordered group. If the group contains mixed entries, a conversion to unordered will fail, and the function return false. Conversion to ordered group will always succeed.

Definition at line 149 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::setPageConstant ( GA_PageNum  pagenum,
const bool  value 
)
inline

Sets all elements of the specified page to the given value.

Definition at line 568 of file GA_ATIGroupBool.h.

virtual bool GA_ElementGroup::stat ( UT_WorkBuffer info,
uint  level 
) const
virtual

Compute detailed information.

Reimplemented from GA_Group.

void GA_ElementGroup::subEqual ( const GA_ATIGroupBool src)

These methods only work on unordered groups.

void GA_ElementGroup::toggleAll ( GA_Size  numelements)

These methods only work on unordered groups.

void GA_ElementGroup::toggleElement ( GA_Offset  ai)

NOTE: When using toggleElement(GA_Offset) in parallel, you must call invalidateGroupEntries() afterward, else getGroupEntries() may return an incorrect value. NOTE: This cannot be used in parallel on an ordered group.

void GA_ElementGroup::toggleElement ( const GA_Range it)

NOTE: This cannot be used in parallel on an ordered group.

void GA_ElementGroup::toggleEntries ( )
inline

Toggle membership of all elements.

Definition at line 423 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::toggleIndex ( GA_Index  ai)
inline

Access elements of the group by ordered index rather than offset. Internally, this method just find the data offset and calls appropriate method.

Definition at line 332 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::toggleOffset ( GA_Offset  ai)
inline

Access elements by their offset in the index map NOTE: When using addOffset, toggleOffset, removeOffset in parallel, you must call invalidateGroupEntries() afterward, else entries() may return an incorrect value. NOTE: These cannot be used in parallel on an ordered group.

Definition at line 358 of file GA_ATIGroupBool.h.

SYS_FORCE_INLINE void GA_ElementGroup::toggleRange ( const GA_Range it)
inline

Access elements by a GA_Range These have the advantage of being able to operate a page at a time when applicable. NOTE: These cannot be used in parallel on an ordered group.

Definition at line 382 of file GA_ATIGroupBool.h.

virtual void GA_ElementGroup::tryCompressAllPages ( GA_Offset  start_offset = GA_Offset(0),
GA_Offset  end_offset = GA_INVALID_OFFSET 
)
virtual

Try to compress data pages.

Implements GA_Attribute.

void GA_ElementGroup::xorEqual ( const GA_ATIGroupBool src)

These methods only work on unordered groups.

Friends And Related Function Documentation

friend class GOP_GroupParse
friend

Definition at line 757 of file GA_ATIGroupBool.h.

friend class GU_ElementGroup
friend

Definition at line 756 of file GA_ATIGroupBool.h.

friend class GU_Group
friend

Definition at line 755 of file GA_ATIGroupBool.h.


The documentation for this class was generated from the following file: