H3D API  2.4.1
Background.h
Go to the documentation of this file.
1 // Copyright 2004-2019, SenseGraphics AB
3 //
4 // This file is part of H3D API.
5 //
6 // H3D API is free software; you can redistribute it and/or modify
7 // it under the terms of the GNU General Public License as published by
8 // the Free Software Foundation; either version 2 of the License, or
9 // (at your option) any later version.
10 //
11 // H3D API is distributed in the hope that it will be useful,
12 // but WITHOUT ANY WARRANTY; without even the implied warranty of
13 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 // GNU General Public License for more details.
15 //
16 // You should have received a copy of the GNU General Public License
17 // along with H3D API; if not, write to the Free Software
18 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 //
20 // A commercial license is also available. Please contact us at
21 // www.sensegraphics.com for more information.
22 //
23 //
27 //
29 #ifndef __BACKGROUND_H__
30 #define __BACKGROUND_H__
31 
32 #include <H3D/X3DBackgroundNode.h>
33 #include <H3D/ImageTexture.h>
34 
35 namespace H3D {
36 
80  class H3DAPI_API Background :
81  public X3DBackgroundNode {
82  public:
83 
85  Background( Inst< SFSetBind > _set_bind = 0,
86  Inst< SFNode > _metadata = 0,
87  Inst< SFTime > _bindTime = 0,
88  Inst< SFBool > _isBound = 0,
89  Inst< DisplayList > _displayList = 0,
90  Inst< MFFloat > _groundAngle = 0,
91  Inst< MFColor > _groundColor = 0,
92  Inst< MFFloat > _skyAngle = 0,
93  Inst< MFColor > _skyColor = 0,
94  Inst< MFString > _backUrl = 0,
95  Inst< MFString > _frontUrl = 0,
96  Inst< MFString > _leftUrl = 0,
97  Inst< MFString > _rightUrl = 0,
98  Inst< MFString > _topUrl = 0,
99  Inst< MFString > _bottomUrl = 0,
100  Inst< SFFloat > _transparency = 0 );
101 
103  virtual void render();
104 
110  H3DUniquePtr< MFString > backUrl;
111 
117  H3DUniquePtr< MFString > frontUrl;
118 
124  H3DUniquePtr< MFString > leftUrl;
125 
131  H3DUniquePtr< MFString > rightUrl;
132 
138  H3DUniquePtr< MFString > topUrl;
139 
145  H3DUniquePtr< MFString > bottomUrl;
146 
149  protected:
162  };
163 }
164 
165 #endif
Header file for ImageTexture, X3D scene-graph node.
Header file for X3DBackgroundNode, X3D scene-graph node.
A background node that uses six static images to compose the backdrop.
Definition: Background.h:81
static H3DNodeDatabase database
The H3DNodeDatabase for this node.
Definition: Background.h:148
AutoRef< ImageTexture > leftTexture
The texture displayed to the left.
Definition: Background.h:155
H3DUniquePtr< MFString > backUrl
The url of the texture to use on the back face of the cube.
Definition: Background.h:110
AutoRef< ImageTexture > backTexture
The texture displayed at the back.
Definition: Background.h:151
H3DUniquePtr< MFString > frontUrl
The url of the texture to use on the front face of the cube.
Definition: Background.h:117
H3DUniquePtr< MFString > bottomUrl
The url of the texture to use on the bottom face of the cube.
Definition: Background.h:145
AutoRef< ImageTexture > topTexture
The texture displayed at the top.
Definition: Background.h:159
H3DUniquePtr< MFString > topUrl
The url of the texture to use on the top face of the cube.
Definition: Background.h:138
AutoRef< ImageTexture > bottomTexture
The texture displayed at the bottom.
Definition: Background.h:161
H3DUniquePtr< MFString > leftUrl
The url of the texture to use on the left face of the cube.
Definition: Background.h:124
AutoRef< ImageTexture > frontTexture
The texture displayed at the front.
Definition: Background.h:153
AutoRef< ImageTexture > rightTexture
The texture displayed to the right.
Definition: Background.h:157
H3DUniquePtr< MFString > rightUrl
The url of the texture to use on the right face of the cube.
Definition: Background.h:131
X3DBackgroundNode is the abstract type from which all backgrounds inherit.
Definition: X3DBackgroundNode.h:126
H3D API namespace.
Definition: Anchor.h:38
The H3DNodeDatabase contains a mapping between a name of a Node and the constructor for the Node with...
Definition: H3DNodeDatabase.h:194