VTK  9.3.1
Types.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
3 #pragma once
4 
5 #include "vtkRenderingRayTracingModule.h"
6 #include <stdint.h>
7 #include <sys/types.h>
8 
9 VTK_ABI_NAMESPACE_BEGIN
10 typedef enum : uint32_t
11 {
19 } RTWError;
20 
21 typedef enum : uint32_t
22 {
23  RTW_FB_NONE, //< framebuffer will not be mapped by application
24  RTW_FB_RGBA8, //< one dword per pixel: rgb+alpha, each one byte
25  RTW_FB_SRGBA, //< one dword per pixel: rgb (in sRGB space) + alpha, each one byte
26  RTW_FB_RGBA32F, //< one float4 per pixel: rgb+alpha, each one float
28 
29 typedef enum : uint32_t
30 {
31  RTW_FB_COLOR = (1 << 0),
32  RTW_FB_DEPTH = (1 << 1),
33  RTW_FB_ACCUM = (1 << 2),
34  RTW_FB_VARIANCE = (1 << 3),
35  RTW_FB_NORMAL = (1 << 4),
36  RTW_FB_ALBEDO = (1 << 5),
38 
39 // OSPRay events which can be waited on via ospWait()
40 typedef enum : uint32_t
41 {
47 } RTWSyncEvent;
48 
49 // OSPRay cell types definition for unstructured volumes, values are set to match VTK
50 typedef enum : uint8_t
51 {
54  RTW_WEDGE = 13,
58 
59 // OSPRay PerspectiveCamera stereo image modes
60 typedef enum : uint8_t
61 {
68 
69 // OSPRay Curves geometry types
70 typedef enum : uint8_t
71 {
76 } RTWCurveType;
77 
78 // OSPRay Curves geometry bases
79 typedef enum : uint8_t
80 {
88 
89 // AMR Volume rendering methods
90 typedef enum : uint8_t
91 {
95 } RTWAMRMethod;
96 
97 typedef enum : uint32_t
98 {
116 
117 typedef enum :uint32_t
118 {
122 
123 typedef enum : uint32_t
124 {
125  // Object reference type.
126  RTW_DEVICE = 100,
127 
128  // Void pointer type.
130 
131  // Booleans, same size as RTW_INT.
132  RTW_BOOL = 250,
133 
134  // highest bit to represent objects/handles
135  RTW_OBJECT = 0x8000000,
136 
137  // object subtypes
138  RTW_DATA = 0x8000000 + 100,
155 
156  // Pointer to a C-style NULL-terminated character string.
157  RTW_STRING = 1500,
158 
159  // Character scalar type.
160  RTW_CHAR = 2000,
161 
162  // Unsigned character scalar and vector types.
164  RTW_BYTE = 2500, //XXX RTW_UCHAR, ISPC issue #1246
165  RTW_RAW = 2500, //XXX RTW_UCHAR, ISPC issue #1246
166 
167  // Signed 16-bit integer scalar.
168  RTW_SHORT = 3000,
169 
170  // Unsigned 16-bit integer scalar.
171  RTW_USHORT = 3500,
172 
173  // Signed 32-bit integer scalar and vector types.
175 
176  // Unsigned 32-bit integer scalar and vector types.
178 
179  // Signed 64-bit integer scalar and vector types.
181 
182  // Unsigned 64-bit integer scalar and vector types.
184 
185  // Single precision floating point scalar and vector types.
187 
188  // Double precision floating point scalar type.
189  RTW_DOUBLE = 7000,
190 
191  // Signed 32-bit integer N-dimensional box types
193 
194  // Single precision floating point N-dimensional box types
196 
197  // Transformation types
199 
200  // Guard value.
201  RTW_UNKNOWN = 9999999
202 } RTWDataType;
203 
204 typedef enum : uint32_t
205 {
209 VTK_ABI_NAMESPACE_END
210 
211 namespace rtw
212 {
213 VTK_ABI_NAMESPACE_BEGIN
214  struct vec2f { float x, y; };
215  struct vec2i { int x, y; };
216  struct vec3i { int x, y, z; };
217  struct vec3ui { unsigned int x, y, z; };
218  struct vec3f { float x, y, z; };
219  struct vec4f { float x, y, z, w; };
220  struct box3i { vec3i lower, upper; };
221  struct box3f { vec3f lower, upper; };
222  struct linear3f { vec3f vx, vy, vz; };
223  struct affine3f { linear3f l; vec3f p; };
224 VTK_ABI_NAMESPACE_END
225 }
226 
227 VTK_ABI_NAMESPACE_BEGIN
228 
229 typedef struct RTWHandle
231 *RTWRenderer,
232 *RTWCamera,
233 *RTWGroup,
234 *RTWInstance,
237 *RTWWorld,
238 *RTWData,
239 *RTWGeometry,
240 *RTWMaterial,
241 *RTWLight,
242 *RTWVolume,
244 *RTWTexture,
245 *RTWObject;
246 
247 typedef RTWTexture RTWTexture2D;
248 
249 typedef enum : uint32_t
250 {
257 } RTWFeature;
258 VTK_ABI_NAMESPACE_END
struct RTWHandle * RTWObject
Definition: Types.h:229
int y
Definition: Types.h:216
RTWTexture RTWTexture2D
Definition: Types.h:247
RTWAMRMethod
Definition: Types.h:90
float y
Definition: Types.h:219
unsigned int z
Definition: Types.h:217
unsigned int y
Definition: Types.h:217
int z
Definition: Types.h:216
float z
Definition: Types.h:218
RTWCurveBasis
Definition: Types.h:79
RTWTextureFilter
Definition: Types.h:117
RTWCurveType
Definition: Types.h:70
struct RTWHandle * RTWInstance
Definition: Types.h:229
struct RTWHandle * RTWRenderer
Definition: Types.h:229
float y
Definition: Types.h:214
struct RTWHandle * RTWVolumetricModel
Definition: Types.h:229
vec3i upper
Definition: Types.h:220
Definition: Types.h:174
Definition: Types.h:165
float x
Definition: Types.h:219
struct RTWHandle * RTWCamera
Definition: Types.h:229
RTWFrameBufferChannel
Definition: Types.h:29
struct RTWHandle * RTWGeometry
Definition: Types.h:229
vec3f vy
Definition: Types.h:222
RTWFrameBufferFormat
Definition: Types.h:21
struct RTWHandle * RTWData
Definition: Types.h:229
RTWTextureFormat
Definition: Types.h:97
RTWFeature
Definition: Types.h:249
int x
Definition: Types.h:216
float y
Definition: Types.h:218
linear3f l
Definition: Types.h:223
RTWStereoMode
Definition: Types.h:60
vec3f lower
Definition: Types.h:221
struct RTWHandle * RTWGeometricModel
Definition: Types.h:229
struct RTWHandle * RTWFrameBuffer
Definition: Types.h:229
float w
Definition: Types.h:219
vec3f p
Definition: Types.h:223
RTWDataType
Definition: Types.h:123
Definition: Types.h:211
Definition: Types.h:73
RTWBackendType
Definition: Types.h:204
int y
Definition: Types.h:215
struct RTWHandle * RTWWorld
Definition: Types.h:229
int x
Definition: Types.h:215
struct RTWHandle * RTWGroup
Definition: Types.h:229
RTWSyncEvent
Definition: Types.h:40
struct RTWHandle * RTWTransferFunction
Definition: Types.h:229
vec3i lower
Definition: Types.h:220
struct RTWHandle * RTWMaterial
Definition: Types.h:229
struct RTWHandle * RTWTexture
Definition: Types.h:229
float x
Definition: Types.h:218
vec3f upper
Definition: Types.h:221
float z
Definition: Types.h:219
RTWUnstructuredCellType
Definition: Types.h:50
struct RTWHandle * RTWVolume
Definition: Types.h:229
unsigned int x
Definition: Types.h:217
struct RTWHandle * RTWLight
Definition: Types.h:229
float x
Definition: Types.h:214
vec3f vx
Definition: Types.h:222
RTWError
Definition: Types.h:10
vec3f vz
Definition: Types.h:222