
Aaron Spike wrote:
Bob Jamison wrote:
One of the new features of this release is the exporting of SVG Paths to Bezier prisms for POVRay. I think that if you compare an SVG file with the Bezier segments that it generates, then you will probably have a good idea how to do the same for DXF.
I took a quick look. It seems the Bezier segments in the POV files are still Beziers. DXF does NURBs. Now I am completely clueless, but from what I understand. Beziers are special case NURBs. I guess I need to know, "when is a NURB a Bezier?" So that I can make fullfleged NURBs from the beziers I have.
The main idea is that you must change the MoveTo/LineTo/CurveTo data to a set of Splines, each with the start point and its control point(s), and the end point and its control point(s).
Correct. And I do have a working version that breaks a path into many NURBs one for each bezier segment. Works great. I was hoping to not break the paths apart. If I could do them in a single spline they would hang together and be easier to move and edit.
Keep in mind that a SVG path is actually a set of subpaths, connected together. A single spline cannot do this, unless it is of very high order.
If this is what I think it is, then I have seen this on the web before. Maybe you want to to turn the cusps (non-continuous points on the path set) into curves?
Basically, you turn two 3d order splines into a single 4th order spline, then reduce it to the closest approximation single 3d order spline you can get. Is that right?
If you come up with a generalized Path->NURB conversion, let us know. If it is clear enough to unenlightened 3d-ers like me, maybe we can make a hardcoded export filter for it.
Bob