DiscussionsIssue archiveDraw Harness and Samples

Archived discussion

Primitive (Triangles) does not appear on AIS Context

Draw Harness and SamplesSat, 11/10/2018 - 23:331 reply

Browse this forum
QuestionAuthor

Hello.

I am trying to display triangles () on a created AIS Context and still cannot see the rendering unfortunately. here is how I implemented the Graphic3d_Group:

// Graphic 3D Environment Settings

StructMng = gcnew NCollection_Haft<Handle(Graphic3d_StructureManager)>(myAISContext()->MainPrsMgr()->StructureManager());

aPresentation = gcnew NCollection_Haft<Handle(Prs3d_Presentation)>(new Prs3d_Presentation(StructMng()));

aGroup = gcnew NCollection_Haft<Handle(Graphic3d_Group)>(Prs3d_Root::CurrentGroup(aPresentation())); 

Handle(Graphic3d_ArrayOfTriangles) myArray = ......;

.

.

.

.

aGroup()->AddPrimitiveArray(myArray);

Discussion

1 archived reply

Posts are displayed in their archived order.

01Commenter-1

Hi,

to display triangles in AIS Context you can use this structure :

MeshVS_Mesh mesh;

aiscontext->Display(mesh) 

or

AIS_Triangulation tri; 

aiscontext->Display(tri) 

AIS_Context is use to display Object with the type AIS_InteractiveObject.