37 #ifndef OPENVDB_POINTS_ATTRIBUTE_GROUP_HAS_BEEN_INCLUDED 38 #define OPENVDB_POINTS_ATTRIBUTE_GROUP_HAS_BEEN_INCLUDED 66 static const char*
name() {
return "grp"; }
105 using Ptr = std::shared_ptr<GroupHandle>;
118 bool get(
Index n)
const;
119 bool getUnsafe(
Index n)
const;
133 using Ptr = std::shared_ptr<GroupWriteHandle>;
137 void set(
Index n,
bool on);
147 bool collapse(
bool on);
163 : mIndex(attributeSet.groupIndex(name)) { }
165 explicit GroupFilter(
const AttributeSet::Descriptor::GroupIndex& index)
171 template <
typename LeafT>
174 template <
typename LeafT>
176 mHandle.reset(
new GroupHandle(leaf.groupHandle(mIndex)));
179 template <
typename IterT>
180 bool valid(
const IterT& iter)
const {
182 return mHandle->getUnsafe(*iter);
186 const AttributeSet::Descriptor::GroupIndex mIndex;
200 #endif // OPENVDB_POINTS_ATTRIBUTE_GROUP_HAS_BEEN_INCLUDED bool valid(const IterT &iter) const
Definition: AttributeGroup.h:180
const GroupType mBitMask
Definition: AttributeGroup.h:123
std::shared_ptr< GroupHandle > Ptr
Definition: AttributeGroup.h:105
Typed class for storing attribute data.
Definition: AttributeArray.h:584
StorageType Type
Definition: AttributeGroup.h:62
Definition: AttributeGroup.h:56
Attribute Array storage templated on type and compression codec.
Definition: AttributeGroup.h:102
const GroupAttributeArray & mArray
Definition: AttributeGroup.h:122
Base class for storing attribute data.
Definition: AttributeArray.h:118
std::string Name
Definition: Name.h:44
Definition: AttributeGroup.h:130
Index size() const
Definition: AttributeGroup.h:115
void reset(const LeafT &leaf)
Definition: AttributeGroup.h:175
Ordered collection of uniquely-named attribute arrays.
Definition: AttributeSet.h:62
#define OPENVDB_VERSION_NAME
The version namespace name for this library version.
Definition: version.h:125
static const char * name()
Definition: AttributeGroup.h:66
Index32 Index
Definition: Types.h:61
Definition: Exceptions.h:40
GroupType StorageType
Definition: AttributeGroup.h:58
bool isGroup(const AttributeArray &array)
Definition: AttributeGroup.h:93
bool isUniform() const
Definition: AttributeGroup.h:116
bool initialized() const
Definition: AttributeGroup.h:168
GroupFilter(const AttributeSet::Descriptor::GroupIndex &index)
Definition: AttributeGroup.h:165
uint8_t GroupType
Definition: AttributeGroup.h:50
std::pair< Index, uint8_t > GroupIndex
Definition: AttributeGroup.h:110
bool isType() const
Return true if this attribute is of the same type as the template parameter.
Definition: AttributeArray.h:259
Definition: AttributeGroup.h:62
#define OPENVDB_USE_VERSION_NAMESPACE
Definition: version.h:177
static index::State state()
Definition: AttributeGroup.h:170
GroupType ValueType
Definition: AttributeGroup.h:59
State
Definition: IndexIterator.h:66
Definition: IndexIterator.h:68
Index filtering on group membership.
Definition: AttributeGroup.h:159
Set of Attribute Arrays which tracks metadata about each array.
static index::State state(const LeafT &)
Definition: AttributeGroup.h:172
Definition: AttributeGroup.h:108
GroupFilter(const Name &name, const AttributeSet &attributeSet)
Definition: AttributeGroup.h:162