scg3  0.6
StandardRenderer.h
Go to the documentation of this file.
1 
10 /*
11  * Copyright 2014 Volker Ahlers
12  *
13  * Licensed under the Apache License, Version 2.0 (the "License");
14  * you may not use this file except in compliance with the License.
15  * You may obtain a copy of the License at
16  *
17  * http://www.apache.org/licenses/LICENSE-2.0
18  *
19  * Unless required by applicable law or agreed to in writing, software
20  * distributed under the License is distributed on an "AS IS" BASIS,
21  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
22  * See the License for the specific language governing permissions and
23  * limitations under the License.
24  */
25 
26 #ifndef STANDARDRENDERER_H_
27 #define STANDARDRENDERER_H_
28 
29 #include "Renderer.h"
30 #include "scg_internals.h"
31 
32 namespace scg {
33 
34 
42 class StandardRenderer: public Renderer {
43 
44 public:
45 
50 
54  virtual ~StandardRenderer();
55 
59  static StandardRendererSP create();
60 
69  virtual void initViewer(Viewer* viewer, FrameBufferSize* frameBufferSize);
70 
74  virtual std::string getInfo();
75 
79  virtual void render();
80 
81 protected:
82 
86 
87 };
88 
89 
90 } /* namespace scg */
91 
92 #endif /* STANDARDRENDERER_H_ */
A standard renderer that uses a PreTraverser, a RenderTraverser, and an InfoTraverser.
Base class for all renderers (abstract).
virtual void render()
Central viewer managing window, controllers, animations, and main loop.
Definition: Viewer.h:108
InfoTraverserUP infoTraverser_
A traverser that renders the scene graph (visitor pattern).
static StandardRendererSP create()
PreTraverserUP preTraverser_
A traverser that gathers information about the scene graph (visitor pattern).
Definition: InfoTraverser.h:37
Frame buffer size, to be set by renderer in Renderer::initViewer(), called by Viewer::init().
Definition: Viewer.h:90
RenderTraverserUP renderTraverser_
virtual std::string getInfo()
virtual ~StandardRenderer()
virtual void initViewer(Viewer *viewer, FrameBufferSize *frameBufferSize)
A traverser that searches Camera and LightPosition nodes in the scene graph (visitor pattern).
Definition: PreTraverser.h:37
Definition: Animation.h:28
Internal definitions required by most classes.
Base class for all renderers (abstract).
Definition: Renderer.h:45