In the area of computer graphics and in particular in the area of b-spline or NURBS curve editing and manipulation, it is typical for graphical curves, after they have been drafted, to be edited by users. Conventionally, there are two major approaches to editing curves in existing solutions.
The first conventional approach is to directly edit the curve data, i.e., either edit points of the curve or the control vertices of the control polygon.
In this method the user directly selects an edit point for example and moves it to a new location. The other points on the curve remain fixed and the curve re-interpolates through the new location. Because the other edit points do not know how to react intelligently to this edit, the curve shape is often distorted, requiring many more edits to re-achieve a pleasing shape.
The second conventional approach entails an edit using a special command. In this method, the user chooses a special command for editing the curves, where the special command contains some intelligence on how to edit the points as a set. For example, a user might choose a scale command and scale the curve in X, but not in Y and Z. This keeps the general curve shape, but has several significant downsides. The most important downside is that by making this command-based, the element is not able to react appropriately if it is asked to edit outside the context of this command. For example, in current associative (or history-based) systems, a change to another curve might require this curve to change to stay connected. Because the intelligence for a “shape-preserving” modification is not maintained within the curve, it cannot react appropriately, and instead edits in a “local” manner as described in the first conventional technique above.
Some commercial software tools with curve-editing capabilities take a “global” approach to curve editing, where by default the curve scales rather than deforming. That is, when a scaling handle of the curve graphic is dragged in a specific direction, the curve will scale in the x-dimension, the y-dimension, or both, while maintaining a basic form of its original shape. This crude “shape preservation” method has specific limitations, however.
One limitation of this technique is that the curve editing is indirect, in that scaling can only be done by manipulating a global scaling handle point. The user is unable to modify a point on the curve specifically and have the rest of the curve update globally.
Further, this type of curve editing is limited to single edits; the user is unable to edit multiple points on the curve in multiple different directions and have the curve respond appropriately.
Finally, this conventional graphical edit cannot be triggered by an outside event, such as another object being modified; it must be manually performed by the user.
There is, therefore, a need in the art for an improved system, method, and computer program product for intelligently preserving shape properties of a curve when being manually or automatically edited.