Jump to content
Sign in to follow this  
Nasyrov

get vertex info

Recommended Posts

Hi there. There is a primitive (GEO_Primitive) loaded into VRAY shader. I want to take values of attributes in vertices.

I'm trying to do this by evaluateInteriorPoint (GEO_Vertex &result, GEO_AttributeHandleList &hlist, fpreal u, fpreal v) const

But nothing good happens. Mantra crashes.

Thanks

Share this post


Link to post
Share on other sites

so as this

GEO_Vertex vert;

vert = skinPrim->getVertex(0);

GEO_Point *ppt;

ppt = vert.getPt();

const UT_Vector3 *cCd = ppt->castAttribData<UT_Vector3>(densID);

UT_Vector3 Cd= *cCd;

printf("\n%f\n", Cd.x());

Share this post


Link to post
Share on other sites

Could you explain guys what GEO_AttributeHandleList is? Is it some sort of filter "which attribute to query, how to filter and so on"? Shall I and how to initialize it prior to call evaluateInteriorPoint()?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×