Omnidome
Fulldome Mapping Software Toolkit
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Setup.h
Go to the documentation of this file.
1 /* Copyright (c) 2014-2015 "Omnidome" by cr8tr
2  * Dome Mapping Projection Software (http://omnido.me).
3  * Omnidome was created by Michael Winkelmann aka Wilston Oreo (@WilstonOreo)
4  *
5  * This file is part of Omnidome.
6  *
7  * Omnidome is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU Affero General Public License as
9  * published by the Free Software Foundation, either version 3 of the
10  * License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU Affero General Public License for more details.
16  * You should have received a copy of the GNU Affero General Public License
17  * along with this program. If not, see <http://www.gnu.org/licenses/>.
18  */
19 
20 #ifndef OMNI_PROJ_SETUP_H_
21 #define OMNI_PROJ_SETUP_H_
22 
23 #include <vector>
24 #include <omni/TypeIdInterface.h>
26 
27 namespace omni {
28  namespace proj {
29  class Projector;
30 
31  /// Interface for a projector setup
32  class Setup :
33  public PropertyMapSerializer,
34  public TypeIdInterface {
35  public:
36  /// Setup projector with scene size
37  virtual void setup(Projector&) = 0;
38 
39  inline virtual bool isMultiSetup() const {
40  return false;
41  }
42 
43  inline virtual void setup(Projector& _proj, qreal _scale) {
44  setup(_proj);
45  scale(_scale);
46  }
47 
48  /// Scale projector setup by factor, e.g. to adapt defaults to scene size
49  virtual void scale(qreal _factor) = 0;
50 
51  virtual bool flipped() const = 0;
52  };
53 
54  /// Typedef for our factory
56  }
57 
59 }
60 
61 #endif /* OMNI_PROJ_SETUP_H_ */
A projector with a transformation matrix and setup.
Definition: Projector.h:32
virtual void scale(qreal _factor)=0
Scale projector setup by factor, e.g. to adapt defaults to scene size.
virtual void setup(Projector &_proj, qreal _scale)
Definition: Setup.h:43
proj::Setup ProjectorSetup
Definition: Setup.h:58
virtual bool isMultiSetup() const
Definition: Setup.h:39
virtual bool flipped() const =0
Abstract Interface with a single virtual member function which returns.
Definition: TypeIdInterface.h:28
Interface for a projector setup.
Definition: Setup.h:32
The central factory class.
Definition: factory.hpp:38
AbstractFactory< Setup > SetupFactory
Typedef for our factory.
Definition: Setup.h:55
virtual void setup(Projector &)=0
Setup projector with scene size.