QuadraticBezier
Create a rational Bézier curve of degree 2in 2D or 3D.
Syntax
model.component(<ctag>).geom(<tag>).create(<ftag>,"QuadraticBezier");
model.component(<ctag>).geom(<tag>).feature(<ftag>).set(property,<value>);
model.component(<ctag>).geom(<tag>).feature(<ftag>).getType(property);
Description
Use model.component(<ctag>).geom(<tag>).create(<ftag>,"QuadraticBezier") to create a quadratic Bézier curve in 2D or 3D. The following properties are available:
none | custom | integer between 1 and the number of colors in the current theme
The color to use. Active when color is set to custom.
on | off
all | obj | dom | bnd | pnt | off
Show selections, if selresult is on, in physics, materials, and so on; in part instances; or in 3D from a plane geometry. obj is not available in a component’s geometry. dom, bnd, and edg are not available in all features.
{1, 1/sqrt(2), 1}
this | Part Instance feature
xyplane | Work Plane feature
For information about the selresult and contributeto properties, see Selections of Geometric Entities.
Example
The following commands creates a quadratic Bézier curve in 2D with control points in (4, 2); (8, 8); and (16, 4):
Code for Use with Java
Model model = ModelUtil.create("Model1");
model.component().create("comp1");
GeomSequence g = model.component("comp1").geom().create("geom1",3);
g.create("qb1", "QuadraticBezier");
g.feature("qb1").setIndex("p", 4, 0, 0);
g.feature("qb1").setIndex("p", 2, 1, 0);
g.feature("qb1").setIndex("p", 8, 0, 1);
g.feature("qb1").setIndex("p", 8, 1, 1);
g.feature("qb1").setIndex("p", 16, 0, 2);
g.feature("qb1").setIndex("p", 4, 1, 2);
g.run();
Code for Use with MATLAB
model = ModelUtil.create('Model');
model.component.create('comp1');
g = model.component('comp1').geom.create('geom1', 3);
g.create('qb1','QuadraticBezier');
g.feature('qb1').setIndex('p', 4, 0, 0);
g.feature('qb1').setIndex('p', 2, 1, 0);
g.feature('qb1').setIndex('p', 8, 0, 1);
g.feature('qb1').setIndex('p', 8, 1, 1);
g.feature('qb1').setIndex('p', 16, 0, 2);
g.feature('qb1').setIndex('p', 4, 1, 2);
g.run;
See Also
CubicBezier, CompositeCurve