how to Use Smooth Lighting to the AIS_Triangulation?

I am using the following code to build a triangulation:

Handle(AIS_Triangulation) m_hTriObject = new AIS_Triangulation(poly);
m_hAisContext->Display(m_hTriObject, Standard_True);
m_hAisContext->SetDisplayMode(m_hTriObject, AIS_WireFrame, true);

Then how can i Use Smooth Lighting to the AIS_Triangulation

Sincerely, yang

gkv311 n's picture

Is there any particular reason for using AIS_Triangulation instead of AIS_Shape? I would suggest using AIS_Shape, when possible.

Otherwise, don't forget to compute vertex normals (using BRepLib_ToolTriangulatedShape::ComputeNormals() or something else) for your Poly_Triangulation before displaying it.