NVIDIA Iray API
Home
Up
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Groups
Pages
imdl_function_call.h
Go to the documentation of this file.
1
//*****************************************************************************
2
// Copyright 1986, 2016 NVIDIA Corporation. All rights reserved.
3
//*****************************************************************************
6
//*****************************************************************************
7
8
#ifndef MI_NEURAYLIB_IMDL_FUNCTION_CALL_H
9
#define MI_NEURAYLIB_IMDL_FUNCTION_CALL_H
10
11
#include <
mi/neuraylib/iattachable.h
>
12
#include <
mi/neuraylib/iscene_element.h
>
13
#include <
mi/neuraylib/version.h
>
14
15
namespace
mi {
16
17
namespace
neuraylib {
18
23
class
IAttribute_container;
24
33
class
IMdl_function_call
:
public
34
mi::base::Interface_declare
<0x308bcfb7,0x6abc,0x44cd,0xb2,0xdc,0x0c,0x88,0x44,0x0f,0x9e,0x32,
35
neuraylib::IScene_element>
36
{
37
public
:
43
virtual
const
char
*
get_function_definition
()
const
= 0;
44
52
virtual
const
char
*
get_name
()
const
= 0;
53
57
virtual
const
char
*
get_return_type
()
const
= 0;
58
62
virtual
bool
is_return_type_varying
()
const
= 0;
63
67
virtual
Uint32
get_parameter_count
()
const
= 0;
68
73
virtual
const
char
*
get_parameter_name
(
Uint32
index)
const
= 0;
74
79
virtual
Sint32
get_parameter_index
(
const
char
* name)
const
= 0;
80
88
virtual
const
char
*
get_parameter_type
(
Uint32
index)
const
= 0;
89
94
virtual
const
char
*
get_parameter_type
(
const
char
* name)
const
= 0;
95
101
virtual
bool
is_parameter_type_uniform
(
Uint32
index)
const
= 0;
102
108
virtual
bool
is_parameter_type_uniform
(
const
char
* name)
const
= 0;
109
121
virtual
const
char
*
get_argument_type
(
Uint32
index)
const
= 0;
122
131
virtual
const
char
*
get_argument_type
(
const
char
* name)
const
= 0;
132
143
virtual
const
IAttachable
*
get_argument
(
Uint32
index)
const
= 0;
144
162
template
<
class
T>
163
const
T*
get_argument
(
Uint32
index)
const
164
{
165
const
IAttachable
* ptr_idata =
get_argument
( index);
166
if
( !ptr_idata)
167
return
0;
168
const
T* ptr_T =
static_cast<
const
T*
>
( ptr_idata->
get_interface
(
typename
T::IID()));
169
ptr_idata->
release
();
170
return
ptr_T;
171
}
172
180
virtual
const
IAttachable
*
get_argument
(
const
char
* name)
const
= 0;
181
196
template
<
class
T>
197
const
T*
get_argument
(
const
char
* name)
const
198
{
199
const
IAttachable
* ptr_idata =
get_argument
( name);
200
if
( !ptr_idata)
201
return
0;
202
const
T* ptr_T =
static_cast<
const
T*
>
( ptr_idata->
get_interface
(
typename
T::IID()));
203
ptr_idata->
release
();
204
return
ptr_T;
205
}
206
222
virtual
Sint32
set_argument
(
Uint32
index,
const
IAttachable
* value) = 0;
223
239
virtual
Sint32
set_argument
(
const
char
* name,
const
IAttachable
* value) = 0;
240
244
virtual
const
IAttribute_container
*
access_arguments
()
const
= 0;
245
260
virtual
Sint32
set_arguments
(
const
IAttribute_container
* arguments) = 0;
261
};
262
// end group mi_neuray_materials
264
265
}
// namespace neuraylib
266
267
#ifdef MI_NEURAYLIB_DEPRECATED_NAMESPACE_MI_TRANSITION
268
using
neuraylib::IAttribute_container;
269
using
neuraylib::IMdl_function_call;
270
using
neuraylib::IScene_element;
271
#endif // MI_NEURAYLIB_DEPRECATED_NAMESPACE_MI_TRANSITION
272
273
}
// namespace mi
274
275
#endif // MI_NEURAYLIB_IMDL_FUNCTION_CALL
mi
neuraylib
imdl_function_call.h
Generated on Fri Mar 4 2016 19:53:39. Build 250909.11169, Doxygen 1.8.4