Hello!
In my Open Cascade project I have a class derived from AIS_InteractiveObject which includes a private member: Handle(AIS_PointCloud) aPntCloud;
I like to display the content of this cloud_of_points variable but so far I haven't succeeded.
When I try to display the cloud_of_points using GetContext()->Display(aPntCloud, false); nothing is displayed on the screen.
The Display() method is invoked inside Compute() method of my AIS_InteractiveObject class.
Instead when I move the cursor in the vertexes region, the bounding box of the entire cloud is displayed all the time.
What is wrong?
What can be done to properly display the cloud_of_points?
Any idea is welcome!
Thank you!
In my Open Cascade project I have a class derived from AIS_InteractiveObject which includes a private member: Handle(AIS_PointCloud) aPntCloud;
I like to display the content of this cloud_of_points variable but so far I haven't succeeded.
C++:
Graphic3d_ArrayFlags aArrayFlags = Graphic3d_ArrayFlags_None;
aArrayFlags |= Graphic3d_ArrayFlags_VertexColor;
Handle(Graphic3d_ArrayOfPoints) aPointsArray = new Graphic3d_ArrayOfPoints(6, aArrayFlags);
aPointsArray->AddVertex(gp_Pnt(160, 115, 15), Quantity_Color(Quantity_NOC_MAGENTA));
aPointsArray->AddVertex(gp_Pnt(160, 115, 0), Quantity_Color(Quantity_NOC_MAGENTA));
aPointsArray->AddVertex(gp_Pnt(65, 115, 0), Quantity_Color(Quantity_NOC_MAGENTA));
aPointsArray->AddVertex(gp_Pnt(65, 65, 0), Quantity_Color(Quantity_NOC_MAGENTA));
aPointsArray->AddVertex(gp_Pnt(160, 65, 0), Quantity_Color(Quantity_NOC_MAGENTA));
aPointsArray->AddVertex(gp_Pnt(160, 65, 15), Quantity_Color(Quantity_NOC_MAGENTA));
aPntCloud = new AIS_PointCloud();
aPntCloud->SetPoints(aPointsArray);
When I try to display the cloud_of_points using GetContext()->Display(aPntCloud, false); nothing is displayed on the screen.
The Display() method is invoked inside Compute() method of my AIS_InteractiveObject class.
Instead when I move the cursor in the vertexes region, the bounding box of the entire cloud is displayed all the time.
What is wrong?
What can be done to properly display the cloud_of_points?
Any idea is welcome!
Thank you!