
Thu, 10/19/2000 - 07:28
Hello,
I have some problems with the visualization of vectors. The following code use the Handle_Graphic3d_Group. But it seems, that there is no function for the visualization of a vector (as an arrow with a vertex) between the both points (gp_Pnt) P1 and P2. I only find the function Polyline to visualize a line between P1 and P2.
void DisplayObject::InsertVector (const Handle_Graphic3d_Group& g) const { g->BeginPrimitives();
for (int i=0; i for (int j=0; j QPoint P1 = Value1(i,j); QPoint P2 = Value2(i,j); Graphic3d_Array1OfVertexC theArray(1,2); theArray(1).SetCoord(P1.X(),P1.Y(),P1.Z()); theArray(1).SetColor(GetColor (i,j)); theArray(2).SetCoord(P2.X(),P2.Y(),P2.Z()); theArray(2).SetColor(GetColor (i,j)); g->Polyline(theArray); } } g->EndPrimitives(); } With advanced Thanks, Frank Conrad
Thu, 10/19/2000 - 16:59
Hello Frank, you could try using DsgPrs_XYZAxisPresentation, look at the source for AIS_Axis to see how to use it. You might also use directly AIS_Axis...
Francois.