HDK
Main Page
Related Pages
Modules
Namespaces
Classes
Files
Examples
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
TS_Ray.h
Go to the documentation of this file.
1
/*
2
* PROPRIETARY INFORMATION. This software is proprietary to
3
* Side Effects Software Inc., and is not to be reproduced,
4
* transmitted, or disclosed in any way without written permission.
5
*
6
* NAME: TS_Ray (C++)
7
*
8
* COMMENTS:
9
*
10
*/
11
12
#ifndef _TS_Ray_h_
13
#define _TS_Ray_h_
14
15
#include "
TS_API.h
"
16
#include <
UT/UT_Vector3.h
>
17
#include <
UT/UT_Interval.h
>
18
#include <
UT/UT_BoundingBox.h
>
19
#include <
UT/UT_ThreadSpecificValue.h
>
20
21
class
TS_API
TS_Ray
22
{
23
public
:
24
inline
TS_Ray
(
const
UT_Vector3
&xdir,
const
UT_Vector3
&xanchor,
25
int
thread_num = -1);
26
int
rayBoxHit(
const
UT_BoundingBox
&box,
UT_Interval
&
t
)
const
;
27
28
// Sets up multiple ray counts for use by seperate threads
29
static
void
setupThreads(
int
num_threads);
30
public
:
31
UT_Vector3
dir
;
32
UT_Vector3
anchor
;
33
int
index
;
34
static
UT_ThreadSpecificValue<int>
ourRaySerial
;
35
};
36
37
inline
TS_Ray::TS_Ray
(
const
UT_Vector3
&pdir,
const
UT_Vector3
&panchor,
38
int
thread_num)
39
{
40
this->
dir
= pdir; this->
anchor
= panchor;
41
42
index
=
ourRaySerial
.
get
()+1;
43
ourRaySerial
.
get
() =
index
;
44
}
45
46
#endif
UT_BoundingBoxT< float >
UT_ThreadSpecificValue::get
T & get()
Definition:
UT_ThreadSpecificValue.h:245
UT_Vector3.h
TS_Ray::TS_Ray
TS_Ray(const UT_Vector3 &xdir, const UT_Vector3 &xanchor, int thread_num=-1)
Definition:
TS_Ray.h:37
TS_Ray::dir
UT_Vector3 dir
Definition:
TS_Ray.h:31
UT_Vector3T< float >
TS_API.h
TS_Ray::ourRaySerial
static UT_ThreadSpecificValue< int > ourRaySerial
Definition:
TS_Ray.h:34
TS_Ray
Definition:
TS_Ray.h:21
TS_Ray::index
int index
Definition:
TS_Ray.h:33
UT_ThreadSpecificValue.h
TS_Ray::anchor
UT_Vector3 anchor
Definition:
TS_Ray.h:32
t
GLdouble t
Definition:
glad.h:2397
TS_API
#define TS_API
Definition:
api.h:41
index
GLuint index
Definition:
glcorearb.h:786
UT_Interval.h
UT_BoundingBox.h
UT_IntervalT< float >
UT_ThreadSpecificValue< int >
TS
TS_Ray.h
Generated on Sat Dec 21 2024 02:48:57 for HDK by
1.8.6