...
More information on cutting planes can be found in the docs.
Code Block | ||
---|---|---|
| ||
//Create cutting plane const bounding = await hwv.model.getModelBounding(true, true); const axis = Communicator.Axis.X; const position = bounding.min; const referenceGeometry = hwv.cuttingManager.createReferenceGeometryFromAxis(axis, bounding); const plane = Communicator.Plane.createFromPointAndNormal(position, new Communicator.Point3(1, 0, 0)); const cuttingSection = hwv.cuttingManager.getCuttingSection(0); cuttingSection.addPlane(plane, referenceGeometry); await cuttingSection.activate(); //Invert normal and d values of plane var myPlane = cuttingSection.getPlane(0); myPlane.normal.negate(); myPlane.d *= -1; //Update plane cuttingSection.updatePlane(0, myPlane); |
...