How to create Graphic3d_ClipPlane instance

Hi,

When i tried to compile below codes, i got error at line create Graphic3d_ClipPlane instance.

Graphic3d_SequenceOfHClipPlane aPlanes;
gp_Pln pln(gp_Pnt(0, 0, 0), gp_Dir(0, 1, 0));
Handle(Graphic3d_ClipPlane) thePlane = new Graphic3d_ClipPlane(pln); /// compile error
aPlanes.Append(thePlane);
m_hView->SetClipPlanes(aPlanes);

I am using OCC 6.7.1 and VS2012.

Appreciate your help.

zbaekhk's picture

Compiler Error C2834

Forum supervisor's picture

Dear BAEK HUM KYUNG,
I would suggested you to read chapter "New features / Object-level clipping planes with optional capping" for OCCT 6.7.0 Release Notes.
Example of using you can find at the file ViewerTest_ViewerCommands.cxx (see command