RenderMan
26.0
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
RixShaderInfo.h
Go to the documentation of this file.
1
/*
2
# ------------------------------------------------------------------------------
3
#
4
# Copyright (c) 2020 Pixar. All rights reserved.
5
#
6
# The information in this file (the "Software") is provided for the exclusive
7
# use of the software licensees of Pixar ("Licensees"). Licensees have the
8
# right to incorporate the Software into other products for use by other
9
# authorized software licensees of Pixar, without fee. Except as expressly
10
# permitted herein, the Software may not be disclosed to third parties, copied
11
# or duplicated in any form, in whole or in part, without the prior written
12
# permission of Pixar.
13
#
14
# The copyright notices in the Software and this entire statement, including the
15
# above license grant, this restriction and the following disclaimer, must be
16
# included in all copies of the Software, in whole or in part, and all permitted
17
# derivative works of the Software, unless such copies or derivative works are
18
# solely in the form of machine-executable object code generated by a source
19
# language processor.
20
#
21
# PIXAR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING ALL
22
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL PIXAR BE
23
# LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
24
# WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION
25
# OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
26
# CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. IN NO CASE WILL
27
# PIXAR'S TOTAL LIABILITY FOR ALL DAMAGES ARISING OUT OF OR IN CONNECTION WITH
28
# THE USE OR PERFORMANCE OF THIS SOFTWARE EXCEED $50.
29
#
30
# Pixar
31
# 1200 Park Ave
32
# Emeryville CA 94608
33
#
34
# ------------------------------------------------------------------------------
35
*/
36
37
#ifndef _RixShaderQuery_h
38
#define _RixShaderQuery_h
39
40
#include "
RixInterfaces.h
"
41
45
class
RixShaderParameter
{
46
47
public
:
48
50
enum
RixShaderParameterType
51
{
52
k_Int
,
53
k_Float
,
54
k_String
,
55
k_Color
,
56
k_Point
,
57
k_Normal
,
58
k_Vector
,
59
k_Matrix
,
60
k_Unknown
61
};
62
64
enum
RixShaderBaseType
{
65
k_UNKNOWN
,
k_NONE
,
66
k_UCHAR
,
k_UINT8
=
k_UCHAR
,
k_CHAR
,
k_INT8
=
k_CHAR
,
67
k_USHORT
,
k_UINT16
=
k_USHORT
,
k_SHORT
,
k_INT16
=
k_SHORT
,
68
k_UINT
,
k_UINT32
=
k_UINT
,
k_INT
,
k_INT32
=
k_INT
,
69
k_ULONGLONG
,
k_UINT64
=
k_ULONGLONG
,
k_LONGLONG
,
k_INT64
=
k_LONGLONG
,
70
k_HALF
,
k_FLOAT
,
k_DOUBLE
,
k_STRING
,
k_PTR
,
k_LASTBASE
71
};
72
74
enum
RixShaderAggregateType
75
{
76
k_Scalar
,
77
k_Vec2
,
78
k_Vec3
,
79
k_Vec4
,
80
k_Matrix33
,
81
k_Matrix44
82
};
83
85
enum
RixShaderVectorSemantics
86
{
87
k_VSColor
,
88
k_VSPoint
,
89
k_VSVector
,
90
k_VSNormal
91
};
92
93
public
:
94
95
virtual
~RixShaderParameter
() {};
96
98
virtual
const
char
*
99
Name
(
void
)
const
= 0;
100
102
virtual
const
char
*
103
StructName
(
void
)
const
= 0;
104
106
virtual
RixShaderParameterType
107
Type
(
void
)
const
= 0;
108
110
virtual
RixShaderBaseType
111
BaseType
(
void
)
const
= 0;
112
114
virtual
RixShaderAggregateType
115
AggregateType
(
void
)
const
= 0;
116
118
virtual
RixShaderVectorSemantics
119
VectorSemantics
(
void
)
const
= 0;
120
122
virtual
bool
123
IsOutput
(
void
)
const
= 0;
124
126
virtual
bool
127
IsStruct
(
void
)
const
= 0;
128
130
virtual
bool
131
IsArray
(
void
)
const
= 0;
132
134
virtual
int
135
ArrayLength
(
void
)
const
= 0;
136
138
virtual
int
139
DefaultSize
(
void
)
const
= 0;
140
142
virtual
const
int
*
143
DefaultI
(
void
)
const
= 0;
144
146
virtual
const
float
*
147
DefaultF
(
void
)
const
= 0;
148
150
virtual
const
char
**
151
DefaultS
(
void
)
const
= 0;
152
155
virtual
int
156
MetaDataSize
(
void
)
const
= 0;
157
163
virtual
const
RixShaderParameter
*
const
*
164
MetaData
(
void
)
const
= 0;
165
166
};
167
172
class
RixShaderQuery
{
173
174
public
:
175
176
virtual
~RixShaderQuery
(
void
) {};
177
188
virtual
bool
189
Open
(
const
char
* name,
const
char
* searchPath) = 0;
190
192
virtual
const
char
*
193
LastError
(
void
) = 0;
194
197
virtual
int
198
ParameterCount
(
void
)
const
= 0;
199
207
virtual
const
RixShaderParameter
*
const
*
208
Parameters
(
void
)
const
= 0;
209
212
virtual
int
213
MetaDataCount
(
void
)
const
= 0;
214
222
virtual
const
RixShaderParameter
*
const
*
223
MetaData
(
void
)
const
= 0;
224
226
virtual
const
char
*
227
ShaderName
(
void
)
const
= 0;
228
230
virtual
const
char
*
231
ShaderType
(
void
)
const
= 0;
232
};
233
246
class
RixShaderInfo
:
public
RixInterface
{
247
public
:
248
251
virtual
RixShaderQuery
*
252
CreateQuery
(
void
) = 0;
253
254
protected
:
255
256
RixShaderInfo
() :
RixInterface
(1) {}
257
258
};
259
#endif
RixShaderInfo.h
Generated on Fri Apr 5 2024 12:32:49 for RenderMan by
Doxygen
1.8.4
© Pixar. All Rights Reserved.