MeVisLab Toolbox Reference
Loading...
Searching...
No Matches
SoShaderObjectElement.h
Go to the documentation of this file.
1/*************************************************************************************
2**
3** Copyright 2007, MeVis Medical Solutions AG
4**
5** The user may use this file in accordance with the license agreement provided with
6** the Software or, alternatively, in accordance with the terms contained in a
7** written agreement between the user and MeVis Medical Solutions AG.
8**
9** For further information use the contact form at https://www.mevislab.de/contact
10**
11**************************************************************************************/
12
13#ifndef SO_SHADER_OBJECT_ELEMENT_H
14#define SO_SHADER_OBJECT_ELEMENT_H
15
16
18
19#include "SoShaderSystem.h"
20#include <Inventor/elements/SoAccumulatedElement.h>
21#include <Inventor/SoLists.h>
22
23class SoShaderObject;
24
26class INVENTOR_SHADER_API SoShaderObjectElement : public SoAccumulatedElement
27{
28 typedef SoAccumulatedElement inherited;
29
30 SO_ELEMENT_HEADER(SoShaderObjectElement);
31
32public:
34 void init(SoState* state) override;
35
37 static void add(SoState* state, SoShaderObject* shader);
38
40 static const SoNodeList& get(SoState* state);
41
43 static void clear(SoState* state, SoNode* node);
44
46 void push(SoState* state) override;
47
49
51 static void initClass();
52
53protected:
56};
57
58#endif // _SO_SHADER_OBJECT_ELEMENT_
Open Inventor element storing a list of vertex or fragment shader nodes in the Open Inventor state.
static const SoNodeList & get(SoState *state)
Returns the current list of shader objects from the state.
void init(SoState *state) override
Initialize element.
SoNodeList _shaders
List of vertex or fragment shader nodes.
static void initClass()
Initialize class with runtime type system.
void push(SoState *state) override
Overrides push() method to copy values from next instance in the stack.
static void add(SoState *state, SoShaderObject *shader)
Add to the current shader object list.
static void clear(SoState *state, SoNode *node)
Clear list.
Abstract Open Inventor node for vertex or fragment shader nodes.
Target mlrange_cast(Source arg)
Generic version of checked ML casts.