Iray SDK API nvidia_logo_transpbg.gif Up
isubdivision_surface.h
Go to the documentation of this file.
1/***************************************************************************************************
2 * Copyright 2024 NVIDIA Corporation. All rights reserved.
3 **************************************************************************************************/
6
7#ifndef MI_NEURAYLIB_ISUBDIVISION_SURFACE_H
8#define MI_NEURAYLIB_ISUBDIVISION_SURFACE_H
9
11
12namespace mi {
13
14class IArray;
15
16namespace neuraylib {
17
31 VERTEX_FEATURE_FORCE_32_BIT = 0xffffffffU
32};
33
34mi_static_assert( sizeof( Vertex_feature) == sizeof( Uint32));
35
56 public base::Interface_declare<0x6a65666a,0x849d,0x4081,0xaa,0x32,0xb3,0xa1,0xeb,0xa0,0x6f,0xe2,
57 neuraylib::IPolygon_mesh>
58{
59public:
61
62
64 virtual Uint32 triangles_size() const = 0;
65
72 virtual Uint32 triangles_capacity() const = 0;
73
80 virtual void reserve_triangles( Uint32 n) = 0;
81
83 virtual Uint32 quads_size() const = 0;
84
91 virtual Uint32 quads_capacity() const = 0;
92
99 virtual void reserve_quads( Uint32 n) = 0;
100
102
104
125
134
151
159 virtual const Float32* get_crease_values( Polygon_handle_struct p) const = 0;
160
174
176
178
187 virtual Sint32 set_vertex_feature( Uint32 index, Vertex_feature feature) = 0;
188
193 virtual Vertex_feature get_vertex_feature( Uint32 index) const = 0;
194
196};
197 // end group mi_neuray_leaf_nodes
199
200} // namespace neuraylib
201
202} // namespace mi
203
204#endif // MI_NEURAYLIB_ISUBDIVISION_SURFACE_H
This interface represents static arrays, i.e., arrays with a fixed number of elements.
Definition: iarray.h:37
Mixin class template for deriving new interface declarations.
Definition: interface_declare.h:43
Interface representing a subdivision surface.
Definition: isubdivision_surface.h:58
virtual Sint32 set_crease_value(Polygon_handle_struct p, Uint32 index, Float32 value)=0
Sets crease values for an edge.
virtual Vertex_feature get_vertex_feature(Uint32 index) const =0
Returns a vertex features.
virtual Sint32 set_crease_values(Polygon_handle_struct p, const Float32 *values)=0
Sets crease values for all edges of a polygon.
virtual Uint32 triangles_capacity() const =0
Returns the number of triangles for which space is allocated in the mesh.
virtual void reserve_quads(Uint32 n)=0
Reserves space for at least n quads.
virtual Uint32 quads_capacity() const =0
Returns the number of quads for which space is allocated in the mesh.
virtual IArray * get_inconsistent_crease_values() const =0
Checks all crease values for consistency and returns inconsistent values.
virtual const Float32 * get_crease_values(Polygon_handle_struct p) const =0
Returns crease values for all edges of a polygon.
virtual Sint32 set_vertex_feature(Uint32 index, Vertex_feature feature)=0
Sets a vertex feature.
virtual Uint32 quads_size() const =0
Returns the number of quads in the mesh.
virtual void reserve_triangles(Uint32 n)=0
Reserves space for at least n triangles.
virtual Uint32 triangles_size() const =0
Returns the number of triangles in the mesh.
virtual Float32 get_crease_value(Polygon_handle_struct p, Uint32 index) const =0
Returns crease values for an edge.
#define mi_static_assert(expr)
Compile time assertion that raises a compilation error if the constant expression expr evaluates to f...
Definition: assert.h:65
unsigned int Uint32
32-bit unsigned integer.
Definition: types.h:49
float Float32
32-bit float.
Definition: types.h:51
signed int Sint32
32-bit signed integer.
Definition: types.h:46
Vertex_feature
Vertex features.
Definition: isubdivision_surface.h:28
@ SMOOTH_VERTEX
the vertex is smooth (the default)
Definition: isubdivision_surface.h:29
@ CORNER_VERTEX
the vertex is a corner
Definition: isubdivision_surface.h:30
Scene element Polygon_mesh.
Common namespace for APIs of NVIDIA Advanced Rendering Center GmbH.
Definition: neuraylib.h:179
Handle class for type-safety.
Definition: identifier.h:56