Attributes are a part of the scene description that provide a common mechanism for parameterized information used in processing. More...
#include <iattribute.h>
Inherits mi::base::Interface_declare< 0xfb32338f, ... >.
Public Member Functions | |
virtual mi::base::Uuid | get_attribute_class () const =0 |
Represents the category or the attribute class that a concrete attribute implements. More... | |
virtual bool | multiple_active_instances () const =0 |
The attributes that implement a category or an attribute class are evaluated in exclusive or integrative fashion (for example, multiple light source affect the shading of surfaces while only one material defines the surface's reflectance properties). More... | |
Attributes are a part of the scene description that provide a common mechanism for parameterized information used in processing.
Attributes define the rendered appearance of shapes and large-scale datasets and can be used to store meta-information in the scene description for later evaluation. Attributes can therefore affect both the rendering as well as the processing and evaluation of data.
The abstract base class IAttribute
represents attributes that can be structured in a scene description. Common attributes include, for example, material properties, light sources, and the fonts used to display the contents of a label.
Once specified in a scene description, attributes affect the rendering of those shapes in the scene that are hierarchically below them in the scene description. (For details on structuring a scene please also refer to IScene_group
.)
Generally, the NVIDIA IndeX library considers two different evaluation strategies for attributes:
|
pure virtual |
Represents the category or the attribute class that a concrete attribute implements.
For instance, a directional light implements the ILight
category and a simple OpenGL-like Phong material implements the IMaterial
category. A category enables the implementation of specialized attributes for certain classes and can thereby extend the number of variants for that category. The evaluation strategies for attribute classes are determined by the category. For example, point lights, directional lights (IDirectional_light
) and directional head lights (IDirectional_headlight
) implement the ILight
category and can all be active at a time. In contrast, a Cook-Torrance surface material and an OpenGL-like Phong material implement the IMaterial
category but only one instance of the material attributes is active when shading a shapes surface.
|
pure virtual |
The attributes that implement a category or an attribute class are evaluated in exclusive or integrative fashion (for example, multiple light source affect the shading of surfaces while only one material defines the surface's reflectance properties).
To control the attribute evaluation, an attribute class (that defines a category for derived attributes) must define whether one or multiple instances of the attribute can be active at the same time when evaluating a shape or dataset.
true
if multiple instances of an attribute that influences a shape's appearance may be active simultaneously. Returns false
if only one attribute can be active at a time.