NVIDIA OptiX 8.1 nvidia_logo_transpbg.gif Up
optix_device_impl_transformations.h
Go to the documentation of this file.
1/*
2* SPDX-FileCopyrightText: Copyright (c) 2019 - 2024 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
3* SPDX-License-Identifier: LicenseRef-NvidiaProprietary
4*
5* NVIDIA CORPORATION, its affiliates and licensors retain all intellectual
6* property and proprietary rights in and to this material, related
7* documentation and any modifications thereto. Any use, reproduction
8* disclosure or distribution of this material and related documentation
9* without an express license agreement from NVIDIA CORPORATION or
10* its affiliates is strictly prohibited.
11*/
20#if !defined( __OPTIX_INCLUDE_INTERNAL_HEADERS__ )
21#error("optix_device_impl_transformations.h is an internal header file and must not be used directly. Please use optix_device.h or optix.h instead.")
22#endif
23
24#ifndef OPTIX_OPTIX_DEVICE_IMPL_TRANSFORMATIONS_H
25#define OPTIX_OPTIX_DEVICE_IMPL_TRANSFORMATIONS_H
26
27namespace optix_impl {
28
29static __forceinline__ __device__ float4 optixAddFloat4( const float4& a, const float4& b )
30{
31 return make_float4( a.x + b.x, a.y + b.y, a.z + b.z, a.w + b.w );
32}
33
34static __forceinline__ __device__ float4 optixMulFloat4( const float4& a, float b )
35{
36 return make_float4( a.x * b, a.y * b, a.z * b, a.w * b );
37}
38
39static __forceinline__ __device__ uint4 optixLdg( unsigned long long addr )
40{
41 const uint4* ptr;
42 asm volatile( "cvta.to.global.u64 %0, %1;" : "=l"( ptr ) : "l"( addr ) );
43 uint4 ret;
44 asm volatile( "ld.global.v4.u32 {%0,%1,%2,%3}, [%4];"
45 : "=r"( ret.x ), "=r"( ret.y ), "=r"( ret.z ), "=r"( ret.w )
46 : "l"( ptr ) );
47 return ret;
48}
49
50template <class T>
51static __forceinline__ __device__ T optixLoadReadOnlyAlign16( const T* ptr )
52{
53 // Debug mode may keep this temporary variable
54 // If T does not enforce 16B alignment, v may not be 16B aligned and storing the loaded data from ptr fails
55 __align__(16) T v;
56 for( int ofs = 0; ofs < sizeof( T ); ofs += 16 )
57 *(uint4*)( (char*)&v + ofs ) = optixLdg( (unsigned long long)( (char*)ptr + ofs ) );
58 return v;
59}
60
61// Multiplies the row vector vec with the 3x4 matrix with rows m0, m1, and m2
62static __forceinline__ __device__ float4 optixMultiplyRowMatrix( const float4 vec, const float4 m0, const float4 m1, const float4 m2 )
63{
64 float4 result;
65
66 result.x = vec.x * m0.x + vec.y * m1.x + vec.z * m2.x;
67 result.y = vec.x * m0.y + vec.y * m1.y + vec.z * m2.y;
68 result.z = vec.x * m0.z + vec.y * m1.z + vec.z * m2.z;
69 result.w = vec.x * m0.w + vec.y * m1.w + vec.z * m2.w + vec.w;
70
71 return result;
72}
73
74// Converts the SRT transformation srt into a 3x4 matrix with rows m0, m1, and m2
75static __forceinline__ __device__ void optixGetMatrixFromSrt( float4& m0, float4& m1, float4& m2, const OptixSRTData& srt )
76{
77 // assumed to be normalized
78 const float4 q = {srt.qx, srt.qy, srt.qz, srt.qw};
79
80 const float sqw = q.w * q.w;
81 const float sqx = q.x * q.x;
82 const float sqy = q.y * q.y;
83 const float sqz = q.z * q.z;
84
85 const float xy = q.x * q.y;
86 const float zw = q.z * q.w;
87 const float xz = q.x * q.z;
88 const float yw = q.y * q.w;
89 const float yz = q.y * q.z;
90 const float xw = q.x * q.w;
91
92 m0.x = ( sqx - sqy - sqz + sqw );
93 m0.y = 2.0f * ( xy - zw );
94 m0.z = 2.0f * ( xz + yw );
95
96 m1.x = 2.0f * ( xy + zw );
97 m1.y = ( -sqx + sqy - sqz + sqw );
98 m1.z = 2.0f * ( yz - xw );
99
100 m2.x = 2.0f * ( xz - yw );
101 m2.y = 2.0f * ( yz + xw );
102 m2.z = ( -sqx - sqy + sqz + sqw );
103
104 m0.w = m0.x * srt.pvx + m0.y * srt.pvy + m0.z * srt.pvz + srt.tx;
105 m1.w = m1.x * srt.pvx + m1.y * srt.pvy + m1.z * srt.pvz + srt.ty;
106 m2.w = m2.x * srt.pvx + m2.y * srt.pvy + m2.z * srt.pvz + srt.tz;
107
108 m0.z = m0.x * srt.b + m0.y * srt.c + m0.z * srt.sz;
109 m1.z = m1.x * srt.b + m1.y * srt.c + m1.z * srt.sz;
110 m2.z = m2.x * srt.b + m2.y * srt.c + m2.z * srt.sz;
111
112 m0.y = m0.x * srt.a + m0.y * srt.sy;
113 m1.y = m1.x * srt.a + m1.y * srt.sy;
114 m2.y = m2.x * srt.a + m2.y * srt.sy;
115
116 m0.x = m0.x * srt.sx;
117 m1.x = m1.x * srt.sx;
118 m2.x = m2.x * srt.sx;
119}
120
121// Inverts a 3x4 matrix in place
122static __forceinline__ __device__ void optixInvertMatrix( float4& m0, float4& m1, float4& m2 )
123{
124 const float det3 =
125 m0.x * ( m1.y * m2.z - m1.z * m2.y ) - m0.y * ( m1.x * m2.z - m1.z * m2.x ) + m0.z * ( m1.x * m2.y - m1.y * m2.x );
126
127 const float inv_det3 = 1.0f / det3;
128
129 float inv3[3][3];
130 inv3[0][0] = inv_det3 * ( m1.y * m2.z - m2.y * m1.z );
131 inv3[0][1] = inv_det3 * ( m0.z * m2.y - m2.z * m0.y );
132 inv3[0][2] = inv_det3 * ( m0.y * m1.z - m1.y * m0.z );
133
134 inv3[1][0] = inv_det3 * ( m1.z * m2.x - m2.z * m1.x );
135 inv3[1][1] = inv_det3 * ( m0.x * m2.z - m2.x * m0.z );
136 inv3[1][2] = inv_det3 * ( m0.z * m1.x - m1.z * m0.x );
137
138 inv3[2][0] = inv_det3 * ( m1.x * m2.y - m2.x * m1.y );
139 inv3[2][1] = inv_det3 * ( m0.y * m2.x - m2.y * m0.x );
140 inv3[2][2] = inv_det3 * ( m0.x * m1.y - m1.x * m0.y );
141
142 const float b[3] = {m0.w, m1.w, m2.w};
143
144 m0.x = inv3[0][0];
145 m0.y = inv3[0][1];
146 m0.z = inv3[0][2];
147 m0.w = -inv3[0][0] * b[0] - inv3[0][1] * b[1] - inv3[0][2] * b[2];
148
149 m1.x = inv3[1][0];
150 m1.y = inv3[1][1];
151 m1.z = inv3[1][2];
152 m1.w = -inv3[1][0] * b[0] - inv3[1][1] * b[1] - inv3[1][2] * b[2];
153
154 m2.x = inv3[2][0];
155 m2.y = inv3[2][1];
156 m2.z = inv3[2][2];
157 m2.w = -inv3[2][0] * b[0] - inv3[2][1] * b[1] - inv3[2][2] * b[2];
158}
159
160static __forceinline__ __device__ void optixLoadInterpolatedMatrixKey( float4& m0, float4& m1, float4& m2, const float4* matrix, const float t1 )
161{
162 m0 = optixLoadReadOnlyAlign16( &matrix[0] );
163 m1 = optixLoadReadOnlyAlign16( &matrix[1] );
164 m2 = optixLoadReadOnlyAlign16( &matrix[2] );
165
166 // The conditional prevents concurrent loads leading to spills
167 if( t1 > 0.0f )
168 {
169 const float t0 = 1.0f - t1;
170 m0 = optixAddFloat4( optixMulFloat4( m0, t0 ), optixMulFloat4( optixLoadReadOnlyAlign16( &matrix[3] ), t1 ) );
171 m1 = optixAddFloat4( optixMulFloat4( m1, t0 ), optixMulFloat4( optixLoadReadOnlyAlign16( &matrix[4] ), t1 ) );
172 m2 = optixAddFloat4( optixMulFloat4( m2, t0 ), optixMulFloat4( optixLoadReadOnlyAlign16( &matrix[5] ), t1 ) );
173 }
174}
175
176static __forceinline__ __device__ void optixLoadInterpolatedSrtKey( float4& srt0,
177 float4& srt1,
178 float4& srt2,
179 float4& srt3,
180 const float4* srt,
181 const float t1 )
182{
183 srt0 = optixLoadReadOnlyAlign16( &srt[0] );
184 srt1 = optixLoadReadOnlyAlign16( &srt[1] );
185 srt2 = optixLoadReadOnlyAlign16( &srt[2] );
186 srt3 = optixLoadReadOnlyAlign16( &srt[3] );
187
188 // The conditional prevents concurrent loads leading to spills
189 if( t1 > 0.0f )
190 {
191 const float t0 = 1.0f - t1;
192 srt0 = optixAddFloat4( optixMulFloat4( srt0, t0 ), optixMulFloat4( optixLoadReadOnlyAlign16( &srt[4] ), t1 ) );
193 srt1 = optixAddFloat4( optixMulFloat4( srt1, t0 ), optixMulFloat4( optixLoadReadOnlyAlign16( &srt[5] ), t1 ) );
194 srt2 = optixAddFloat4( optixMulFloat4( srt2, t0 ), optixMulFloat4( optixLoadReadOnlyAlign16( &srt[6] ), t1 ) );
195 srt3 = optixAddFloat4( optixMulFloat4( srt3, t0 ), optixMulFloat4( optixLoadReadOnlyAlign16( &srt[7] ), t1 ) );
196
197 float inv_length = 1.f / sqrt( srt2.y * srt2.y + srt2.z * srt2.z + srt2.w * srt2.w + srt3.x * srt3.x );
198 srt2.y *= inv_length;
199 srt2.z *= inv_length;
200 srt2.w *= inv_length;
201 srt3.x *= inv_length;
202 }
203}
204
205static __forceinline__ __device__ void optixResolveMotionKey( float& localt, int& key, const OptixMotionOptions& options, const float globalt )
206{
207 const float timeBegin = options.timeBegin;
208 const float timeEnd = options.timeEnd;
209 const float numIntervals = (float)( options.numKeys - 1 );
210
211 // No need to check the motion flags. If data originates from a valid transform list handle, then globalt is in
212 // range, or vanish flags are not set.
213
214 // should be NaN or in [0,numIntervals]
215 float time = max( 0.f, min( numIntervals, numIntervals * __fdividef( globalt - timeBegin, timeEnd - timeBegin ) ) );
216
217 // catch NaN (for example when timeBegin=timeEnd)
218 if( time != time )
219 time = 0.f;
220
221 const float fltKey = fminf( floorf(time), numIntervals - 1 );
222
223 localt = time - fltKey;
224 key = (int)fltKey;
225}
226
227// Returns the interpolated transformation matrix for a particular matrix motion transformation and point in time.
228static __forceinline__ __device__ void optixGetInterpolatedTransformation( float4& trf0,
229 float4& trf1,
230 float4& trf2,
231 const OptixMatrixMotionTransform* transformData,
232 const float time )
233{
234 // Compute key and intra key time
235 float keyTime;
236 int key;
237 optixResolveMotionKey( keyTime, key, optixLoadReadOnlyAlign16( transformData ).motionOptions, time );
238
239 // Get pointer to left key
240 const float4* transform = (const float4*)( &transformData->transform[key][0] );
241
242 // Load and interpolate matrix keys
243 optixLoadInterpolatedMatrixKey( trf0, trf1, trf2, transform, keyTime );
244}
245
246// Returns the interpolated transformation matrix for a particular SRT motion transformation and point in time.
247static __forceinline__ __device__ void optixGetInterpolatedTransformation( float4& trf0,
248 float4& trf1,
249 float4& trf2,
250 const OptixSRTMotionTransform* transformData,
251 const float time )
252{
253 // Compute key and intra key time
254 float keyTime;
255 int key;
256 optixResolveMotionKey( keyTime, key, optixLoadReadOnlyAlign16( transformData ).motionOptions, time );
257
258 // Get pointer to left key
259 const float4* dataPtr = reinterpret_cast<const float4*>( &transformData->srtData[key] );
260
261 // Load and interpolated SRT keys
262 float4 data[4];
263 optixLoadInterpolatedSrtKey( data[0], data[1], data[2], data[3], dataPtr, keyTime );
264
265 OptixSRTData srt = {data[0].x, data[0].y, data[0].z, data[0].w, data[1].x, data[1].y, data[1].z, data[1].w,
266 data[2].x, data[2].y, data[2].z, data[2].w, data[3].x, data[3].y, data[3].z, data[3].w};
267
268 // Convert SRT into a matrix
269 optixGetMatrixFromSrt( trf0, trf1, trf2, srt );
270}
271
272// Returns the interpolated transformation matrix for a particular traversable handle and point in time.
273static __forceinline__ __device__ void optixGetInterpolatedTransformationFromHandle( float4& trf0,
274 float4& trf1,
275 float4& trf2,
276 const OptixTraversableHandle handle,
277 const float time,
278 const bool objectToWorld )
279{
281
283 {
285 {
287 optixGetInterpolatedTransformation( trf0, trf1, trf2, transformData, time );
288 }
289 else
290 {
291 const OptixSRTMotionTransform* transformData = optixGetSRTMotionTransformFromHandle( handle );
292 optixGetInterpolatedTransformation( trf0, trf1, trf2, transformData, time );
293 }
294
295 if( !objectToWorld )
296 optixInvertMatrix( trf0, trf1, trf2 );
297 }
299 {
300 const float4* transform;
301
303 {
304 transform = ( objectToWorld ) ? optixGetInstanceTransformFromHandle( handle ) :
306 }
307 else
308 {
309 const OptixStaticTransform* traversable = optixGetStaticTransformFromHandle( handle );
310 transform = (const float4*)( ( objectToWorld ) ? traversable->transform : traversable->invTransform );
311 }
312
313 trf0 = optixLoadReadOnlyAlign16( &transform[0] );
314 trf1 = optixLoadReadOnlyAlign16( &transform[1] );
315 trf2 = optixLoadReadOnlyAlign16( &transform[2] );
316 }
317 else
318 {
319 trf0 = {1.0f, 0.0f, 0.0f, 0.0f};
320 trf1 = {0.0f, 1.0f, 0.0f, 0.0f};
321 trf2 = {0.0f, 0.0f, 1.0f, 0.0f};
322 }
323}
324
325// Returns the world-to-object transformation matrix resulting from the current transform stack and current ray time.
326static __forceinline__ __device__ void optixGetWorldToObjectTransformMatrix( float4& m0, float4& m1, float4& m2 )
327{
328 const unsigned int size = optixGetTransformListSize();
329 const float time = optixGetRayTime();
330
331#pragma unroll 1
332 for( unsigned int i = 0; i < size; ++i )
333 {
335
336 float4 trf0, trf1, trf2;
337 optixGetInterpolatedTransformationFromHandle( trf0, trf1, trf2, handle, time, /*objectToWorld*/ false );
338
339 if( i == 0 )
340 {
341 m0 = trf0;
342 m1 = trf1;
343 m2 = trf2;
344 }
345 else
346 {
347 // m := trf * m
348 float4 tmp0 = m0, tmp1 = m1, tmp2 = m2;
349 m0 = optixMultiplyRowMatrix( trf0, tmp0, tmp1, tmp2 );
350 m1 = optixMultiplyRowMatrix( trf1, tmp0, tmp1, tmp2 );
351 m2 = optixMultiplyRowMatrix( trf2, tmp0, tmp1, tmp2 );
352 }
353 }
354}
355
356// Returns the object-to-world transformation matrix resulting from the current transform stack and current ray time.
357static __forceinline__ __device__ void optixGetObjectToWorldTransformMatrix( float4& m0, float4& m1, float4& m2 )
358{
359 const int size = optixGetTransformListSize();
360 const float time = optixGetRayTime();
361
362#pragma unroll 1
363 for( int i = size - 1; i >= 0; --i )
364 {
366
367 float4 trf0, trf1, trf2;
368 optixGetInterpolatedTransformationFromHandle( trf0, trf1, trf2, handle, time, /*objectToWorld*/ true );
369
370 if( i == size - 1 )
371 {
372 m0 = trf0;
373 m1 = trf1;
374 m2 = trf2;
375 }
376 else
377 {
378 // m := trf * m
379 float4 tmp0 = m0, tmp1 = m1, tmp2 = m2;
380 m0 = optixMultiplyRowMatrix( trf0, tmp0, tmp1, tmp2 );
381 m1 = optixMultiplyRowMatrix( trf1, tmp0, tmp1, tmp2 );
382 m2 = optixMultiplyRowMatrix( trf2, tmp0, tmp1, tmp2 );
383 }
384 }
385}
386
387// Multiplies the 3x4 matrix with rows m0, m1, m2 with the point p.
388static __forceinline__ __device__ float3 optixTransformPoint( const float4& m0, const float4& m1, const float4& m2, const float3& p )
389{
390 float3 result;
391 result.x = m0.x * p.x + m0.y * p.y + m0.z * p.z + m0.w;
392 result.y = m1.x * p.x + m1.y * p.y + m1.z * p.z + m1.w;
393 result.z = m2.x * p.x + m2.y * p.y + m2.z * p.z + m2.w;
394 return result;
395}
396
397// Multiplies the 3x3 linear submatrix of the 3x4 matrix with rows m0, m1, m2 with the vector v.
398static __forceinline__ __device__ float3 optixTransformVector( const float4& m0, const float4& m1, const float4& m2, const float3& v )
399{
400 float3 result;
401 result.x = m0.x * v.x + m0.y * v.y + m0.z * v.z;
402 result.y = m1.x * v.x + m1.y * v.y + m1.z * v.z;
403 result.z = m2.x * v.x + m2.y * v.y + m2.z * v.z;
404 return result;
405}
406
407// Multiplies the transpose of the 3x3 linear submatrix of the 3x4 matrix with rows m0, m1, m2 with the normal n.
408// Note that the given matrix is supposed to be the inverse of the actual transformation matrix.
409static __forceinline__ __device__ float3 optixTransformNormal( const float4& m0, const float4& m1, const float4& m2, const float3& n )
410{
411 float3 result;
412 result.x = m0.x * n.x + m1.x * n.y + m2.x * n.z;
413 result.y = m0.y * n.x + m1.y * n.y + m2.y * n.z;
414 result.z = m0.z * n.x + m1.z * n.y + m2.z * n.z;
415 return result;
416}
417
418} // namespace optix_impl
419
420#endif // OPTIX_OPTIX_DEVICE_IMPL_TRANSFORMATIONS_H
OptixTransformType
Transform.
Definition: optix_types.h:1850
unsigned long long OptixTraversableHandle
Traversable handle.
Definition: optix_types.h:68
@ OPTIX_TRANSFORM_TYPE_SRT_MOTION_TRANSFORM
Definition: optix_types.h:1854
@ OPTIX_TRANSFORM_TYPE_STATIC_TRANSFORM
Definition: optix_types.h:1852
@ OPTIX_TRANSFORM_TYPE_INSTANCE
Definition: optix_types.h:1855
@ OPTIX_TRANSFORM_TYPE_MATRIX_MOTION_TRANSFORM
Definition: optix_types.h:1853
Definition: optix_device_impl_transformations.h:27
static __forceinline__ __device__ void optixGetMatrixFromSrt(float4 &m0, float4 &m1, float4 &m2, const OptixSRTData &srt)
Definition: optix_device_impl_transformations.h:75
static __forceinline__ __device__ void optixResolveMotionKey(float &localt, int &key, const OptixMotionOptions &options, const float globalt)
Definition: optix_device_impl_transformations.h:205
static __forceinline__ __device__ float4 optixAddFloat4(const float4 &a, const float4 &b)
Definition: optix_device_impl_transformations.h:29
static __forceinline__ __device__ float4 optixMulFloat4(const float4 &a, float b)
Definition: optix_device_impl_transformations.h:34
static __forceinline__ __device__ T optixLoadReadOnlyAlign16(const T *ptr)
Definition: optix_device_impl_transformations.h:51
static __forceinline__ __device__ void optixLoadInterpolatedMatrixKey(float4 &m0, float4 &m1, float4 &m2, const float4 *matrix, const float t1)
Definition: optix_device_impl_transformations.h:160
static __forceinline__ __device__ void optixGetObjectToWorldTransformMatrix(float4 &m0, float4 &m1, float4 &m2)
Definition: optix_device_impl_transformations.h:357
static __forceinline__ __device__ float3 optixTransformPoint(const float4 &m0, const float4 &m1, const float4 &m2, const float3 &p)
Definition: optix_device_impl_transformations.h:388
static __forceinline__ __device__ void optixInvertMatrix(float4 &m0, float4 &m1, float4 &m2)
Definition: optix_device_impl_transformations.h:122
static __forceinline__ __device__ float3 optixTransformVector(const float4 &m0, const float4 &m1, const float4 &m2, const float3 &v)
Definition: optix_device_impl_transformations.h:398
static __forceinline__ __device__ void optixLoadInterpolatedSrtKey(float4 &srt0, float4 &srt1, float4 &srt2, float4 &srt3, const float4 *srt, const float t1)
Definition: optix_device_impl_transformations.h:176
static __forceinline__ __device__ float3 optixTransformNormal(const float4 &m0, const float4 &m1, const float4 &m2, const float3 &n)
Definition: optix_device_impl_transformations.h:409
static __forceinline__ __device__ uint4 optixLdg(unsigned long long addr)
Definition: optix_device_impl_transformations.h:39
static __forceinline__ __device__ float4 optixMultiplyRowMatrix(const float4 vec, const float4 m0, const float4 m1, const float4 m2)
Definition: optix_device_impl_transformations.h:62
static __forceinline__ __device__ void optixGetInterpolatedTransformationFromHandle(float4 &trf0, float4 &trf1, float4 &trf2, const OptixTraversableHandle handle, const float time, const bool objectToWorld)
Definition: optix_device_impl_transformations.h:273
static __forceinline__ __device__ void optixGetInterpolatedTransformation(float4 &trf0, float4 &trf1, float4 &trf2, const OptixMatrixMotionTransform *transformData, const float time)
Definition: optix_device_impl_transformations.h:228
static __forceinline__ __device__ void optixGetWorldToObjectTransformMatrix(float4 &m0, float4 &m1, float4 &m2)
Definition: optix_device_impl_transformations.h:326
static __forceinline__ __device__ const OptixStaticTransform * optixGetStaticTransformFromHandle(OptixTraversableHandle handle)
Definition: optix_device_impl.h:1651
static __forceinline__ __device__ const OptixMatrixMotionTransform * optixGetMatrixMotionTransformFromHandle(OptixTraversableHandle handle)
Definition: optix_device_impl.h:1665
static __forceinline__ __device__ OptixTraversableHandle optixGetTransformListHandle(unsigned int index)
Definition: optix_device_impl.h:1637
static __forceinline__ __device__ const float4 * optixGetInstanceTransformFromHandle(OptixTraversableHandle handle)
Definition: optix_device_impl.h:1686
static __forceinline__ __device__ unsigned int optixGetTransformListSize()
Definition: optix_device_impl.h:1630
static __forceinline__ __device__ const OptixSRTMotionTransform * optixGetSRTMotionTransformFromHandle(OptixTraversableHandle handle)
Definition: optix_device_impl.h:1658
static __forceinline__ __device__ float optixGetRayTime()
Definition: optix_device_impl.h:1289
static __forceinline__ __device__ OptixTransformType optixGetTransformTypeFromHandle(OptixTraversableHandle handle)
Definition: optix_device_impl.h:1644
static __forceinline__ __device__ const float4 * optixGetInstanceInverseTransformFromHandle(OptixTraversableHandle handle)
Definition: optix_device_impl.h:1693
Represents a matrix motion transformation.
Definition: optix_types.h:1448
float transform[2][12]
Affine object-to-world transformation as 3x4 matrix in row-major layout.
Definition: optix_types.h:1460
Motion options.
Definition: optix_types.h:1311
unsigned short numKeys
If numKeys > 1, motion is enabled. timeBegin, timeEnd and flags are all ignored when motion is disabl...
Definition: optix_types.h:1314
float timeBegin
Point in time where motion starts. Must be lesser than timeEnd.
Definition: optix_types.h:1320
float timeEnd
Point in time where motion ends. Must be greater than timeBegin.
Definition: optix_types.h:1323
Represents an SRT transformation.
Definition: optix_types.h:1494
float qz
Definition: optix_types.h:1497
float b
Definition: optix_types.h:1497
float tz
Definition: optix_types.h:1497
float qx
Definition: optix_types.h:1497
float sz
Definition: optix_types.h:1497
float c
Definition: optix_types.h:1497
float sy
Definition: optix_types.h:1497
float pvz
Definition: optix_types.h:1497
float qw
Definition: optix_types.h:1497
float ty
Definition: optix_types.h:1497
float pvy
Definition: optix_types.h:1497
float pvx
Definition: optix_types.h:1497
float sx
Definition: optix_types.h:1497
float a
Definition: optix_types.h:1497
float qy
Definition: optix_types.h:1497
float tx
Definition: optix_types.h:1497
Represents an SRT motion transformation.
Definition: optix_types.h:1531
OptixSRTData srtData[2]
The actual SRT data describing the transformation.
Definition: optix_types.h:1543
Static transform.
Definition: optix_types.h:1408
float invTransform[12]
Affine world-to-object transformation as 3x4 matrix in row-major layout Must be the inverse of the tr...
Definition: optix_types.h:1420
float transform[12]
Affine object-to-world transformation as 3x4 matrix in row-major layout.
Definition: optix_types.h:1416