|
|
virtual Sint32 |
set_basis_type (Basis_type type)=0 |
|
Sets the basis type. More...
|
|
virtual Basis_type |
get_basis_type () const =0 |
|
Returns the basis type. More...
|
|
virtual Sint32 |
set_degree (Parameter_space_dimension dim, Uint32 degree)=0 |
|
Sets the basis degree. More...
|
|
virtual Uint32 |
get_degree (Parameter_space_dimension dim) const =0 |
|
Returns the basis degree. More...
|
|
|
virtual Sint32 |
set_patches_size (Parameter_space_dimension dim, Uint32 count)=0 |
|
Sets the number of patches. More...
|
|
virtual Uint32 |
get_patches_size (Parameter_space_dimension dim) const =0 |
|
Returns the number of patches. More...
|
|
|
virtual Uint32 |
get_parameters_size (Parameter_space_dimension dim) const =0 |
|
Returns the size of the parameter vector. More...
|
|
virtual Sint32 |
set_parameter (Parameter_space_dimension dim, Uint32 index, Float64 value)=0 |
|
Sets a parameter. More...
|
|
virtual Float64 |
get_parameter (Parameter_space_dimension dim, Uint32 index) const =0 |
|
Returns a parameter. More...
|
|
|
virtual Uint32 |
get_control_points_size (Parameter_space_dimension dim) const =0 |
|
Returns the number of control points. More...
|
|
virtual Sint32 |
set_control_point (Uint32 index_u, Uint32 index_v, Float32_3_struct p)=0 |
|
Sets a control point. More...
|
|
virtual Sint32 |
get_control_point (Uint32 index_u, Uint32 index_v, Float32_3_struct &p) const =0 |
|
Returns a control point. More...
|
|
virtual Sint32 |
set_control_point (Uint32 index_u, Uint32 index_v, Float64_3_struct p)=0 |
|
Sets a control point. More...
|
|
virtual Sint32 |
get_control_point (Uint32 index_u, Uint32 index_v, Float64_3_struct &p) const =0 |
|
Returns a control point. More...
|
|
virtual Sint32 |
set_weight (Uint32 index_u, Uint32 index_v, Float32 weight)=0 |
|
Sets a weight. More...
|
|
virtual Sint32 |
get_weight (Uint32 index_u, Uint32 index_v, Float32 &weight) const =0 |
|
Returns a weight. More...
|
|
virtual Sint32 |
set_weight (Uint32 index_u, Uint32 index_v, Float64 weight)=0 |
|
Sets a weight. More...
|
|
virtual Sint32 |
get_weight (Uint32 index_u, Uint32 index_v, Float64 &weight) const =0 |
|
Returns a weight. More...
|
|
virtual void |
set_rational (bool rational)=0 |
|
Sets the rational flag. More...
|
|
virtual bool |
get_rational () const =0 |
|
Returns the rational flag. More...
|
|
|
virtual Sint32 |
set_range (Parameter_space_dimension dim, Float64 range_min, Float64 range_max)=0 |
|
Sets the parameter range. More...
|
|
virtual Sint32 |
get_range (Parameter_space_dimension dim, Float64 &range_min, Float64 &range_max) const =0 |
|
Returns the parameter range. More...
|
|
|
virtual Uint32 |
curves_size () const =0 |
|
Returns the number of curves. More...
|
|
virtual ICurve * |
add_curve ()=0 |
|
Adds and returns a new curve. More...
|
|
virtual const ICurve * |
access_curve (Curve_handle_struct c) const =0 |
|
Returns a curve (const). More...
|
|
virtual ICurve * |
edit_curve (Curve_handle_struct c)=0 |
|
Returns a curve (mutable). More...
|
|
virtual Sint32 |
remove_curve (Curve_handle_struct c)=0 |
|
Removes a curve. More...
|
|
|
virtual Uint32 |
texture_surfaces_size () const =0 |
|
Returns the number of texture surfaces. More...
|
|
virtual ITexture_surface * |
add_texture_surface ()=0 |
|
Adds and returns a new texture surface. More...
|
|
virtual const ITexture_surface * |
access_texture_surface (Texture_surface_handle_struct t) const =0 |
|
Returns a texture surface (const). More...
|
|
virtual ITexture_surface * |
edit_texture_surface (Texture_surface_handle_struct t) const =0 |
|
Returns a texture surface (mutable). More...
|
|
virtual Sint32 |
remove_texture_surface (Texture_surface_handle_struct t)=0 |
|
Removes a texture surface. More...
|
|
|
typedef Interface_declare< id1,
id2, id3, id4, id5, id6, id7,
id8, id9, id10, id11,
IInterface > |
Self |
|
Own type. More...
|
|
typedef Uuid_t< id1, id2, id3,
id4, id5, id6, id7, id8, id9,
id10, id11 > |
IID |
|
Declares the interface ID (IID) of this interface. More...
|
|
static bool |
compare_iid (const Uuid &iid) |
|
Compares the interface ID iid against the interface ID of this interface and of its ancestors. More...
|
|
A surface of a freeform surface.
Surfaces are defined by their basis type, degree (in U and V direction), number of patches (in U and V direction), the parameter vector (in U and V direction), and the 2-dimensional grid of control points. In case of rational surfaces, an additional weight is associated with each control point.
Two basis types are currently supported: Bezier and B-Spline.
Note the distinction between surfaces and patches. A patch is the smallest unit that can be described with a given basis. For example, a patch for a cubic Bezier bases has 4 x 4 control points. A surface consists of one or more patches. Neighboring patches share control points. For example, a patch in a B-Spline surface of degrees d
in a given parameter space dimension shares its last d
control points with the next patch in that dimension.
The degree, the number of patches, the length of the parameter vector, and the number of control points in a given parameter space dimension are related as follows:
|
Bezier basis |
B-Spline basis |
#parameters |
#patches + 1 |
#patches + 2*degree + 1 |
#control points |
#patches * degree + 1 |
#patches + degree |
The degree and the number of patches can be explicitly controlled (see set_degree() and set_patches_size()). The numbers of parameters and controls points are automatically computed based on the degree and the number of patches.
Furthermore, surfaces can be trimmed by parametric curves (see mi::neuraylib::ICurve). Texture surfaces can be attached to specify how surface vertices are mapped to texture coordinates (see mi::neuraylib::ITexture_surface).
Curves and texture surfaces are stored with consecutive indices, starting with the index 0. For type safety, indices of curves and textures surfaces are represented using mi::neuraylib::Curve_handle and mi::neuraylib::Texture_surface_handle instead of plain integers.
- See Also
-
mi::neuraylib::IFreeform_surface
-
mi::neuraylib::ICurve
-
mi::neuraylib::ITexture_surface
-
mi::neuraylib::Parameter_space_dimension
-
mi::neuraylib::Basis_type