12 #ifndef __GA_AttributeRefMap__
13 #define __GA_AttributeRefMap__
39 class ga_AttributeHandleList;
40 class ga_VertexPoolProxy;
134 , myStart(start_offset)
137 for (
int i = 0; i < myMap.entries(); ++i)
157 for (
int i = 0,
n = myMap.entries(); i <
n; ++i)
198 , myStart(start_offset)
201 for (
int i = 0; i < myMap.entries(); ++i)
220 for (
int i = 0,
n = myMap.entries(); i <
n; ++i)
255 myStrW = UTmakeUnique<GA_RWBatchHandleS>(attrib);
257 return *myStrW.
get();
263 myStrR = UTmakeUnique<GA_ROHandleS>(attrib);
265 return *myStrR.
get();
271 myDictW = UTmakeUnique<GA_RWBatchHandleDict>(attrib);
273 return *myDictW.
get();
279 myDictR = UTmakeUnique<GA_ROHandleDict>(attrib);
281 return *myDictR.
get();
290 Data *getData(
int idx)
292 return &myData.forcedRef(idx);
299 void bumpAllDestDataIds()
301 for (
int i = 0, n = entries(); i <
n; ++i)
318 for (
int i = 0; i < entries(); ++i)
322 if (!attrib)
continue;
336 for (
int i = 0; i < entries(); i++)
340 if (!attrib)
continue;
366 void replaceSource(
const GA_Detail &src,
bool as_custom_map =
false);
376 void initThreadInstance();
395 {
return getVertexPool().appendVertex(pt); }
397 {
return getVertexPool().appendPoint(); }
405 { getVertexPool().freeVertex(v); }
407 { getVertexPool().freePoint(p); }
429 return src ? append(dest, src) : false;
435 return dest ? append(dest, src) : false;
443 int search_order_size);
446 {
return append(filter, &owner, 1); }
470 int search_order_size);
475 {
return cloneAndAppendFromSource(filter, &owner, 1); }
498 int entriesWithSourceP()
const;
502 void homogenize(OffsetMap &dest)
const;
505 void dehomogenize(OffsetMap &dest)
const;
511 Cache *cache = 0)
const;
512 void copyValue(OffsetMap &dest,
514 Cache *cache = 0)
const;
520 bool isEqual(OffsetMap &
a,
524 bool isAlmostEqual(OffsetMap &
a,
533 void copyExplicitPosition(OffsetMap &dest,
537 void copyExplicitPosition(OffsetMap &dest,
541 void copyExplicitPosition(OffsetMap &dest,
545 void copyExplicitPosition(OffsetMap &dest,
549 void copyExplicitPosition(OffsetMap &dest,
553 void copyExplicitPosition(OffsetMap &dest,
562 void addValue(OffsetMap &dest,
570 void subValue(OffsetMap &dest,
577 void mulValue(OffsetMap &dest,
585 void lerpValue(OffsetMap &dest,
591 void lerpHValue(OffsetMap &dest,
617 GA_Offset dest)
const { startSum(sum, downer, dest); }
619 { startSum(sum, dest); }
623 fpreal normalization=1)
const;
627 fpreal normalization=1)
const;
655 void barycentricValue(OffsetMap &dest,
665 void barycentricValue(OffsetMap &dest,
685 void bilinearValue(OffsetMap &dest,
693 void zeroElement(OffsetMap &dest)
const;
709 OffsetMap &dest)
const;
713 OffsetMap &dest)
const;
723 void copyDestValue(OffsetMap &dest,
728 void addDestValue(OffsetMap &dest,
733 void subDestValue(OffsetMap &dest,
739 void lerpDestValue(OffsetMap &dest,
763 const char *msg, ...)
const;
764 void dump(OffsetMap &dest,
765 const char *msg, ...)
const;
767 const char *msg, va_list
args)
const;
768 void vdump(OffsetMap &dest,
769 const char *msg, va_list
args)
const;
791 if (
name.multiMatch(myPattern) != 0)
795 strcmp(a->
getName(),
"P") == 0)
798 return name.multiMatch(myPattern) != 0;
813 void appendAndCreateAllSource(
816 const char *matchpattern,
818 bool includegroups =
true);
SYS_FORCE_INLINE void bumpDataId()
Definition of a geometry attribute.
bool match(const GA_Attribute *a) const override
void startHSum(const GA_WeightedSum &sum, GA_AttributeOwner downer, GA_Offset dest) const
SYS_FORCE_INLINE const HOLDER & get(GA_Offset off, int comp=0) const
Get the string at the given offset.
const GA_Detail * getSourceDetail() const
GLboolean GLboolean GLboolean GLboolean a
void clearOrdered()
Clear all order information, including any mixed entries.
Manages allocation/deletion of temporary vertex/points for a detail.
Context to keep track of weighted sums.
FilterPattern(const char *pattern, bool matchPw=false)
GA_Size GA_VertexPoolIndex
virtual void tryCompressAllPages(GA_Offset start_offset=GA_Offset(0), GA_Offset end_offset=GA_INVALID_OFFSET)=0
#define GA_INVALID_OFFSET
std::unique_ptr< T, Deleter > UT_UniquePtr
A smart pointer for unique ownership of dynamically allocated objects.
SYS_FORCE_INLINE const UT_StringHolder & getName() const
GA_API const UT_StringHolder scale
void startHSum(const GA_WeightedSum &sum, OffsetMap &dest) const
SYS_FORCE_INLINE bool isGroup() const
std::shared_ptr< T > UT_SharedPtr
Wrapper around std::shared_ptr.
~FilterPattern() override
const char *const myPattern
A handle to simplify manipulation of multiple attributes.
GLuint const GLchar * name
SYS_DECLARE_LEGACY_TR(GU_Detail)
GA_API const UT_StringHolder transform
GA_AttributeRefMapOffsetMap OffsetMap
**If you just want to fire and args
SYS_FORCE_INLINE GA_AttributeOwner getOwner() const
Container class for all geometry.
GLubyte GLubyte GLubyte GLubyte w
GA_Detail * getDestDetail() const
SYS_FORCE_INLINE HOLDER get(GA_Offset off, int comp=0) const
Get the string at the given offset.
virtual void hardenAllPages(GA_Offset start_offset=GA_Offset(0), GA_Offset end_offset=GA_INVALID_OFFSET)=0
uint64_t multiply(uint64_t lhs, uint64_t rhs)
void invalidateGroupEntries()
GLint GLint GLint GLint GLint GLint GLint GLbitfield GLenum filter