HDK
|
#include "GEO_API.h"
#include <GA/GA_Handle.h>
#include <GA/GA_Types.h>
#include <UT/UT_Array.h>
#include <UT/UT_VectorTypes.h>
#include <UT/UT_PolySample.h>
#include <UT/UT_Vector3.h>
#include <SYS/SYS_Math.h>
Go to the source code of this file.
Classes | |
struct | GEO_InterpolationOptions |
Macros | |
#define | __GEO_Interpolate__ |
Functions | |
template<typename INT > | |
void | geoInterpolateAttributes (const GEO_Detail *source, const GA_AttributeRefMap &attribmap, const GA_Range &destrange, const GA_ROHandleT< INT > &primnumattrib, const GA_ROHandleV3 &primuvwattrib, const GEO_InterpolationOptions &options) |
template<typename INT > | |
void | geoInterpolateAttributes (const GEO_Detail *source, const GA_AttributeRefMap &attribmap, const GA_Range &destrange, const GA_ROHandleT< INT > &primnumattrib, const GA_ROHandleV3 &primuvwattrib, GA_AttributeOwner computenumbersof, GA_Attribute *computeindexattrib, GA_Attribute *computeweightattrib, const GEO_InterpolationOptions &options) |
GEO_API void | geoInterpolateAttributes (const GEO_Detail *source, const GA_AttributeRefMap &attribmap, const GA_Range &destrange, GA_AttributeOwner indexowner, const GA_Attribute *indexattrib, const GA_Attribute *weightattrib, const GEO_InterpolationOptions &options) |
template<typename T , typename S > | |
void | GEOquadInterpolationWeights (T u, T v, S weights[4]) |
template<typename T , typename S > | |
void | GEOtriInterpolationWeights (T u, T v, S weights[3]) |
template<typename T > | |
void | GEOgetXYProjection (const UT_Vector3T< T > &nml, int &x, int &y) |
GEO_API void | GEOgetInterpolationWeights (const GEO_Detail *detail, GA_Offset primoff, UT_Array< GA_Offset > &offsets, UT_Array< float > &weights, const UT_Vector3 &uvw, bool is_point_offsets=false) |
template<typename T > | |
GEO_API void | GEOevaluateInteriorPoint (const GEO_Detail *gdp, GA_Offset primoff, const GA_ROHandleT< T > &h, const UT_Vector3 &uvw, T *buf, int size) |
GEO_API void | GEOevaluateInteriorPoint (const GEO_Detail *gdp, GA_Offset primoff, const GA_ROHandleS &h, const UT_Vector3 &uvw, UT_StringHolder *buf, int size) |
template<typename T > | |
SYS_FORCE_INLINE GEO_API T | GEOevaluateInteriorPoint (const GEO_Detail *gdp, GA_Offset primoff, const GA_ROHandleT< T > &h, const UT_Vector3 &uvw) |
SYS_FORCE_INLINE GEO_API UT_StringHolder | GEOevaluateInteriorPoint (const GEO_Detail *gdp, GA_Offset primoff, const GA_ROHandleS &h, const UT_Vector3 &uvw) |
#define __GEO_Interpolate__ |
Definition at line 14 of file GEO_Interpolate.h.
GEO_API void GEOevaluateInteriorPoint | ( | const GEO_Detail * | gdp, |
GA_Offset | primoff, | ||
const GA_ROHandleT< T > & | h, | ||
const UT_Vector3 & | uvw, | ||
T * | buf, | ||
int | size | ||
) |
Evaluate a GA_ROHandle based on the uvw position, can either evaluate into a buffer or return the result.
Uses GEOgetInterpolationWeights in order to interpolate vertex and point attributes.
GEO_API void GEOevaluateInteriorPoint | ( | const GEO_Detail * | gdp, |
GA_Offset | primoff, | ||
const GA_ROHandleS & | h, | ||
const UT_Vector3 & | uvw, | ||
UT_StringHolder * | buf, | ||
int | size | ||
) |
Evaluate a GA_ROHandle based on the uvw position, can either evaluate into a buffer or return the result.
Uses GEOgetInterpolationWeights in order to interpolate vertex and point attributes.
SYS_FORCE_INLINE GEO_API T GEOevaluateInteriorPoint | ( | const GEO_Detail * | gdp, |
GA_Offset | primoff, | ||
const GA_ROHandleT< T > & | h, | ||
const UT_Vector3 & | uvw | ||
) |
Evaluate a GA_ROHandle based on the uvw position, can either evaluate into a buffer or return the result.
Uses GEOgetInterpolationWeights in order to interpolate vertex and point attributes.
Definition at line 323 of file GEO_Interpolate.h.
SYS_FORCE_INLINE GEO_API UT_StringHolder GEOevaluateInteriorPoint | ( | const GEO_Detail * | gdp, |
GA_Offset | primoff, | ||
const GA_ROHandleS & | h, | ||
const UT_Vector3 & | uvw | ||
) |
Evaluate a GA_ROHandle based on the uvw position, can either evaluate into a buffer or return the result.
Uses GEOgetInterpolationWeights in order to interpolate vertex and point attributes.
Definition at line 336 of file GEO_Interpolate.h.
GEO_API void GEOgetInterpolationWeights | ( | const GEO_Detail * | detail, |
GA_Offset | primoff, | ||
UT_Array< GA_Offset > & | offsets, | ||
UT_Array< float > & | weights, | ||
const UT_Vector3 & | uvw, | ||
bool | is_point_offsets = false |
||
) |
Fill the offsets and weights arrays with the vertex/point offsets and their corresponding interpolation weights for the given primitive parametric space coordinate uvw, for the specified primitive.
This acts like GEO_Primitive::computeInteriorPointWeights(), except that it avoids hardening the primitive list if the primitive is a polygon or tetrahedron, and if is_point_offsets is true, it will convert the offsets to point offsets, instead of staying with vertex offsets.
|
inline |
Definition at line 126 of file GEO_Interpolate.h.
void geoInterpolateAttributes | ( | const GEO_Detail * | source, |
const GA_AttributeRefMap & | attribmap, | ||
const GA_Range & | destrange, | ||
const GA_ROHandleT< INT > & | primnumattrib, | ||
const GA_ROHandleV3 & | primuvwattrib, | ||
const GEO_InterpolationOptions & | options | ||
) |
Interpoates attributes based on primitive index and (u,v,w) INT must be int32 or int64.
void geoInterpolateAttributes | ( | const GEO_Detail * | source, |
const GA_AttributeRefMap & | attribmap, | ||
const GA_Range & | destrange, | ||
const GA_ROHandleT< INT > & | primnumattrib, | ||
const GA_ROHandleV3 & | primuvwattrib, | ||
GA_AttributeOwner | computenumbersof, | ||
GA_Attribute * | computeindexattrib, | ||
GA_Attribute * | computeweightattrib, | ||
const GEO_InterpolationOptions & | options | ||
) |
Interpoates attributes based on primitive number and (u,v,w), and fills in computeindexattrib and computeweightattrib with the point or vertex indices and weights that produced the interpolation. computenumbersof determines whether computeindexattrib receives point or vertex indices. computeindexattrib and computeweightattrib must implement GA_AIFNumericArray. INT must be int32 or int64.
GEO_API void geoInterpolateAttributes | ( | const GEO_Detail * | source, |
const GA_AttributeRefMap & | attribmap, | ||
const GA_Range & | destrange, | ||
GA_AttributeOwner | indexowner, | ||
const GA_Attribute * | indexattrib, | ||
const GA_Attribute * | weightattrib, | ||
const GEO_InterpolationOptions & | options | ||
) |
Interpoates attributes based on arrays of indices and weights specified in indexattrib and weightattrib. indexowner specifies whether the source indices are for points, vertices, or primitives. indexattrib and weightattrib must implement GA_AIFNumericArray.
|
inline |
Definition at line 84 of file GEO_Interpolate.h.
|
inline |
Definition at line 95 of file GEO_Interpolate.h.