Changing the origin of a Matrix

Trips

Well-known member
Joined
Aug 7, 2010
Messages
2,788
Hi there,
I am using C# and trying to change the origin of a matrix so that it does not start at point (0,0,0) but at (distance, distance, 0), where distance is a double value.
This is the code so far which works, but I am not sure how to change the origin.
public void ColumnMatrix(int xNumber, int yNumber, double distance)<br/>
{<br/>
m_columnMatrixUV = new Autodesk.Revit.DB.UV[xNumber, yNumber];<br/>
<br/>
for (int i = 0; i < xNumber ; i++)<br/>
{<br/>
for (int j = 0; j < yNumber ; j++)<br/>
{<br/>
m_columnMatrixUV[i, j] = new Autodesk.Revit.DB.UV(i * distance, j * distance);<br/>
}<br/>
}<br/>
}

I have searched the web but cannot find anything and have also tried to add an
XYZ startpoint = new XYZ();
but cannot seem to input it in the matrix anywhere.
Any help appreciated.
Best regards,
Mike

View the full article
 
Back
Top