OSG  3.4.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
ClearNode.h
Go to the documentation of this file.
1 /* -*-c++-*- OpenSceneGraph - Copyright (C) 1998-2006 Robert Osfield
2  *
3  * This library is open source and may be redistributed and/or modified under
4  * the terms of the OpenSceneGraph Public License (OSGPL) version 0.0 or
5  * (at your option) any later version. The full license is in LICENSE file
6  * included with this distribution, and on the openscenegraph.org website.
7  *
8  * This library is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11  * OpenSceneGraph Public License for more details.
12 */
13 
14 #ifndef OSG_CLEARNODE
15 #define OSG_CLEARNODE 1
16 
17 #include <osg/Group>
18 #include <osg/Vec4>
19 
20 namespace osg {
21 
30 class OSG_EXPORT ClearNode : public Group
31 {
32  public :
33 
34  ClearNode();
35 
36  ClearNode(const ClearNode& cs, const CopyOp& copyop=CopyOp::SHALLOW_COPY):
37  Group(cs,copyop),
38  _requiresClear(cs._requiresClear),
39  _clearColor(cs._clearColor),
40  _clearMask(cs._clearMask) {}
41 
42 
44 
46  inline void setRequiresClear(bool requiresClear) { _requiresClear = requiresClear; }
47 
49  inline bool getRequiresClear() const { return _requiresClear; }
50 
52  inline void setClearColor(const Vec4& color) { _clearColor = color; }
53 
55  inline const Vec4& getClearColor() const { return _clearColor; }
56 
59  inline void setClearMask(GLbitfield mask) { _clearMask = mask; }
60 
62  inline GLbitfield getClearMask() const { return _clearMask; }
63 
64  protected :
65 
66  virtual ~ClearNode() {}
67 
70  GLbitfield _clearMask;
71 };
72 
73 }
74 
75 #endif
void setRequiresClear(bool requiresClear)
Definition: ClearNode.h:46
#define OSG_EXPORT
Definition: Export.h:43
ClearNode(const ClearNode &cs, const CopyOp &copyop=CopyOp::SHALLOW_COPY)
Definition: ClearNode.h:36
#define META_Node(library, name)
Definition: Node.h:59
void setClearMask(GLbitfield mask)
Definition: ClearNode.h:59
virtual ~ClearNode()
Definition: ClearNode.h:66
bool getRequiresClear() const
Definition: ClearNode.h:49
GLbitfield _clearMask
Definition: ClearNode.h:70
bool _requiresClear
Definition: ClearNode.h:68
Definition: AlphaFunc.h:19
const Vec4 & getClearColor() const
Definition: ClearNode.h:55
Vec4 _clearColor
Definition: ClearNode.h:69
GLbitfield getClearMask() const
Definition: ClearNode.h:62
void setClearColor(const Vec4 &color)
Definition: ClearNode.h:52