User name:
Password:
Forgot password?
Create an account!
« back
Please log in to write a message.
2. Johannes (Apr 26, 2010 13.49):
i can't figure out what goes wrong... but take a look on the following code. it works fine with your definition of arrNormal. the result is the identifier of the cutting plane.
1. mrgordon (Apr 26, 2010 13.02):
I have a set of rectangular prisms and I want to split each one in half by bisecting its longest dimension. My plan was to generate a cutplane for each prism and I have already calculated a StartPoint and an EndPoint along the middle of each object where I want to cut. I have been struggling for days with the Rhino.AddCutPlane method because I have been unable to generate arrNormal (the optional fourth argument) correctly. If I call AddCutPlane on each of the prisms with a correct StartPoint and EndPoint, I get different orientations for the cutplanes that are generated even if I use the same value for arrNormal. Could this have something to do with CPlane vs. WorldPlane, a bug in my code, or something else altogether? Any insight on how I can solve this (with or without AddCutPlane) would be much appreciated. I'm ready to give up on using AddCutPlane but I can get it to properly orient the cutplanes about 75% of the time, so it's really frustrating. I've tried generating normals using both of the following formats: