OGRE  1.8
Object-Oriented Graphics Rendering Engine
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
OgreGLES2Support.h
Go to the documentation of this file.
1 /*
2 -----------------------------------------------------------------------------
3 This source file is part of OGRE
4  (Object-oriented Graphics Rendering Engine)
5 For the latest info, see http://www.ogre3d.org/
6 
7 Copyright (c) 2000-2013 Torus Knot Software Ltd
8 
9 Permission is hereby granted, free of charge, to any person obtaining a copy
10 of this software and associated documentation files (the "Software"), to deal
11 in the Software without restriction, including without limitation the rights
12 to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
13 copies of the Software, and to permit persons to whom the Software is
14 furnished to do so, subject to the following conditions:
15 
16 The above copyright notice and this permission notice shall be included in
17 all copies or substantial portions of the Software.
18 
19 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21 FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
22 AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23 LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
24 OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
25 THE SOFTWARE.
26 -----------------------------------------------------------------------------
27 */
28 
29 #ifndef __GLES2Support_H__
30 #define __GLES2Support_H__
31 
32 #include "OgreGLES2Prerequisites.h"
33 #include "OgreRenderWindow.h"
34 #include "OgreConfigOptionMap.h"
35 
36 namespace Ogre
37 {
38  class GLES2RenderSystem;
39 
41  {
42  public:
44  virtual ~GLES2Support() { }
45 
51  virtual void addConfig() = 0;
52  virtual void setConfigOption(const String &name, const String &value);
53 
58  virtual String validateConfig() = 0;
59  virtual ConfigOptionMap& getConfigOptions(void);
60  virtual RenderWindow* createWindow(bool autoCreateWindow,
61  GLES2RenderSystem *renderSystem,
62  const String& windowTitle) = 0;
63 
65  virtual RenderWindow* newWindow(const String &name,
66  unsigned int width, unsigned int height,
67  bool fullScreen,
68  const NameValuePairList *miscParams = 0) = 0;
69 
73  const String& getGLVendor(void) const
74  {
75  return mVendor;
76  }
77 
81  const String& getGLVersion(void) const
82  {
83  return mVersion;
84  }
85 
89  const String& getShaderCachePath(void) const
90  {
91  return mShaderCachePath;
92  }
93 
97  const String& getShaderLibraryPath(void) const
98  {
99  return mShaderLibraryPath;
100  }
101 
106  {
107  mShaderCachePath = path;
108  }
109 
114  {
115  mShaderLibraryPath = path;
116  }
117 
121  virtual void *getProcAddress(const String& procname) = 0;
122 
126  virtual void initialiseExtensions();
127 
131  virtual bool checkExtension(const String& ext) const;
132 
134  virtual unsigned int getDisplayMonitorCount() const
135  {
136  return 1;
137  }
138 
142  virtual void start() = 0;
146  virtual void stop() = 0;
147 
148  private:
153 
154  protected:
155  // Stored options
157 
158  // This contains the complete list of supported extensions
160  };
161 
162 }
163 
164 #endif
Manages the target rendering window.
const String & getShaderCachePath(void) const
Get shader cache path.
map< String, String >::type NameValuePairList
Name / value parameter pair (first = name, second = value)
Definition: OgreCommon.h:553
#define _OgreGLES2Export
const String & getGLVersion(void) const
Get version information.
ConfigOptionMap mOptions
void setShaderLibraryPath(String path)
Set shader library path.
Implementation of GL ES 2.x as a rendering system.
const String & getGLVendor(void) const
Get vendor information.
set< String >::type extensionList
map< String, ConfigOption >::type ConfigOptionMap
const String & getShaderLibraryPath(void) const
Get shader library path.
void setShaderCachePath(String path)
Set shader cache path.
virtual unsigned int getDisplayMonitorCount() const
Gets the number of display monitors.
_StringBase String