coordinate system of normal from ComputeDerivatives method

coordinate system of normal from ComputeDerivatives method

Anonymous
Not applicable
705 Views
1 Reply
Message 1 of 2

coordinate system of normal from ComputeDerivatives method

Anonymous
Not applicable

Hi, I am confused with coordinate systems:

 

(1) From GeometryInstance.Transform property, we can get the norm = Transform.basisX,  this normal is based on the document coordinate system, is that right? But some code shows that, we should do transform to get normal vector based on document systems. 

 

(2) ComputeDerivatives of Face class, the normal and tangent vectors are based on the document coordinate system?  Is that the instance coordinate system the same as the document coordinate system?   For example, see following code

 

Autodesk.Revit.DB.XYZ FaceNormal = m_face.ComputeDerivatives(endptUV).BasisZ;  

 FaceNormal = reference.GetInstanceTransform().OfVector(FaceNormal); // transformation to get document coordinates instead of the parent symbol

 

I am confused (a) the coordinate system in Revit, and (b) whether I need to do additional transform of vectors calcualted by ComputeDerivatives() to document coordinate system?

0 Likes
706 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable

Answer my own question,

 

My test shows that coordinates calculated by ComputeDerivatives() falls into model space.  Transform matrix is identity.

0 Likes