12 #ifndef __GEO_Detail_h__
13 #define __GEO_Detail_h__
70 template<
typename T,
bool B>
class GA_EdgeT;
80 #define GEO_STD_ATTRIB_POSITION "P"
81 #define GEO_STD_ATTRIB_NORMAL "N"
82 #define GEO_STD_ATTRIB_TEXTURE "uv"
83 #define GEO_STD_ATTRIB_VELOCITY "v"
84 #define GEO_STD_ATTRIB_ANGULAR_VELOCITY "w"
85 #define GEO_STD_ATTRIB_MATERIAL "shop_materialpath"
86 #define GEO_STD_ATTRIB_OGLSHOP "ogl_shop"
87 #define GEO_STD_ATTRIB_DIFFUSE "Cd"
88 #define GEO_STD_ATTRIB_ALPHA "Alpha"
89 #define GEO_STD_ATTRIB_COM "com"
90 #define GEO_STD_ATTRIB_DISTANCE "dist"
91 #define GEO_STD_ATTRIB_LOD "lod"
92 #define GEO_STD_ATTRIB_REST "rest"
93 #define GEO_STD_ATTRIB_MASS "mass"
94 #define GEO_STD_ATTRIB_DRAG "drag"
95 #define GEO_STD_ATTRIB_TENSION "tension"
96 #define GEO_STD_ATTRIB_SPRINGK "springk"
97 #define GEO_STD_ATTRIB_LIFE "life"
98 #define GEO_STD_ATTRIB_AGE "age"
99 #define GEO_STD_ATTRIB_DIST "dist"
100 #define GEO_STD_ATTRIB_UP "up"
101 #define GEO_STD_ATTRIB_ORIENT "orient"
102 #define GEO_STD_ATTRIB_ID "id"
103 #define GEO_STD_ATTRIB_PSCALE "pscale"
104 #define GEO_STD_ATTRIB_CREASE "creaseweight"
105 #define GEO_STD_ATTRIB_AREA "area"
106 #define GEO_STD_ATTRIB_PERIMETER "perimeter"
107 #define GEO_STD_ATTRIB_WIDTH "width"
108 #define GEO_STD_ATTRIB_LAYERMERGE "layermerge"
109 #define GEO_STD_ATTRIB_SEGS "segs"
110 #define GEO_STD_ATTRIB_DIV "div"
111 #define GEO_STD_ATTRIB_LAGE "lage"
112 #define GEO_STD_ATTRIB_ARC "arc"
113 #define GEO_STD_ATTRIB_GEN "gen"
114 #define GEO_STD_ATTRIB_TUBECAPTURE "tubeCapt"
115 #define GEO_STD_ATTRIB_PNT_CAPTURE_ALPHA "pCaptAlpha"
116 #define GEO_STD_ATTRIB_PNT_CAPTURE_PATH "pCaptPath"
117 #define GEO_STD_ATTRIB_PNT_CAPTURE_DATA "pCaptData"
118 #define GEO_STD_ATTRIB_CAPTUREFRAME "pCaptFrame"
119 #define GEO_STD_ATTRIB_CAPT_SKELROOT "pCaptSkelRoot"
120 #define GEO_STD_ATTRIB_CLOTH_CAPT "clothCapt"
121 #define GEO_STD_ATTRIB_WIRE_CAPT_U "wireCaptU"
122 #define GEO_STD_ATTRIB_WIRE_CAPT_V "wireCaptV"
123 #define GEO_STD_ATTRIB_WIRE_CAPT_PRIMU "wireCaptPrimU"
124 #define GEO_STD_ATTRIB_META_CAPT_FRAME "metaCaptFrame"
125 #define GEO_STD_ATTRIB_META_CAPT_GROUPS "metaCaptGroups"
126 #define GEO_STD_ATTRIB_META_CAPT_ROOT "metaCaptRoot"
127 #define GEO_STD_ATTRIB_META_CAPT_PATHS "metaCaptPaths"
128 #define GEO_STD_ATTRIB_META_CAPT_DATA "metaCaptData"
129 #define GEO_STD_ATTRIB_META_CAPT_GROUP_MAP "metaCaptGroupMap"
130 #define GEO_STD_ATTRIB_META_SLIDE "slideModifier"
131 #define GEO_STD_ATTRIB_INFLATE_MODIFIER "inflatemodifier"
132 #define GEO_STD_ATTRIB_MUSCLE_REST_ANCHOR "restAnchor"
133 #define GEO_STD_ATTRIB_MUSCLE_REST_XFORMS "restTransforms"
134 #define GEO_STD_ATTRIB_MUSCLE_INFLATE_NORM "muscleInflateNormal"
135 #define GEO_STD_ATTRIB_MUSCLE_POSITION_BIAS "positionbiasvalues"
136 #define GEO_STD_ATTRIB_MUSCLE_CAPT_NAMES "muscleCaptNames"
137 #define GEO_STD_ATTRIB_RIXLATE "rixlate"
138 #define GEO_STD_ATTRIB_DEFORM_SKIN_METHOD "deformSkinMethod"
139 #define GEO_STD_ATTRIB_DEFORM_DUAL_QUATERNION_BLEND_ATTRIB "deformDualQuaternionBlendAttrib"
140 #define GEO_STD_ATTRIB_DEFORM_TRANSFORMS_PATH "deformTransformsPath"
141 #define GEO_STD_ATTRIB_DEFORM_TRANSFORM_REGIONS_PATH "deformTransformRegionsPath"
142 #define GEO_STD_ATTRIB_DEFORM_TRANSFORM_TARGETS_PATH "deformTransformTargetsPath"
143 #define GEO_STD_ATTRIB_POSE_SHAPE_EXAMPLE_PATH "poseShapeExamplePath"
144 #define GEO_STD_ATTRIB_SHAPE_DIFF_METHOD "shapeDiffMethod"
145 #define GEO_STD_ATTRIB_SHAPE_DIFF_ORIENT_ATTRIB "shapeDiffOrientAttrib"
146 #define GEO_STD_ATTRIB_SHAPE_DIFF_TRANSFORM_ATTRIB "shapeDiffTransformAttrib"
147 #define GEO_STD_ATTRIB_STASH_POSE_PATH "stashPosePath"
238 bool full_topology=
true);
285 bool mergePrimGroup =
true,
286 bool insertPrimsAtHead=
false,
288 bool keep_internal_groups =
true,
301 bool merge_groups =
true,
302 bool keep_internal_groups =
true);
311 void merge(
const GEO_Primitive &sprim,
bool insertPrimAtHead=
false);
320 bool this_parameter_is_ignored =
true,
321 bool keep_internal_groups =
true,
324 void collapseIndexAttributes();
332 template<
typename FLOAT_T>
336 bool keep_vector_lengths =
true,
337 bool check_pasting =
true,
338 bool neg_determinant_flip_vector =
true,
339 bool update_ptnormals =
false,
341 bool updateaffectednormals =
false,
342 const char *attribpattern = NULL);
345 template<
typename FLOAT_T>
350 bool keep_vector_lengths =
true,
351 bool check_pasting =
true,
352 bool neg_determinant_flip_vector =
true,
353 bool update_ptnormals =
false,
355 bool updateaffectednormals =
false,
356 const char *attribpattern = NULL);
364 template<
typename FLOAT_T>
369 bool keep_vector_lengths =
true,
370 bool check_pasting =
true,
371 bool neg_determinant_flipvector =
true,
372 bool update_ptnormals =
false,
374 bool updateaffectednormals =
false,
375 const char *attribpattern = NULL);
379 template<
typename FLOAT_T>
384 bool keep_vector_lengths =
true,
385 bool check_pasting =
true,
386 bool neg_determinant_flipvector =
true,
387 bool update_ptnormals =
false,
389 bool updateaffectednormals =
false,
390 const char *attribpattern = NULL);
393 template<
typename FLOAT_T>
397 bool check_pasting =
true,
398 bool update_ptnormals =
false,
400 bool updateaffectednormals =
false,
401 const char *attribpattern = NULL);
405 template<
typename FLOAT_T>
409 bool keep_vector_lengths =
true,
410 bool check_pasting =
true,
411 bool neg_determinant_flipvector =
true,
412 bool update_ptnormals =
false,
414 bool updateaffectednormals =
false,
415 const char *attribpattern = NULL);
418 template<
typename FLOAT_T>
423 bool keep_vector_lengths =
true,
424 bool check_pasting =
true,
425 bool neg_determinant_flipvector =
true,
426 bool update_ptnormals =
false,
428 bool updateaffectednormals =
false,
429 const char *attribpattern = NULL);
433 template <
typename FLOAT_T,
bool INVERT=false>
434 void transformPointsByAttribute(
437 bool keep_vector_lengths =
true,
438 bool updateaffectednormals =
true,
439 const char *attribpattern = NULL);
443 template <
typename FLOAT_T,
bool INVERT=false>
444 void transformPointsByAttribute(
447 bool keep_vector_lengths =
true,
448 bool updateaffectednormals =
true,
449 const char *attribpattern = NULL);
453 template <
typename FLOAT_T,
bool INVERT=false>
454 void transformPointsByAttribute(
457 bool keep_vector_lengths =
true,
458 bool updateaffectednormals =
true,
459 const char *attribpattern = NULL);
463 template <
typename FLOAT_T,
bool INVERT=false>
464 void translatePointsByAttribute(
467 bool keep_vector_lengths =
true,
468 bool updateaffectednormals =
true,
469 const char *attribpattern = NULL);
472 template<
typename FLOAT_T>
475 bool check_pasting =
true,
476 bool update_ptnormals =
false,
478 bool updateaffectednormals =
false,
479 const char *attribpattern = NULL);
484 template<
typename FLOAT_T>
489 bool keep_vector_lengths =
true,
490 bool check_pasting =
true,
491 bool neg_determinant_flipvector =
true,
492 bool update_ptnormals =
false,
494 bool updateaffectednormals =
false,
495 const char *attribpattern = NULL);
498 template<
typename FLOAT_T>
501 bool check_pasting =
true,
502 bool update_ptnormals =
false,
504 bool updateaffectednormals =
false,
505 const char *attribpattern = NULL);
509 template<
typename FLOAT_T>
513 bool update_ptnormals =
false,
515 bool updateaffectednormals =
false,
516 const char *attribpattern = NULL);
519 template<
typename FLOAT_T>
522 bool update_ptnormals =
false,
524 bool updateaffectednormals =
false,
525 const char *attribpattern = NULL);
530 template<
typename FLOAT_T>
534 bool keep_vector_lengths =
true,
535 bool check_pasting =
true,
536 bool neg_determinant_flipvector =
true,
539 bool update_ptnormals =
false,
541 bool updateaffectednormals =
false,
542 const char *attribpattern = NULL);
545 template<
typename FLOAT_T>
548 bool check_pasting =
true,
550 bool update_ptnormals =
false,
552 bool updateaffectednormals =
false,
553 const char *attribpattern = NULL);
555 void visualizeSoftPoints(
const GEO_Rolloff &rolloff,
568 && myTol == other.
myTol;
573 return !(*
this == other);
587 void computeSoftPointFalloff(
const bool connected,
641 void normalTranslatePoints(
float length = 1.0F,
642 int check_pasting = 1,
644 int update_ptnormals = 0,
646 bool updateaffectednormals =
false);
647 void normalTranslatePrimitives(
float length = 1.0F,
648 int check_pasting = 1,
650 int update_ptnormals = 0,
652 bool updateaffectednormals =
false);
654 float length = 1.0F,
int check_pasting = 1,
655 int update_ptnormals = 0,
657 bool updateaffectednormals =
false);
659 float length = 1.0F,
int check_pasting = 1,
660 int update_ptnormals = 0,
662 bool updateaffectednormals =
false);
664 float length = 1.0F,
int check_pasting = 1,
665 int update_ptnormals = 0,
667 bool updateaffectednormals =
false);
669 float length = 1.0F,
int check_pasting = 1,
670 int update_ptnormals = 0,
672 bool updateaffectednormals =
false);
673 void normalTranslateGroup(
const GA_Group &grp,
674 float length = 1.0F,
int check_pasting = 1,
675 int update_ptnormals = 0,
677 bool updateaffectednormals =
false);
684 void updateAffectedNormals(
const GA_Range &ptrange,
686 bool allsametransform =
false);
691 template<
typename FLOAT_T>
696 bool keep_vector_lengths =
true,
697 bool check_pasting =
true,
698 bool neg_determinant_flipvector =
true,
699 bool update_ptnormals =
false,
701 bool updateaffectednormals =
false);
705 template<
typename FLOAT_T>
710 bool keep_vector_lengths =
true,
711 bool check_pasting =
true,
712 bool neg_determinant_flipvector =
true,
713 bool update_ptnormals =
false,
715 bool updateaffectednormals =
false,
721 template<
typename FLOAT_T>
726 bool keep_vector_lengths =
true,
727 bool check_pasting =
true,
728 bool neg_determinant_flipvector =
true,
729 bool update_ptnormals =
false,
731 bool updateaffectednormals =
false,
738 template<
typename FLOAT_T>
742 bool keep_vector_lengths =
true,
743 bool check_pasting =
true,
744 bool neg_determinant_flipvector =
true,
747 bool update_ptnormals =
false,
749 bool updateaffectednormals =
false,
755 template <
typename FLOAT_T>
772 : myFwdVector(forward), myUpVector(up), myType(
Type::LOOKAT),
773 myPivotSpace(pivot_space) {}
781 : myOrient(orient), myOrigin(origin), myType(
Type::ORIENT),
782 myPivotSpace(pivot_space) {}
801 template<
typename FLT>
806 FLT tx, FLT ty, FLT tz,
807 FLT rx, FLT ry, FLT rz,
808 FLT sx, FLT sy, FLT sz,
809 FLT s_xy, FLT s_xz, FLT s_yz,
810 FLT px, FLT
py, FLT pz,
811 FLT prx, FLT pry, FLT prz);
824 float tx,
float ty,
float tz,
825 float rx,
float ry,
float rz,
826 float sx,
float sy,
float sz,
827 float s_xy,
float s_xz,
float s_yz,
828 float px,
float py,
float pz,
829 float prx,
float pry,
float prz,
834 int keep_vector_lengths = 1,
835 int check_pasting = 1,
836 int neg_determinant_flipvector = 1,
837 int update_ptnormals = 0,
839 bool updateaffectednormals =
false,
840 const char *attribpattern = NULL,
842 bool *falloff_written = NULL);
844 float tx,
float ty,
float tz,
845 float rx,
float ry,
float rz,
846 float sx,
float sy,
float sz,
847 float s_xy,
float s_xz,
float s_yz,
848 float px,
float py,
float pz,
849 float prx,
float pry,
float prz,
854 int keep_vector_lengths = 1,
855 int check_pasting = 1,
856 int neg_determinant_flipvector = 1,
857 int update_ptnormals = 0,
859 bool updateaffectednormals =
false,
860 const char *attribpattern = NULL,
862 bool *falloff_written = NULL);
866 float tx,
float ty,
float tz,
867 float rx,
float ry,
float rz,
868 float sx,
float sy,
float sz,
869 float s_xy,
float s_xz,
float s_yz,
870 float px,
float py,
float pz,
871 float prx,
float pry,
float prz,
876 int keep_vector_lengths = 1,
877 int check_pasting = 1,
878 int neg_determinant_flipvector = 1,
879 int update_ptnormals = 0,
881 bool updateaffectednormals =
false,
882 const char *attribpattern = NULL,
884 bool *falloff_written = NULL);
887 float tx,
float ty,
float tz,
888 float rx,
float ry,
float rz,
889 float sx,
float sy,
float sz,
890 float s_xy,
float s_xz,
float s_yz,
891 float px,
float py,
float pz,
892 float prx,
float pry,
float prz,
897 int keep_vector_lengths = 1,
898 int check_pasting = 1,
899 int neg_determinant_flipvector = 1,
900 int update_ptnormals = 0,
902 bool updateaffectednormals =
false,
903 const char *attribpattern = NULL,
905 bool *falloff_written = NULL);
917 void softTranslatePoints(
const UT_Vector3 &delta,
921 int check_pasting = 1,
922 int update_ptnormals = 0,
924 bool updateaffectednormals =
false,
925 const char *attribpattern = NULL,
927 bool *falloff_written = NULL);
928 void softTranslateEdges(
const UT_Vector3 &delta,
932 int check_pasting = 1,
933 int update_ptnormals = 0,
935 bool updateaffectednormals =
false,
936 const char *attribpattern = NULL,
938 bool *falloff_written = NULL);
950 void softNormalTranslatePoints(
float distance,
955 int along_lead_normal = 1,
956 int check_pasting = 1,
957 int update_ptnormals = 0,
959 bool updateaffectednormals =
false,
962 bool *falloff_written = NULL);
994 &getPointCaptureAttribName(CaptureType
type);
999 static const char *getPointCaptureIndexPropertyName(CaptureType
type);
1004 &getPointCaptureFrameAttribName(CaptureType
type);
1009 &getPointCaptureRootAttribName(CaptureType
type);
1014 static const char *getPointCaptureDataPropertyName(CaptureType
type);
1018 bool getCaptureRegionRootPath(
UT_String &root_path,
1019 CaptureType
t = CAPTURE_BONE)
const;
1020 bool setCaptureRegionRootPath(
const UT_String &root_path,
1021 CaptureType
t = CAPTURE_BONE);
1025 int getCaptureRegionIndex(
const UT_String &cregion_name,
1026 CaptureType
t = CAPTURE_BONE);
1031 int addCaptureRegion(
const UT_String &cregion_name,
1034 int addCaptureRegion(
const UT_String &cregion_name,
1035 const UT_Matrix4 &xform,
float tcap,
float bcap,
1036 float taperx,
float taperz);
1040 int addCaptureRegion(
const UT_String &cregion_name,
1045 int removeCaptureRegion(
const UT_String &cregion_name,
1046 CaptureType
t = CAPTURE_BONE);
1049 void setCaptureWeight(
int cregion_index,
float weight,
1052 bool add_weight =
false,
1053 bool clamp_negative =
false,
1054 bool normalizeweight =
false,
1055 CaptureType
t = CAPTURE_BONE);
1058 void setCaptureWeight(
int cregion_index,
float weight,
1061 bool add_weight =
false,
1062 bool clamp_negative =
false,
1063 bool normalizeweight =
false,
1064 CaptureType
t = CAPTURE_BONE);
1067 float getCaptureWeight(
int cregion_index,
GA_Offset ptoff,
1068 CaptureType
t = CAPTURE_BONE)
const;
1077 CaptureType
t = CAPTURE_BONE)
const;
1078 void clearCaptureWeights(
GA_Offset ptoff,
1079 CaptureType
t = CAPTURE_BONE);
1088 void colorPointsByCaptureWeight(
1091 CaptureType
t = CAPTURE_BONE,
1092 VisualizationType vistype = VISTYPE_MULTIPLE,
1097 void colorPointsByCaptureWeight(
1101 VisualizationType vistype,
1105 void normalizeCaptureWeights(
const GA_PointGroup *ptgroup = NULL,
1106 CaptureType
t = CAPTURE_BONE);
1112 void clampCaptureWeights(
const GA_PointGroup *ptgroup = NULL,
1113 bool clamp_low_flag =
true,
1114 float low_threshold = 0.0
f,
float low_val = 0.0
f,
1115 bool clamp_hi_flag =
false,
1116 float hi_threshold = 1.0
f,
float hi_val = 1.0
f,
1120 void normalizeRelativeCaptureWeights(
int idx,
GA_Offset ptoff,
1144 {
return insertPointCopy(src, wrangler); }
1148 {
return insertPointCopy(src); }
1168 getPrimitive(primoff));
1187 getPrimitiveByIndex(idx));
1194 getPrimitiveByIndex(idx));
1204 {
return destroyPoints(range,
mode); }
1206 {
return destroyPrimitives(range, and_points); }
1208 {
return destroyPrimitive(prim, and_points); }
1228 bool destroyPrimitiveOffset(
1230 bool and_points =
false)
override;
1234 GA_Size destroyPrimitiveOffsets(
1236 bool and_points =
false)
override;
1241 bool and_points =
false);
1244 bool and_points =
false);
1263 int updateRequired = 0)
const;
1274 int accuratebounds = 0)
const;
1286 int accuratebounds = 0)
const;
1294 int accuratebounds = 0)
const;
1302 int accuratebounds)
const;
1323 template <
typename T>
1324 bool getPointAttribCentroid(
1358 void copyPointVertexAttributes(
GEO_Vertex dest,
1360 bool copy_point_P = true) const;
1361 void copyPointVertexAttributes(
1365 void copyPointVertexAttributes(
1371 copyVertex(dest_vtx, src_vtx, vertex_wrangler,
1372 point_wrangler, copy_point_P);
1383 copyVertex(dest_vtx, src_vtx, vertex_wrangler,
1400 int shallow = 0)
const;
1434 void fixSplineWeights();
1470 GA_Attribute *addCaptureFrameAttribute(CaptureType
t = CAPTURE_BONE,
1498 GA_Attribute *addPointCaptureAttribute(geo_NPairs n_pairs,
1499 CaptureType
t = CAPTURE_BONE,
1504 GA_Attribute *addPointCaptureAlphaAttribute(
float dflt,
1534 const GA_Attribute *findInternalNormalAttribute()
const;
1540 CaptureType
t = CAPTURE_BONE)
const;
1542 CaptureType
t = CAPTURE_BONE);
1545 const GA_Attribute *findCaptureSkelRootAttribute(CaptureType
t
1546 = CAPTURE_BONE)
const;
1553 CaptureType
t = CAPTURE_BONE)
const;
1555 CaptureType
t = CAPTURE_BONE);
1557 const GA_Attribute *findPointCaptureAlphaAttribute()
const;
1565 void destroyInternalNormalAttribute();
1574 void destroyTubeCaptureAttribute();
1577 void destroyCaptureFrameAttribute(CaptureType
t
1581 void destroyCaptureSkelRootAttribute(CaptureType
t
1586 void destroyPointCaptureAttribute(CaptureType
t =
1590 void destroyPointCaptureAlphaAttribute();
1597 bool getMetaRestAnchorPath(
UT_String &anchorPath)
const;
1614 int layer = -1)
const;
1615 int getAttributeLayer(
const char* attr_name)
const;
1617 static GA_TypeInfo getStdAttributeTypeInfo(
const char *
name,
int floattuplesize);
1620 int getCurrentLayer()
const;
1621 void setCurrentLayer(
int layer);
1622 void setNumLayers(
int numlayer);
1623 int getNumLayers()
const;
1625 void setLayerMerge(
int preclear,
int mask,
int srcblend,
1627 void getLayerMerge(
int &preclear,
int &
mask,
int &srcblend,
1628 int &dstblend)
const;
1630 void addVariableName(
const char *attr,
const char *varname);
1632 { addVariableName(0, varname); }
1638 void traverseVariableNames(
int (*
function)(
const char *attr,
1639 const char *varname,
void *
data),
1643 GA_Attribute *growPointCaptureAttribute(geo_NPairs num_added_pairs,
1644 CaptureType
t = CAPTURE_BONE);
1649 return getAttributes().cloneAttribute(
1661 creation_args, attribute_options,attribtype);
1670 creation_args, attribute_options,attribtype);
1678 {
return findPointAttribute(src.
getScope(),
1682 {
return findPointAttribute(src.
getScope(),
1720 return getAttributes().cloneAttribute(
1731 creation_args, attribute_options,attribtype);
1740 creation_args, attribute_options,attribtype);
1748 {
return findVertexAttribute(src.
getScope(),
1752 {
return findVertexAttribute(src.
getScope(),
1790 return getAttributes().cloneAttribute(
1801 n, creation_args, attribute_options,attribtype);
1810 creation_args, attribute_options,attribtype);
1818 {
return findPrimitiveAttribute(src.
getScope(),
1822 {
return findPrimitiveAttribute(src.
getScope(),
1845 return getAttributes().cloneAttribute(
1857 creation_args, attribute_options,attribtype);
1866 creation_args, attribute_options,attribtype);
1871 {
return findGlobalAttribute(src.
getScope(),
1875 {
return findGlobalAttribute(src.
getScope(),
1903 {
return getAttributes().getDict(
1907 {
return getAttributes().getDict(
1911 {
return getAttributes().getDict(
1915 {
return getAttributes().getDict(
1921 bool hasMetaPrimitives()
const;
1922 bool hasPastedPrimitives()
const;
1923 bool hasQuadricPrimitives()
const;
1924 bool hasParticlePrimitives()
const;
1925 bool hasVolumePrimitives()
const;
1926 bool hasTransformingPrimitives()
const;
1930 bool hasCustomPrimitives()
const;
1933 GA_Size getPastedCount()
const;
1934 GA_Size getQuadricCount()
const;
1935 GA_Size getParticleCount()
const;
1936 GA_Size getVolumeCount()
const;
1943 bool mergeCaptureProperties(
1969 const
char *attrib_name) const;
1972 const
char *attrib_name);
2014 GA_Size getPointGroupAdjacentToPrimitiveGroup(
2017 GA_Size getPointGroupAdjacentToPrimitiveRange(
2020 GA_Size getVertexGroupAdjacentToPrimitiveGroup(
2023 GA_Size getVertexGroupAdjacentToPrimitiveRange(
2029 struct AdjacentPolygonData
2034 {
return myAdjacentPolygon == pad.myAdjacentPolygon; }
2036 {
return myAdjacentPolygon < pad.myAdjacentPolygon; }
2085 const GEO_Primitive *findPrimitiveByName(
const char *nametomatch,
2088 const char *nameattrib=
"name",
2089 int matchnumber = 0)
const;
2093 const char *nameattrib=
"name",
2094 int matchnumber = 0);
2097 void findAllPrimitivesByName(
2099 const char *nametomatch,
2102 const char *nameattrib=
"name")
const;
2103 void findAllPrimitivesByName(
2105 const char *nametomatch,
2108 const char *nameattrib=
"name");
2117 { destroyElementGroup(g); }
2119 { destroyElementGroup(g); }
2121 { destroyElementGroup(g); }
2144 bool override =
true);
2147 bool override =
true);
2151 bool override =
true);
2154 bool override =
true);
2160 GA_Size localIntrinsicTupleSize(
2176 const char *
value)
override;
2202 bool convertIndexPairDataFromH9();
2203 bool convertIndexPairDataToH9();
2205 template<
typename FLOAT_T>
2210 bool keep_vector_lengths,
2212 bool neg_determinant_flipvector,
2213 bool update_ptnormals,
2215 bool updateaffectednormals,
2216 const char *attribpattern);
2221 bool override =
true);
2262 int min_size=1,
int max_size=-1)
const;
2266 int min_size=1,
int max_size=-1)
const
2269 min_size, max_size);
2274 int min_size=1,
int max_size=-1);
2278 int min_size=1,
int max_size=-1)
2281 min_size, max_size);
2286 int min_size=1,
int max_size=-1)
const;
2290 int min_size=1,
int max_size=-1)
const
2293 min_size, max_size);
2298 int min_size=1,
int max_size=-1);
2302 int min_size=1,
int max_size=-1)
2305 min_size, max_size);
2311 int min_size=1,
int max_size=-1)
const;
2315 int min_size=1,
int max_size=-1)
const
2318 name, min_size, max_size);
2324 int min_size=1,
int max_size=-1);
2328 int min_size=1,
int max_size=-1)
2331 name, min_size, max_size);
2336 int min_size=1,
int max_size=-1)
const;
2340 int min_size=1,
int max_size=-1)
const
2343 name, min_size, max_size);
2348 int min_size=1,
int max_size=-1);
2352 int min_size=1,
int max_size=-1)
2355 name, min_size, max_size);
2378 int min_size=1,
int max_size=-1)
const;
2382 int min_size=1,
int max_size=-1)
const
2385 min_size, max_size);
2390 int min_size=1,
int max_size=-1);
2394 int min_size=1,
int max_size=-1)
2397 min_size, max_size);
2402 int min_size=1,
int max_size=-1)
const;
2406 int min_size=1,
int max_size=-1)
const
2409 min_size, max_size);
2414 int min_size=1,
int max_size=-1);
2418 int min_size=1,
int max_size=-1)
2421 min_size, max_size);
2426 int min_size=1,
int max_size=-1)
const;
2430 int min_size=1,
int max_size=-1)
const
2433 min_size, max_size);
2438 int min_size=1,
int max_size=-1);
2442 int min_size=1,
int max_size=-1)
2445 min_size, max_size);
2450 int min_size=1,
int max_size=-1)
const;
2454 int min_size=1,
int max_size=-1)
const
2457 min_size, max_size);
2462 int min_size=1,
int max_size=-1);
2466 int min_size=1,
int max_size=-1)
2469 min_size, max_size);
2474 int min_size=1,
int max_size=-1)
const;
2478 int min_size=1,
int max_size=-1)
const
2481 min_size, max_size);
2486 int min_size=1,
int max_size=-1);
2490 int min_size=1,
int max_size=-1)
2493 min_size, max_size);
2535 return addTuple(storage,
2577 tuple_size, defaults,
2604 tuple_size, defaults,
2628 name, tuple_size, creation_args,
2629 attribute_options, reuse);
2650 name, tuple_size, creation_args,
2651 attribute_options, reuse);
2764 return ((
'P'<<24) + (
'G'<<16) + (
'E'<<8) +
'O');
2769 return ((
'B'<<24) + (
'g'<<16) + (
'e'<<8) +
'o');
2775 bool savePointsH9(std::ostream &os,
bool binary,
2779 bool saveExtraH9(std::ostream &os,
bool binary,
2789 os,
false,
nullptr);
2794 friend class GU_IOClassic;
2800 void privateComputeNormal(
2803 const float cuspangledegrees,
2804 const int method)
const override;
UT_ValArray< EdgeAdjacencyData > GEO_EdgeAdjArray
void destroyPrimitiveGroup(GA_PrimitiveGroup *g)
virtual void clearCaches()
SYS_FORCE_INLINE GA_Attribute * addIntArray(GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size=1, const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, GA_Storage storage=GA_STORE_INT32, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
SYS_FORCE_INLINE const GA_Attribute * findStringTuple(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
Definition of a geometry attribute.
SYS_FORCE_INLINE GA_Attribute * addPointAttrib(const GA_Attribute *src)
SYS_FORCE_INLINE const GA_Attribute * findNumericArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
void incrementMetaCacheCount()
Specify when and how to reuse an existing attribute.
SYS_FORCE_INLINE const GA_Attribute * findPointVectorAttrib(GA_AttributeScope s, const UT_StringRef &n) const
Looks for a 3-float point attribute.
GLuint GLdouble GLdouble GLint GLint order
SYS_FORCE_INLINE GA_Attribute * findNumericTuple(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
GLenum GLuint GLint GLint layer
Axis-aligned bounding box (AABB).
*get result *(waiting if necessary)*A common idiom is to fire a bunch of sub tasks at the and then *wait for them to all complete We provide a helper class
SYS_FORCE_INLINE GA_Attribute * findIntTuple(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
GEO_Capture_Bone_Property
Class which stores the default values for a GA_Attribute.
GEO_Capture_Cloth_Property
SYS_FORCE_INLINE GA_Attribute * addDictArray(GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size=1, const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, GA_Storage storage=GA_STORE_STRING, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
#define SYS_DEPRECATED_PUSH_DISABLE()
#define SYS_DEPRECATED_POP_DISABLE()
SYS_FORCE_INLINE GA_Attribute * addPrimAttrib(const UT_StringHolder &n, const UT_Options *creation_args, const GA_AttributeOptions *attribute_options, const UT_StringRef &attribtype)
bool GAisValid(GA_Size v)
void clearAndDestroy()
Clear all the points/primitives out of this detail.
const GLuint GLenum const void * binary
SYS_FORCE_INLINE GA_Attribute * addTuple(GA_Storage storage, GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size, const GA_Defaults &defaults=GA_Defaults(0.0), const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
SYS_FORCE_INLINE GA_Attribute * addVertexAttrib(GA_AttributeScope scope, const UT_StringHolder &n, const UT_Options *creation_args, const GA_AttributeOptions *attribute_options, const UT_StringRef &attribtype)
bool deletePrimitive(GA_Primitive &prim, bool and_points=false)
UT_ValArray< PointAdjacencyData > GEO_PointAdjArray
SYS_FORCE_INLINE GA_Attribute * findGlobalAttrib(const GA_Attribute &src)
SYS_FORCE_INLINE GA_Attribute * findIndexPair(GA_AttributeOwner owner, const UT_StringRef &name)
SYS_FORCE_INLINE GA_Attribute * findStringTuple(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
void destroyVertexGroup(GA_VertexGroup *g)
SYS_FORCE_INLINE void destroyVertexAttrib(GA_AttributeScope scope, const UT_StringRef &n, const GA_AttributeFilter *filter=NULL)
IOStatus saveClassic(const char *, const GA_SaveOptions *) const
GLuint const GLchar * name
SYS_FORCE_INLINE const GA_Attribute * findFloatTuple(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
Standard user attribute level.
GA_Size deletePoints(const GA_Range &range, GA_DestroyPointMode mode=GA_LEAVE_PRIMITIVES)
static int binaryMagicH9()
Magic number for binary geometry files.
UT_Vector3T< FLOAT_T > myUpVector
const UT_StringHolder & getName() const
exint GA_Size
Defines the bit width for index and offset types in GA.
GA_Size deletePrimitives(const GA_Range &range, bool and_points=false)
virtual int64 getMemoryUsage(bool inclusive) const
Compute memory usage (includes all shared memory)
GEO_Capture_Wire_Property
GA_Offset appendPointCopy(GA_Offset src)
GLuint GLuint GLfloat weight
void removeVariableName(const char *varname)
A range of elements in an index-map.
SYS_FORCE_INLINE const GA_Attribute * findVertexAttrib(const GA_Attribute &src) const
SYS_FORCE_INLINE GA_Attribute * findDictArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
A string map of attributes to ease backward compatibility In the GB/GEO/GU library code would often p...
SYS_FORCE_INLINE GEO_Primitive * getGEOPrimitive(GA_Offset primoff)
SYS_FORCE_INLINE GA_Attribute * addPrimAttrib(GA_AttributeScope scope, const UT_StringHolder &n, const UT_Options *creation_args, const GA_AttributeOptions *attribute_options, const UT_StringRef &attribtype)
SYS_FORCE_INLINE GA_Attribute * findPrimAttrib(const GA_Attribute &src)
GLuint GLenum GLenum transform
SYS_FORCE_INLINE GA_Attribute * addVertexAttrib(const UT_StringHolder &n, const UT_Options *creation_args, const GA_AttributeOptions *attribute_options, const UT_StringRef &attribtype)
SYS_FORCE_INLINE const GEO_Primitive * getGEOPrimitive(GA_Offset off) const
bool operator==(const BaseDimensions< T > &a, const BaseDimensions< Y > &b)
Class used to create a map of source points during merging.
SYS_FORCE_INLINE const GA_Attribute * findPointAttrib(const GA_Attribute &src) const
bool operator!=(const SoftSymmetryParms &other) const
UT_Matrix3T< FLOAT_T > myOrient
SYS_FORCE_INLINE GA_Attribute * addPrimAttrib(const GA_Attribute *src)
CaptureType
Methods for manipulating capture weights (GEO_CaptureWeight.C)
GLint GLint GLsizei GLint GLenum GLenum type
SYS_FORCE_INLINE GA_Attribute * findVertexAttrib(const GA_Attribute &src)
SYS_FORCE_INLINE const GA_Attribute * findGlobalAttrib(const GA_Attribute &src) const
Class used to keep track of inheritance of intrinsic attribute evaluation.
SYS_FORCE_INLINE GA_Attribute * addIntTuple(GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size, const GA_Defaults &defaults=GA_Defaults(0), const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, GA_Storage storage=GA_STORE_INT32, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
GLfloat GLfloat GLfloat v2
friend std::ostream & operator<<(std::ostream &os, const GEO_Detail &d)
SYS_FORCE_INLINE bool promotePointAttrib(const UT_StringRef &name)
SYS_FORCE_INLINE GA_Attribute * addFloatArray(GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size=1, const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, GA_Storage storage=GA_STORE_REAL32, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
SYS_FORCE_INLINE GA_Attribute * addGlobalAttrib(GA_AttributeScope scope, const UT_StringHolder &n, const UT_Options *creation_args, const GA_AttributeOptions *attribute_options, const UT_StringRef &attribtype)
GLsizei GLsizei GLfloat distance
UT_BoundingBoxT< float > UT_BoundingBox
SYS_FORCE_INLINE void destroyAttribute(GA_AttributeOwner owner, const UT_StringRef &name, const GA_AttributeFilter *filter=0)
SYS_FORCE_INLINE void destroyPrimAttrib(const UT_StringRef &n, const GA_AttributeFilter *filter=NULL)
SYS_FORCE_INLINE const GA_Attribute * findNumericTuple(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
GLboolean GLboolean GLboolean GLboolean a
SYS_FORCE_INLINE GA_Offset appendPoint()
Append a new point, returning its new data offset.
SYS_FORCE_INLINE const GA_Attribute * findDictArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
SYS_FORCE_INLINE const GA_Attribute * findFloatArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
bool operator<(const GU_TetrahedronFacet &a, const GU_TetrahedronFacet &b)
GA_Offset myStartEdgePoint
A handle to simplify manipulation of multiple attributes.
SYS_FORCE_INLINE GA_Attribute * findFloatTuple(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
SYS_FORCE_INLINE const GA_Attribute * findVertexVectorAttrib(GA_AttributeScope s, const UT_StringRef &n) const
Looks for a 3-float vertex attribute.
GLint GLint GLint GLint GLint GLint GLint GLbitfield GLenum filter
HUSD_API bool eval(VtValue &val, T &ret_val)
const GEO_Primitive * getGEOPrimitiveByIndex(GA_Index idx) const
#define SYS_DEPRECATED_HDK(__V__)
SYS_FORCE_INLINE GA_Attribute * addPointAttrib(const UT_StringHolder &n, const UT_Options *creation_args, const GA_AttributeOptions *attribute_options, const UT_StringRef &attribtype)
GEO_Primitive GB_MACRO_PRIM_TYPE
SYS_FORCE_INLINE const GA_Attribute * findIndexPair(GA_AttributeOwner owner, const UT_StringRef &name) const
GA_Size GA_Index
Define the strictness of GA_Offset/GA_Index.
GA_AttributeScope getScope() const
UT_Vector3T< FLOAT_T > myFwdVector
GA_API const UT_StringHolder orient
SYS_FORCE_INLINE GA_Attribute * growTuple(GA_AttributeOwner owner, const UT_StringRef &name, int added_size)
SYS_FORCE_INLINE GA_Attribute * findPointAttrib(const GA_Attribute &src)
SYS_FORCE_INLINE void destroyPointAttrib(const UT_StringRef &n, const GA_AttributeFilter *filter=NULL)
SYS_FORCE_INLINE const GA_AttributeDict & attribs() const
bool destroyPointGroup(const char *name)
LocalXformContextT(const UT_Matrix3T< FLOAT_T > &orient, const UT_Vector3T< FLOAT_T > &origin, PivotSpace pivot_space)
GLuint GLdouble GLdouble GLint GLint const GLdouble * points
SYS_FORCE_INLINE GA_Attribute * findFloatArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
GEO_Primitive * getGEOPrimitiveByIndex(GA_Index idx)
Contains transitional objects to provide some backward compatibility for code that references old GEO...
GLuint GLsizei GLsizei * length
GEO_API const TypeMask GEOPRIMALL
SYS_FORCE_INLINE GA_Offset appendPointOffset()
A map of string to various well defined value types.
Class to return information about a GA_Detail.
SYS_FORCE_INLINE const GA_Attribute * findPrimAttrib(const GA_Attribute &src) const
SYS_FORCE_INLINE GA_Attribute * findStringArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
SYS_FORCE_INLINE GA_Attribute * findPointVectorAttrib(GA_AttributeScope s, const UT_StringRef &n)
SYS_FORCE_INLINE GA_Attribute * addGlobalAttrib(const UT_StringHolder &n, const UT_Options *creation_args, const GA_AttributeOptions *attribute_options, const UT_StringRef &attribtype)
SYS_FORCE_INLINE GA_Attribute * addDictTuple(GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size, const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
SYS_FORCE_INLINE bool demoteVertexAttrib(const UT_StringRef &name)
SYS_FORCE_INLINE const GA_Attribute * findPointVectorAttrib(const UT_StringRef &n) const
GA_Primitive * appendPrimitive(const GA_PrimitiveTypeId &type)
Append a primitive by GA_PrimitiveTypeId.
virtual void countMemory(UT_MemoryCounter &counter, bool inclusive) const
SYS_FORCE_INLINE GA_Attribute * findIntArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
GA_API const UT_StringHolder up
static int asciiMagicH9()
Magic number for ASCII geometry files.
SYS_FORCE_INLINE const GA_Attribute * findIntArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
SYS_FORCE_INLINE GEO_Primitive * appendPrimitive(const GA_PrimitiveTypeId &type)
SYS_FORCE_INLINE GA_Attribute * addGlobalAttrib(const GA_Attribute *src)
SYS_FORCE_INLINE const GA_AttributeDict & primitiveAttribs() const
Utility class for containing a color ramp.
void destroyPointGroup(GA_PointGroup *g)
GEO_Capture_Muscle_Property
OIIO_API bool copy(string_view from, string_view to, std::string &err)
SYS_FORCE_INLINE GA_Attribute * findNumericArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1)
SYS_FORCE_INLINE GA_Size deletePoints(const GA_PointGroup &point_group, GA_DestroyPointMode mode=GA_LEAVE_PRIMITIVES)
SYS_FORCE_INLINE GA_Attribute * addFloatTuple(GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size, const GA_Defaults &defaults=GA_Defaults(0.0), const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, GA_Storage storage=GA_STORE_REAL32, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
GLsizei const GLfloat * value
bool destroyPrimitiveGroup(const char *name)
SYS_FORCE_INLINE GA_Attribute * addStringArray(GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size=1, const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, GA_Storage storage=GA_STORE_STRING, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
SYS_FORCE_INLINE GA_Attribute * addPointAttrib(GA_AttributeScope scope, const UT_StringHolder &n, const UT_Options *creation_args, const GA_AttributeOptions *attribute_options, const UT_StringRef &attribtype)
SYS_FORCE_INLINE GA_Attribute * findVertexVectorAttrib(const UT_StringRef &n)
SYS_FORCE_INLINE GA_Attribute * findPointVectorAttrib(const UT_StringRef &n)
getOption("OpenEXR.storage") storage
Container class for all geometry.
SYS_FORCE_INLINE const GA_Attribute * findIntTuple(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
UT_Vector3T< FLOAT_T > myOrigin
GA_Offset appendPointCopy(GA_Offset src, GA_PointWrangler &wrangler)
Append a point, copying data from the source point.
SYS_FORCE_INLINE void destroyVertexAttrib(const UT_StringRef &n, const GA_AttributeFilter *filter=NULL)
PUGI__FN char_t * translate(char_t *buffer, const char_t *from, const char_t *to, size_t to_length)
SYS_FORCE_INLINE GA_Attribute * addVertexAttrib(const GA_Attribute *src)
GEO_Capture_Meta_Property
SYS_FORCE_INLINE GA_Attribute * addStringTuple(GA_AttributeOwner owner, const UT_StringHolder &name, int tuple_size, const UT_Options *creation_args=0, const GA_AttributeOptions *attribute_options=0, const GA_ReuseStrategy &reuse=GA_ReuseStrategy())
SYS_FORCE_INLINE const GA_Attribute * findStringArray(GA_AttributeOwner owner, const UT_StringRef &name, int min_size=1, int max_size=-1) const
SYS_FORCE_INLINE void destroyGlobalAttrib(GA_AttributeScope scope, const UT_StringRef &n, const GA_AttributeFilter *filter=NULL)
bool operator==(const SoftSymmetryParms &other) const
SYS_FORCE_INLINE void destroyPointAttrib(GA_AttributeScope scope, const UT_StringRef &n, const GA_AttributeFilter *filter=NULL)
Class to specify options for loading geometry.
SYS_FORCE_INLINE GA_Attribute * findVertexVectorAttrib(GA_AttributeScope s, const UT_StringRef &n)
SYS_FORCE_INLINE void destroyGlobalAttrib(const UT_StringRef &n, const GA_AttributeFilter *filter=NULL)
LocalXformContextT(const UT_Vector3T< FLOAT_T > &forward, const UT_Vector3T< FLOAT_T > &up, PivotSpace pivot_space)
Coordinate frame defined by lookat(zero, forward, up).
GEO_CopyMethod
An enum for GEO_Detail::copy's method parameter.
bool destroyVertexGroup(const char *name)
SYS_FORCE_INLINE const GA_Attribute * findVertexVectorAttrib(const UT_StringRef &n) const
SYS_FORCE_INLINE const GA_AttributeDict & vertexAttribs() const
SYS_FORCE_INLINE void destroyPrimAttrib(GA_AttributeScope scope, const UT_StringRef &n, const GA_AttributeFilter *filter=NULL)