Drop GCC 4.6 support
parent
7e21d3bd79
commit
88ec9aaae3
|
@ -115,42 +115,37 @@ set(CMAKE_MODULE_PATH "${colobot_SOURCE_DIR}/cmake" ${CMAKE_MODULE_PATH})
|
||||||
|
|
||||||
# Compiler detection
|
# Compiler detection
|
||||||
if(CMAKE_CXX_COMPILER_ID MATCHES "GNU")
|
if(CMAKE_CXX_COMPILER_ID MATCHES "GNU")
|
||||||
execute_process(
|
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 4.7)
|
||||||
COMMAND ${CMAKE_CXX_COMPILER} -dumpversion OUTPUT_VARIABLE GCC_VERSION)
|
message(FATAL_ERROR "${PROJECT_NAME} requires GCC 4.7 or greater.")
|
||||||
if (GCC_VERSION VERSION_GREATER 4.7 OR GCC_VERSION VERSION_EQUAL 4.7)
|
|
||||||
message(STATUS "Detected GCC version 4.7+")
|
|
||||||
set(CXX11_FLAGS "-std=gnu++11")
|
|
||||||
add_definitions(-DOVERRIDE=override)
|
|
||||||
elseif (GCC_VERSION VERSION_GREATER 4.6 OR GCC_VERSION VERSION_EQUAL 4.6)
|
|
||||||
message(STATUS "Detected GCC version 4.6+")
|
|
||||||
set(CXX11_FLAGS "-std=c++0x")
|
|
||||||
add_definitions(-DOVERRIDE=)
|
|
||||||
else()
|
|
||||||
message(FATAL_ERROR "${PROJECT_NAME} requires GCC 4.6 or greater.")
|
|
||||||
endif()
|
endif()
|
||||||
set(NORMAL_CXX_FLAGS "-Wall -Wold-style-cast")
|
|
||||||
|
message(STATUS "Detected GCC version 4.7+")
|
||||||
|
|
||||||
|
set(NORMAL_CXX_FLAGS "-std=gnu++11 -Wall -Wold-style-cast")
|
||||||
set(RELEASE_CXX_FLAGS "-O2")
|
set(RELEASE_CXX_FLAGS "-O2")
|
||||||
set(DEBUG_CXX_FLAGS "-g -O0")
|
set(DEBUG_CXX_FLAGS "-g -O0")
|
||||||
set(TEST_CXX_FLAGS "-pthread")
|
set(TEST_CXX_FLAGS "-pthread")
|
||||||
add_definitions(-DNOEXCEPT=noexcept)
|
add_definitions(-DNOEXCEPT=noexcept)
|
||||||
elseif(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
elseif(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||||
message(STATUS "Detected Clang compiler")
|
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS 3.1)
|
||||||
set(CXX11_FLAGS "-std=c++11")
|
message(FATAL_ERROR "${PROJECT_NAME} requires Clang 3.1 or greater.")
|
||||||
set(NORMAL_CXX_FLAGS "-Wall -Wold-style-cast")
|
endif()
|
||||||
|
|
||||||
|
message(STATUS "Detected Clang version 3.1+")
|
||||||
|
|
||||||
|
set(NORMAL_CXX_FLAGS "-std=c++11 -Wall -Wold-style-cast")
|
||||||
set(RELEASE_CXX_FLAGS "-O2")
|
set(RELEASE_CXX_FLAGS "-O2")
|
||||||
set(DEBUG_CXX_FLAGS "-g -O0")
|
set(DEBUG_CXX_FLAGS "-g -O0")
|
||||||
set(TEST_CXX_FLAGS "-pthread")
|
set(TEST_CXX_FLAGS "-pthread")
|
||||||
add_definitions(-DOVERRIDE=override)
|
|
||||||
add_definitions(-DNOEXCEPT=noexcept)
|
add_definitions(-DNOEXCEPT=noexcept)
|
||||||
elseif(CMAKE_CXX_COMPILER_ID MATCHES "MSVC")
|
elseif(CMAKE_CXX_COMPILER_ID MATCHES "MSVC")
|
||||||
message(STATUS "Detected MSVC compiler")
|
message(STATUS "Detected MSVC compiler")
|
||||||
set(CXX11_FLAGS "")
|
|
||||||
set(NORMAL_CXX_FLAGS "/wd\"4244\" /wd\"4309\" /wd\"4800\" /wd\"4996\"") # disable some useless warnings
|
set(NORMAL_CXX_FLAGS "/wd\"4244\" /wd\"4309\" /wd\"4800\" /wd\"4996\"") # disable some useless warnings
|
||||||
set(RELEASE_CXX_FLAGS "")
|
set(RELEASE_CXX_FLAGS "")
|
||||||
set(DEBUG_CXX_FLAGS "")
|
set(DEBUG_CXX_FLAGS "")
|
||||||
set(TEST_CXX_FLAGS "")
|
set(TEST_CXX_FLAGS "")
|
||||||
add_definitions(-DNOEXCEPT=)
|
add_definitions(-DNOEXCEPT=)
|
||||||
add_definitions(-DOVERRIDE=override)
|
|
||||||
else()
|
else()
|
||||||
message(FATAL_ERROR "Your C++ compiler doesn't seem to be supported.")
|
message(FATAL_ERROR "Your C++ compiler doesn't seem to be supported.")
|
||||||
endif()
|
endif()
|
||||||
|
@ -163,7 +158,7 @@ endif()
|
||||||
# Special flags for boost
|
# Special flags for boost
|
||||||
add_definitions(-DBOOST_NO_SCOPED_ENUMS -DBOOST_NO_CXX11_SCOPED_ENUMS)
|
add_definitions(-DBOOST_NO_SCOPED_ENUMS -DBOOST_NO_CXX11_SCOPED_ENUMS)
|
||||||
|
|
||||||
set(COLOBOT_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${NORMAL_CXX_FLAGS} ${CXX11_FLAGS}")
|
set(COLOBOT_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${NORMAL_CXX_FLAGS}")
|
||||||
set(COLOBOT_CXX_FLAGS_RELEASE "${RELEASE_CXX_FLAGS}")
|
set(COLOBOT_CXX_FLAGS_RELEASE "${RELEASE_CXX_FLAGS}")
|
||||||
set(COLOBOT_CXX_FLAGS_DEBUG "${DEBUG_CXX_FLAGS}")
|
set(COLOBOT_CXX_FLAGS_DEBUG "${DEBUG_CXX_FLAGS}")
|
||||||
|
|
||||||
|
|
|
@ -53,7 +53,7 @@ Since there are so many Linux flavors, it is difficult to write generic instruct
|
||||||
you will need to compile colobot.
|
you will need to compile colobot.
|
||||||
|
|
||||||
You will need:
|
You will need:
|
||||||
* recent compiler (GCC >= 4.6 or a newer clang) since we are using some features of C++11
|
* recent compiler (GCC >= 4.7, or Clang >= 3.1) since we are using some features of C++11
|
||||||
* CMake >= 2.8
|
* CMake >= 2.8
|
||||||
* Boost >= 1.51 (header files + components: filesystem and regex)
|
* Boost >= 1.51 (header files + components: filesystem and regex)
|
||||||
* SDL >= 1.2.10
|
* SDL >= 1.2.10
|
||||||
|
@ -103,7 +103,7 @@ Now to configure CMake:
|
||||||
```
|
```
|
||||||
where `/some/prefix` is installation prefix where you want to put the game files. It could be a proper installation directory
|
where `/some/prefix` is installation prefix where you want to put the game files. It could be a proper installation directory
|
||||||
if you want to install colobot in the system or simply temporary directory like `/tmp/colobot-temporary-install` if you just want to try it.
|
if you want to install colobot in the system or simply temporary directory like `/tmp/colobot-temporary-install` if you just want to try it.
|
||||||
You can also use clang as the compiler. In that case, before issuing cmake, set the following variables:
|
You can also use Clang as the compiler. In that case, before issuing cmake, set the following variables:
|
||||||
```
|
```
|
||||||
$ export CC=clang CXX=clang++
|
$ export CC=clang CXX=clang++
|
||||||
```
|
```
|
||||||
|
@ -133,7 +133,7 @@ file for details.
|
||||||
### Other platforms
|
### Other platforms
|
||||||
|
|
||||||
The code isn't particularly tied to any compiler or platform, so in theory it should work on any platform provided you have
|
The code isn't particularly tied to any compiler or platform, so in theory it should work on any platform provided you have
|
||||||
the required libraries there. Also, other compilers than currently supported GCC >= 4.6, Clang and MSVC 2013 may happen to work with our code.
|
the required libraries there. Also, other compilers than currently supported (GCC >= 4.7, Clang >= 3.1 and MSVC 2013) may happen to work with our code.
|
||||||
If you can, please try to compile the code on your platform and let us know how it goes.
|
If you can, please try to compile the code on your platform and let us know how it goes.
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -40,16 +40,16 @@ struct SystemTimeStamp
|
||||||
class CSystemUtilsLinux : public CSystemUtils
|
class CSystemUtilsLinux : public CSystemUtils
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void Init() OVERRIDE;
|
virtual void Init() override;
|
||||||
|
|
||||||
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) OVERRIDE;
|
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
||||||
|
|
||||||
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) OVERRIDE;
|
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
||||||
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) OVERRIDE;
|
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
||||||
|
|
||||||
virtual std::string GetSaveDir() OVERRIDE;
|
virtual std::string GetSaveDir() override;
|
||||||
|
|
||||||
virtual void Usleep(int usec) OVERRIDE;
|
virtual void Usleep(int usec) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
bool m_zenityAvailable;
|
bool m_zenityAvailable;
|
||||||
|
|
|
@ -28,13 +28,13 @@
|
||||||
class CSystemUtilsMacOSX : public CSystemUtilsOther
|
class CSystemUtilsMacOSX : public CSystemUtilsOther
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void Init() OVERRIDE;
|
virtual void Init() override;
|
||||||
|
|
||||||
virtual std::string GetDataPath() OVERRIDE;
|
virtual std::string GetDataPath() override;
|
||||||
virtual std::string GetLangPath() OVERRIDE;
|
virtual std::string GetLangPath() override;
|
||||||
virtual std::string GetSaveDir() OVERRIDE;
|
virtual std::string GetSaveDir() override;
|
||||||
|
|
||||||
virtual void Usleep(int usec) OVERRIDE;
|
virtual void Usleep(int usec) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
std::string m_ASPath;
|
std::string m_ASPath;
|
||||||
|
|
|
@ -42,12 +42,12 @@ struct SystemTimeStamp
|
||||||
class CSystemUtilsOther : public CSystemUtils
|
class CSystemUtilsOther : public CSystemUtils
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void Init() OVERRIDE;
|
virtual void Init() override;
|
||||||
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) OVERRIDE;
|
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
||||||
|
|
||||||
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) OVERRIDE;
|
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
||||||
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) OVERRIDE;
|
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
||||||
|
|
||||||
virtual void Usleep(int usec) OVERRIDE;
|
virtual void Usleep(int usec) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -38,16 +38,16 @@ struct SystemTimeStamp
|
||||||
class CSystemUtilsWindows : public CSystemUtils
|
class CSystemUtilsWindows : public CSystemUtils
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void Init() OVERRIDE;
|
virtual void Init() override;
|
||||||
|
|
||||||
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) OVERRIDE;
|
virtual SystemDialogResult SystemDialog(SystemDialogType type, const std::string& title, const std::string& message) override;
|
||||||
|
|
||||||
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) OVERRIDE;
|
virtual void GetCurrentTimeStamp(SystemTimeStamp *stamp) override;
|
||||||
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) OVERRIDE;
|
virtual long long TimeStampExactDiff(SystemTimeStamp *before, SystemTimeStamp *after) override;
|
||||||
|
|
||||||
virtual std::string GetSaveDir() OVERRIDE;
|
virtual std::string GetSaveDir() override;
|
||||||
|
|
||||||
virtual void Usleep(int usec) OVERRIDE;
|
virtual void Usleep(int usec) override;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
static std::string UTF8_Encode(const std::wstring &wstr);
|
static std::string UTF8_Encode(const std::wstring &wstr);
|
||||||
|
|
|
@ -133,40 +133,40 @@ public:
|
||||||
explicit CDefaultFramebuffer(const FramebufferParams ¶ms);
|
explicit CDefaultFramebuffer(const FramebufferParams ¶ms);
|
||||||
|
|
||||||
//! Creates default framebuffer
|
//! Creates default framebuffer
|
||||||
virtual void Create() OVERRIDE;
|
virtual void Create() override;
|
||||||
|
|
||||||
//! Destroys default framebuffer
|
//! Destroys default framebuffer
|
||||||
virtual void Destroy() OVERRIDE;
|
virtual void Destroy() override;
|
||||||
|
|
||||||
//! Returns true
|
//! Returns true
|
||||||
virtual bool IsDefault() OVERRIDE;
|
virtual bool IsDefault() override;
|
||||||
|
|
||||||
//! Returns width of buffers in this framebuffer
|
//! Returns width of buffers in this framebuffer
|
||||||
virtual int GetWidth() OVERRIDE;
|
virtual int GetWidth() override;
|
||||||
|
|
||||||
//! Returns height of buffers in this framebuffer
|
//! Returns height of buffers in this framebuffer
|
||||||
virtual int GetHeight() OVERRIDE;
|
virtual int GetHeight() override;
|
||||||
|
|
||||||
//! Returns depth size in bits
|
//! Returns depth size in bits
|
||||||
virtual int GetDepth() OVERRIDE;
|
virtual int GetDepth() override;
|
||||||
|
|
||||||
//! Returns number of samples or 1 if multisampling is not supported
|
//! Returns number of samples or 1 if multisampling is not supported
|
||||||
virtual int GetSamples() OVERRIDE;
|
virtual int GetSamples() override;
|
||||||
|
|
||||||
//! Returns texture that contains color buffer or 0 if not available
|
//! Returns texture that contains color buffer or 0 if not available
|
||||||
virtual int GetColorTexture() OVERRIDE;
|
virtual int GetColorTexture() override;
|
||||||
|
|
||||||
//! Returns texture that contains depth buffer or 0 if not available
|
//! Returns texture that contains depth buffer or 0 if not available
|
||||||
virtual int GetDepthTexture() OVERRIDE;
|
virtual int GetDepthTexture() override;
|
||||||
|
|
||||||
//! Binds this framebuffer to context
|
//! Binds this framebuffer to context
|
||||||
virtual void Bind() OVERRIDE;
|
virtual void Bind() override;
|
||||||
|
|
||||||
//! Unbinds this framebuffer from context
|
//! Unbinds this framebuffer from context
|
||||||
virtual void Unbind() OVERRIDE;
|
virtual void Unbind() override;
|
||||||
|
|
||||||
//! Copies content of color buffer to screen
|
//! Copies content of color buffer to screen
|
||||||
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) OVERRIDE;
|
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end of Gfx
|
} // end of Gfx
|
||||||
|
|
|
@ -55,97 +55,97 @@ public:
|
||||||
CGL21Device(const DeviceConfig &config);
|
CGL21Device(const DeviceConfig &config);
|
||||||
virtual ~CGL21Device();
|
virtual ~CGL21Device();
|
||||||
|
|
||||||
virtual void DebugHook() OVERRIDE;
|
virtual void DebugHook() override;
|
||||||
virtual void DebugLights() OVERRIDE;
|
virtual void DebugLights() override;
|
||||||
|
|
||||||
virtual bool Create() OVERRIDE;
|
virtual bool Create() override;
|
||||||
virtual void Destroy() OVERRIDE;
|
virtual void Destroy() override;
|
||||||
|
|
||||||
virtual void ConfigChanged(const DeviceConfig &newConfig) OVERRIDE;
|
virtual void ConfigChanged(const DeviceConfig &newConfig) override;
|
||||||
|
|
||||||
virtual void BeginScene() OVERRIDE;
|
virtual void BeginScene() override;
|
||||||
virtual void EndScene() OVERRIDE;
|
virtual void EndScene() override;
|
||||||
|
|
||||||
virtual void Clear() OVERRIDE;
|
virtual void Clear() override;
|
||||||
|
|
||||||
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) OVERRIDE;
|
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
||||||
|
|
||||||
virtual void SetMaterial(const Material &material) OVERRIDE;
|
virtual void SetMaterial(const Material &material) override;
|
||||||
|
|
||||||
virtual int GetMaxLightCount() OVERRIDE;
|
virtual int GetMaxLightCount() override;
|
||||||
virtual void SetLight(int index, const Light &light) OVERRIDE;
|
virtual void SetLight(int index, const Light &light) override;
|
||||||
virtual void SetLightEnabled(int index, bool enabled) OVERRIDE;
|
virtual void SetLightEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) OVERRIDE;
|
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) OVERRIDE;
|
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateDepthTexture(int width, int height, int depth) OVERRIDE;
|
virtual Texture CreateDepthTexture(int width, int height, int depth) override;
|
||||||
virtual void DestroyTexture(const Texture &texture) OVERRIDE;
|
virtual void DestroyTexture(const Texture &texture) override;
|
||||||
virtual void DestroyAllTextures() OVERRIDE;
|
virtual void DestroyAllTextures() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureStageCount() OVERRIDE;
|
virtual int GetMaxTextureStageCount() override;
|
||||||
virtual void SetTexture(int index, const Texture &texture) OVERRIDE;
|
virtual void SetTexture(int index, const Texture &texture) override;
|
||||||
virtual void SetTexture(int index, unsigned int textureId) OVERRIDE;
|
virtual void SetTexture(int index, unsigned int textureId) override;
|
||||||
virtual void SetTextureEnabled(int index, bool enabled) OVERRIDE;
|
virtual void SetTextureEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) OVERRIDE;
|
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
||||||
|
|
||||||
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) OVERRIDE;
|
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
||||||
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) OVERRIDE;
|
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
||||||
|
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) OVERRIDE;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) OVERRIDE;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) OVERRIDE;
|
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
||||||
|
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void DrawStaticBuffer(unsigned int bufferId) OVERRIDE;
|
virtual void DrawStaticBuffer(unsigned int bufferId) override;
|
||||||
virtual void DestroyStaticBuffer(unsigned int bufferId) OVERRIDE;
|
virtual void DestroyStaticBuffer(unsigned int bufferId) override;
|
||||||
|
|
||||||
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) OVERRIDE;
|
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
||||||
|
|
||||||
virtual void SetViewport(int x, int y, int width, int height) OVERRIDE;
|
virtual void SetViewport(int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void SetRenderState(RenderState state, bool enabled) OVERRIDE;
|
virtual void SetRenderState(RenderState state, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) OVERRIDE;
|
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
||||||
|
|
||||||
virtual void SetDepthTestFunc(CompFunc func) OVERRIDE;
|
virtual void SetDepthTestFunc(CompFunc func) override;
|
||||||
|
|
||||||
virtual void SetDepthBias(float factor, float units) OVERRIDE;
|
virtual void SetDepthBias(float factor, float units) override;
|
||||||
|
|
||||||
virtual void SetAlphaTestFunc(CompFunc func, float refValue) OVERRIDE;
|
virtual void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
||||||
|
|
||||||
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) OVERRIDE;
|
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
||||||
|
|
||||||
virtual void SetClearColor(const Color &color) OVERRIDE;
|
virtual void SetClearColor(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetGlobalAmbient(const Color &color) OVERRIDE;
|
virtual void SetGlobalAmbient(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) OVERRIDE;
|
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
||||||
|
|
||||||
virtual void SetCullMode(CullMode mode) OVERRIDE;
|
virtual void SetCullMode(CullMode mode) override;
|
||||||
|
|
||||||
virtual void SetShadeModel(ShadeModel model) OVERRIDE;
|
virtual void SetShadeModel(ShadeModel model) override;
|
||||||
|
|
||||||
virtual void SetShadowColor(float value) OVERRIDE;
|
virtual void SetShadowColor(float value) override;
|
||||||
|
|
||||||
virtual void SetFillMode(FillMode mode) OVERRIDE;
|
virtual void SetFillMode(FillMode mode) override;
|
||||||
|
|
||||||
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) OVERRIDE;
|
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void* GetFrameBufferPixels() const OVERRIDE;
|
virtual void* GetFrameBufferPixels() const override;
|
||||||
|
|
||||||
virtual CFramebuffer* GetFramebuffer(std::string name) OVERRIDE;
|
virtual CFramebuffer* GetFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) OVERRIDE;
|
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
||||||
|
|
||||||
virtual void DeleteFramebuffer(std::string name) OVERRIDE;
|
virtual void DeleteFramebuffer(std::string name) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//! Updates position for given light based on transformation matrices
|
//! Updates position for given light based on transformation matrices
|
||||||
|
|
|
@ -54,97 +54,97 @@ public:
|
||||||
CGL33Device(const DeviceConfig &config);
|
CGL33Device(const DeviceConfig &config);
|
||||||
virtual ~CGL33Device();
|
virtual ~CGL33Device();
|
||||||
|
|
||||||
virtual void DebugHook() OVERRIDE;
|
virtual void DebugHook() override;
|
||||||
virtual void DebugLights() OVERRIDE;
|
virtual void DebugLights() override;
|
||||||
|
|
||||||
virtual bool Create() OVERRIDE;
|
virtual bool Create() override;
|
||||||
virtual void Destroy() OVERRIDE;
|
virtual void Destroy() override;
|
||||||
|
|
||||||
virtual void ConfigChanged(const DeviceConfig &newConfig) OVERRIDE;
|
virtual void ConfigChanged(const DeviceConfig &newConfig) override;
|
||||||
|
|
||||||
virtual void BeginScene() OVERRIDE;
|
virtual void BeginScene() override;
|
||||||
virtual void EndScene() OVERRIDE;
|
virtual void EndScene() override;
|
||||||
|
|
||||||
virtual void Clear() OVERRIDE;
|
virtual void Clear() override;
|
||||||
|
|
||||||
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) OVERRIDE;
|
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
||||||
|
|
||||||
virtual void SetMaterial(const Material &material) OVERRIDE;
|
virtual void SetMaterial(const Material &material) override;
|
||||||
|
|
||||||
virtual int GetMaxLightCount() OVERRIDE;
|
virtual int GetMaxLightCount() override;
|
||||||
virtual void SetLight(int index, const Light &light) OVERRIDE;
|
virtual void SetLight(int index, const Light &light) override;
|
||||||
virtual void SetLightEnabled(int index, bool enabled) OVERRIDE;
|
virtual void SetLightEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) OVERRIDE;
|
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) OVERRIDE;
|
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateDepthTexture(int width, int height, int depth) OVERRIDE;
|
virtual Texture CreateDepthTexture(int width, int height, int depth) override;
|
||||||
virtual void DestroyTexture(const Texture &texture) OVERRIDE;
|
virtual void DestroyTexture(const Texture &texture) override;
|
||||||
virtual void DestroyAllTextures() OVERRIDE;
|
virtual void DestroyAllTextures() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureStageCount() OVERRIDE;
|
virtual int GetMaxTextureStageCount() override;
|
||||||
virtual void SetTexture(int index, const Texture &texture) OVERRIDE;
|
virtual void SetTexture(int index, const Texture &texture) override;
|
||||||
virtual void SetTexture(int index, unsigned int textureId) OVERRIDE;
|
virtual void SetTexture(int index, unsigned int textureId) override;
|
||||||
virtual void SetTextureEnabled(int index, bool enabled) OVERRIDE;
|
virtual void SetTextureEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) OVERRIDE;
|
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
||||||
|
|
||||||
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) OVERRIDE;
|
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
||||||
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) OVERRIDE;
|
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
||||||
|
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) OVERRIDE;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) OVERRIDE;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) OVERRIDE;
|
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
||||||
|
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void DrawStaticBuffer(unsigned int bufferId) OVERRIDE;
|
virtual void DrawStaticBuffer(unsigned int bufferId) override;
|
||||||
virtual void DestroyStaticBuffer(unsigned int bufferId) OVERRIDE;
|
virtual void DestroyStaticBuffer(unsigned int bufferId) override;
|
||||||
|
|
||||||
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) OVERRIDE;
|
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
||||||
|
|
||||||
virtual void SetViewport(int x, int y, int width, int height) OVERRIDE;
|
virtual void SetViewport(int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void SetRenderState(RenderState state, bool enabled) OVERRIDE;
|
virtual void SetRenderState(RenderState state, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) OVERRIDE;
|
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
||||||
|
|
||||||
virtual void SetDepthTestFunc(CompFunc func) OVERRIDE;
|
virtual void SetDepthTestFunc(CompFunc func) override;
|
||||||
|
|
||||||
virtual void SetDepthBias(float factor, float units) OVERRIDE;
|
virtual void SetDepthBias(float factor, float units) override;
|
||||||
|
|
||||||
virtual void SetAlphaTestFunc(CompFunc func, float refValue) OVERRIDE;
|
virtual void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
||||||
|
|
||||||
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) OVERRIDE;
|
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
||||||
|
|
||||||
virtual void SetClearColor(const Color &color) OVERRIDE;
|
virtual void SetClearColor(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetGlobalAmbient(const Color &color) OVERRIDE;
|
virtual void SetGlobalAmbient(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) OVERRIDE;
|
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
||||||
|
|
||||||
virtual void SetCullMode(CullMode mode) OVERRIDE;
|
virtual void SetCullMode(CullMode mode) override;
|
||||||
|
|
||||||
virtual void SetShadeModel(ShadeModel model) OVERRIDE;
|
virtual void SetShadeModel(ShadeModel model) override;
|
||||||
|
|
||||||
virtual void SetShadowColor(float value) OVERRIDE;
|
virtual void SetShadowColor(float value) override;
|
||||||
|
|
||||||
virtual void SetFillMode(FillMode mode) OVERRIDE;
|
virtual void SetFillMode(FillMode mode) override;
|
||||||
|
|
||||||
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) OVERRIDE;
|
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void* GetFrameBufferPixels() const OVERRIDE;
|
virtual void* GetFrameBufferPixels() const override;
|
||||||
|
|
||||||
virtual CFramebuffer* GetFramebuffer(std::string name) OVERRIDE;
|
virtual CFramebuffer* GetFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) OVERRIDE;
|
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
||||||
|
|
||||||
virtual void DeleteFramebuffer(std::string name) OVERRIDE;
|
virtual void DeleteFramebuffer(std::string name) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//! Updates position for given light based on transformation matrices
|
//! Updates position for given light based on transformation matrices
|
||||||
|
|
|
@ -74,97 +74,97 @@ public:
|
||||||
CGLDevice(const DeviceConfig &config);
|
CGLDevice(const DeviceConfig &config);
|
||||||
virtual ~CGLDevice();
|
virtual ~CGLDevice();
|
||||||
|
|
||||||
virtual void DebugHook() OVERRIDE;
|
virtual void DebugHook() override;
|
||||||
virtual void DebugLights() OVERRIDE;
|
virtual void DebugLights() override;
|
||||||
|
|
||||||
virtual bool Create() OVERRIDE;
|
virtual bool Create() override;
|
||||||
virtual void Destroy() OVERRIDE;
|
virtual void Destroy() override;
|
||||||
|
|
||||||
virtual void ConfigChanged(const DeviceConfig &newConfig) OVERRIDE;
|
virtual void ConfigChanged(const DeviceConfig &newConfig) override;
|
||||||
|
|
||||||
virtual void BeginScene() OVERRIDE;
|
virtual void BeginScene() override;
|
||||||
virtual void EndScene() OVERRIDE;
|
virtual void EndScene() override;
|
||||||
|
|
||||||
virtual void Clear() OVERRIDE;
|
virtual void Clear() override;
|
||||||
|
|
||||||
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) OVERRIDE;
|
virtual void SetTransform(TransformType type, const Math::Matrix &matrix) override;
|
||||||
|
|
||||||
virtual void SetMaterial(const Material &material) OVERRIDE;
|
virtual void SetMaterial(const Material &material) override;
|
||||||
|
|
||||||
virtual int GetMaxLightCount() OVERRIDE;
|
virtual int GetMaxLightCount() override;
|
||||||
virtual void SetLight(int index, const Light &light) OVERRIDE;
|
virtual void SetLight(int index, const Light &light) override;
|
||||||
virtual void SetLightEnabled(int index, bool enabled) OVERRIDE;
|
virtual void SetLightEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) OVERRIDE;
|
virtual Texture CreateTexture(CImage *image, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) OVERRIDE;
|
virtual Texture CreateTexture(ImageData *data, const TextureCreateParams ¶ms) override;
|
||||||
virtual Texture CreateDepthTexture(int width, int height, int depth) OVERRIDE;
|
virtual Texture CreateDepthTexture(int width, int height, int depth) override;
|
||||||
virtual void DestroyTexture(const Texture &texture) OVERRIDE;
|
virtual void DestroyTexture(const Texture &texture) override;
|
||||||
virtual void DestroyAllTextures() OVERRIDE;
|
virtual void DestroyAllTextures() override;
|
||||||
|
|
||||||
virtual int GetMaxTextureStageCount() OVERRIDE;
|
virtual int GetMaxTextureStageCount() override;
|
||||||
virtual void SetTexture(int index, const Texture &texture) OVERRIDE;
|
virtual void SetTexture(int index, const Texture &texture) override;
|
||||||
virtual void SetTexture(int index, unsigned int textureId) OVERRIDE;
|
virtual void SetTexture(int index, unsigned int textureId) override;
|
||||||
virtual void SetTextureEnabled(int index, bool enabled) OVERRIDE;
|
virtual void SetTextureEnabled(int index, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) OVERRIDE;
|
virtual void SetTextureStageParams(int index, const TextureStageParams ¶ms) override;
|
||||||
|
|
||||||
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) OVERRIDE;
|
virtual void SetTextureStageWrap(int index, Gfx::TexWrapMode wrapS, Gfx::TexWrapMode wrapT) override;
|
||||||
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) OVERRIDE;
|
virtual void SetTextureCoordGeneration(int index, TextureGenerationParams ¶ms) override;
|
||||||
|
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const Vertex *vertices , int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) OVERRIDE;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
virtual void DrawPrimitive(PrimitiveType type, const VertexTex2 *vertices, int vertexCount,
|
||||||
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) OVERRIDE;
|
Color color = Color(1.0f, 1.0f, 1.0f, 1.0f)) override;
|
||||||
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) OVERRIDE;
|
virtual void DrawPrimitive(PrimitiveType type, const VertexCol *vertices , int vertexCount) override;
|
||||||
|
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) OVERRIDE;
|
virtual unsigned int CreateStaticBuffer(PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const Vertex* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexTex2* vertices, int vertexCount) override;
|
||||||
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) OVERRIDE;
|
virtual void UpdateStaticBuffer(unsigned int bufferId, PrimitiveType primitiveType, const VertexCol* vertices, int vertexCount) override;
|
||||||
virtual void DrawStaticBuffer(unsigned int bufferId) OVERRIDE;
|
virtual void DrawStaticBuffer(unsigned int bufferId) override;
|
||||||
virtual void DestroyStaticBuffer(unsigned int bufferId) OVERRIDE;
|
virtual void DestroyStaticBuffer(unsigned int bufferId) override;
|
||||||
|
|
||||||
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) OVERRIDE;
|
virtual int ComputeSphereVisibility(const Math::Vector ¢er, float radius) override;
|
||||||
|
|
||||||
virtual void SetViewport(int x, int y, int width, int height) OVERRIDE;
|
virtual void SetViewport(int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void SetRenderState(RenderState state, bool enabled) OVERRIDE;
|
virtual void SetRenderState(RenderState state, bool enabled) override;
|
||||||
|
|
||||||
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) OVERRIDE;
|
virtual void SetColorMask(bool red, bool green, bool blue, bool alpha) override;
|
||||||
|
|
||||||
virtual void SetDepthTestFunc(CompFunc func) OVERRIDE;
|
virtual void SetDepthTestFunc(CompFunc func) override;
|
||||||
|
|
||||||
virtual void SetDepthBias(float factor, float units) OVERRIDE;
|
virtual void SetDepthBias(float factor, float units) override;
|
||||||
|
|
||||||
virtual void SetAlphaTestFunc(CompFunc func, float refValue) OVERRIDE;
|
virtual void SetAlphaTestFunc(CompFunc func, float refValue) override;
|
||||||
|
|
||||||
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) OVERRIDE;
|
virtual void SetBlendFunc(BlendFunc srcBlend, BlendFunc dstBlend) override;
|
||||||
|
|
||||||
virtual void SetClearColor(const Color &color) OVERRIDE;
|
virtual void SetClearColor(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetGlobalAmbient(const Color &color) OVERRIDE;
|
virtual void SetGlobalAmbient(const Color &color) override;
|
||||||
|
|
||||||
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) OVERRIDE;
|
virtual void SetFogParams(FogMode mode, const Color &color, float start, float end, float density) override;
|
||||||
|
|
||||||
virtual void SetCullMode(CullMode mode) OVERRIDE;
|
virtual void SetCullMode(CullMode mode) override;
|
||||||
|
|
||||||
virtual void SetShadeModel(ShadeModel model) OVERRIDE;
|
virtual void SetShadeModel(ShadeModel model) override;
|
||||||
|
|
||||||
virtual void SetShadowColor(float value) OVERRIDE;
|
virtual void SetShadowColor(float value) override;
|
||||||
|
|
||||||
virtual void SetFillMode(FillMode mode) OVERRIDE;
|
virtual void SetFillMode(FillMode mode) override;
|
||||||
|
|
||||||
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) OVERRIDE;
|
virtual void CopyFramebufferToTexture(Texture& texture, int xOffset, int yOffset, int x, int y, int width, int height) override;
|
||||||
|
|
||||||
virtual void* GetFrameBufferPixels() const OVERRIDE;
|
virtual void* GetFrameBufferPixels() const override;
|
||||||
|
|
||||||
virtual CFramebuffer* GetFramebuffer(std::string name) OVERRIDE;
|
virtual CFramebuffer* GetFramebuffer(std::string name) override;
|
||||||
|
|
||||||
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) OVERRIDE;
|
virtual CFramebuffer* CreateFramebuffer(std::string name, const FramebufferParams& params) override;
|
||||||
|
|
||||||
virtual void DeleteFramebuffer(std::string name) OVERRIDE;
|
virtual void DeleteFramebuffer(std::string name) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//! Updates internal modelview matrix
|
//! Updates internal modelview matrix
|
||||||
|
|
|
@ -49,29 +49,29 @@ protected:
|
||||||
public:
|
public:
|
||||||
CGLFramebuffer(const FramebufferParams& params);
|
CGLFramebuffer(const FramebufferParams& params);
|
||||||
|
|
||||||
virtual void Create() OVERRIDE;
|
virtual void Create() override;
|
||||||
|
|
||||||
virtual void Destroy() OVERRIDE;
|
virtual void Destroy() override;
|
||||||
|
|
||||||
virtual bool IsDefault() OVERRIDE;
|
virtual bool IsDefault() override;
|
||||||
|
|
||||||
virtual int GetWidth() OVERRIDE;
|
virtual int GetWidth() override;
|
||||||
|
|
||||||
virtual int GetHeight() OVERRIDE;
|
virtual int GetHeight() override;
|
||||||
|
|
||||||
virtual int GetDepth() OVERRIDE;
|
virtual int GetDepth() override;
|
||||||
|
|
||||||
virtual int GetSamples() OVERRIDE;
|
virtual int GetSamples() override;
|
||||||
|
|
||||||
virtual int GetColorTexture() OVERRIDE;
|
virtual int GetColorTexture() override;
|
||||||
|
|
||||||
virtual int GetDepthTexture() OVERRIDE;
|
virtual int GetDepthTexture() override;
|
||||||
|
|
||||||
virtual void Bind() OVERRIDE;
|
virtual void Bind() override;
|
||||||
|
|
||||||
virtual void Unbind() OVERRIDE;
|
virtual void Unbind() override;
|
||||||
|
|
||||||
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) OVERRIDE;
|
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -99,29 +99,29 @@ protected:
|
||||||
public:
|
public:
|
||||||
CGLFramebufferEXT(const FramebufferParams& params);
|
CGLFramebufferEXT(const FramebufferParams& params);
|
||||||
|
|
||||||
virtual void Create() OVERRIDE;
|
virtual void Create() override;
|
||||||
|
|
||||||
virtual void Destroy() OVERRIDE;
|
virtual void Destroy() override;
|
||||||
|
|
||||||
virtual bool IsDefault() OVERRIDE;
|
virtual bool IsDefault() override;
|
||||||
|
|
||||||
virtual int GetWidth() OVERRIDE;
|
virtual int GetWidth() override;
|
||||||
|
|
||||||
virtual int GetHeight() OVERRIDE;
|
virtual int GetHeight() override;
|
||||||
|
|
||||||
virtual int GetDepth() OVERRIDE;
|
virtual int GetDepth() override;
|
||||||
|
|
||||||
virtual int GetSamples() OVERRIDE;
|
virtual int GetSamples() override;
|
||||||
|
|
||||||
virtual int GetColorTexture() OVERRIDE;
|
virtual int GetColorTexture() override;
|
||||||
|
|
||||||
virtual int GetDepthTexture() OVERRIDE;
|
virtual int GetDepthTexture() override;
|
||||||
|
|
||||||
virtual void Bind() OVERRIDE;
|
virtual void Bind() override;
|
||||||
|
|
||||||
virtual void Unbind() OVERRIDE;
|
virtual void Unbind() override;
|
||||||
|
|
||||||
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) OVERRIDE;
|
virtual void CopyToScreen(int fromX, int fromY, int fromWidth, int fromHeight, int toX, int toY, int toWidth, int toHeight) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
} // end of Gfx
|
} // end of Gfx
|
||||||
|
|
|
@ -32,16 +32,16 @@ public:
|
||||||
CAutoJostle(CObject* object);
|
CAutoJostle(CObject* object);
|
||||||
~CAutoJostle();
|
~CAutoJostle();
|
||||||
|
|
||||||
void DeleteObject(bool bAll=false) OVERRIDE;
|
void DeleteObject(bool bAll=false) override;
|
||||||
|
|
||||||
void Init() OVERRIDE;
|
void Init() override;
|
||||||
void Start(int param, float force);
|
void Start(int param, float force);
|
||||||
bool EventProcess(const Event &event) OVERRIDE;
|
bool EventProcess(const Event &event) override;
|
||||||
Error IsEnded() OVERRIDE;
|
Error IsEnded() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
// Overriden to avoid warning about hiding virtual function
|
// Overriden to avoid warning about hiding virtual function
|
||||||
void Start(int param) OVERRIDE;
|
void Start(int param) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
float m_force;
|
float m_force;
|
||||||
|
|
|
@ -50,40 +50,40 @@ public:
|
||||||
ALSound();
|
ALSound();
|
||||||
~ALSound();
|
~ALSound();
|
||||||
|
|
||||||
bool Create() OVERRIDE;
|
bool Create() override;
|
||||||
bool Cache(Sound, const std::string &) OVERRIDE;
|
bool Cache(Sound, const std::string &) override;
|
||||||
bool CacheMusic(const std::string &) OVERRIDE;
|
bool CacheMusic(const std::string &) override;
|
||||||
bool IsCached(Sound) OVERRIDE;
|
bool IsCached(Sound) override;
|
||||||
bool IsCachedMusic(const std::string &) OVERRIDE;
|
bool IsCachedMusic(const std::string &) override;
|
||||||
|
|
||||||
bool GetEnable() OVERRIDE;
|
bool GetEnable() override;
|
||||||
|
|
||||||
void SetAudioVolume(int volume) OVERRIDE;
|
void SetAudioVolume(int volume) override;
|
||||||
int GetAudioVolume() OVERRIDE;
|
int GetAudioVolume() override;
|
||||||
void SetMusicVolume(int volume) OVERRIDE;
|
void SetMusicVolume(int volume) override;
|
||||||
int GetMusicVolume() OVERRIDE;
|
int GetMusicVolume() override;
|
||||||
|
|
||||||
void SetListener(const Math::Vector &eye, const Math::Vector &lookat) OVERRIDE;
|
void SetListener(const Math::Vector &eye, const Math::Vector &lookat) override;
|
||||||
void FrameMove(float rTime) OVERRIDE;
|
void FrameMove(float rTime) override;
|
||||||
|
|
||||||
int Play(Sound sound, float amplitude=1.0f, float frequency=1.0f, bool bLoop = false) OVERRIDE;
|
int Play(Sound sound, float amplitude=1.0f, float frequency=1.0f, bool bLoop = false) override;
|
||||||
int Play(Sound sound, const Math::Vector &pos, float amplitude=1.0f, float frequency=1.0f, bool bLoop = false) OVERRIDE;
|
int Play(Sound sound, const Math::Vector &pos, float amplitude=1.0f, float frequency=1.0f, bool bLoop = false) override;
|
||||||
bool FlushEnvelope(int channel) OVERRIDE;
|
bool FlushEnvelope(int channel) override;
|
||||||
bool AddEnvelope(int channel, float amplitude, float frequency, float time, SoundNext oper) OVERRIDE;
|
bool AddEnvelope(int channel, float amplitude, float frequency, float time, SoundNext oper) override;
|
||||||
bool Position(int channel, const Math::Vector &pos) OVERRIDE;
|
bool Position(int channel, const Math::Vector &pos) override;
|
||||||
bool Frequency(int channel, float frequency) OVERRIDE;
|
bool Frequency(int channel, float frequency) override;
|
||||||
bool Stop(int channel) OVERRIDE;
|
bool Stop(int channel) override;
|
||||||
bool StopAll() OVERRIDE;
|
bool StopAll() override;
|
||||||
bool MuteAll(bool bMute) OVERRIDE;
|
bool MuteAll(bool bMute) override;
|
||||||
|
|
||||||
bool PlayMusic(int rank, bool bRepeat, float fadeTime=2.0f) OVERRIDE;
|
bool PlayMusic(int rank, bool bRepeat, float fadeTime=2.0f) override;
|
||||||
bool PlayMusic(const std::string &filename, bool bRepeat, float fadeTime=2.0f) OVERRIDE;
|
bool PlayMusic(const std::string &filename, bool bRepeat, float fadeTime=2.0f) override;
|
||||||
bool RestartMusic() OVERRIDE;
|
bool RestartMusic() override;
|
||||||
void SuspendMusic() OVERRIDE;
|
void SuspendMusic() override;
|
||||||
void StopMusic(float fadeTime=2.0f) OVERRIDE;
|
void StopMusic(float fadeTime=2.0f) override;
|
||||||
bool IsPlayingMusic() OVERRIDE;
|
bool IsPlayingMusic() override;
|
||||||
bool PlayPauseMusic(const std::string &filename, bool repeat) OVERRIDE;
|
bool PlayPauseMusic(const std::string &filename, bool repeat) override;
|
||||||
void StopPauseMusic() OVERRIDE;
|
void StopPauseMusic() override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void CleanUp();
|
void CleanUp();
|
||||||
|
|
|
@ -47,15 +47,15 @@ class CList : public CControl
|
||||||
|
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg, float expand);
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg, float expand);
|
||||||
|
|
||||||
void SetPos(Math::Point pos) OVERRIDE;
|
void SetPos(Math::Point pos) override;
|
||||||
void SetDim(Math::Point dim) OVERRIDE;
|
void SetDim(Math::Point dim) override;
|
||||||
|
|
||||||
bool SetState(int state, bool bState) OVERRIDE;
|
bool SetState(int state, bool bState) override;
|
||||||
bool SetState(int state) OVERRIDE;
|
bool SetState(int state) override;
|
||||||
bool ClearState(int state) OVERRIDE;
|
bool ClearState(int state) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event) OVERRIDE;
|
bool EventProcess(const Event &event) override;
|
||||||
void Draw() OVERRIDE;
|
void Draw() override;
|
||||||
|
|
||||||
void Flush();
|
void Flush();
|
||||||
|
|
||||||
|
@ -97,7 +97,7 @@ class CList : public CControl
|
||||||
|
|
||||||
private:
|
private:
|
||||||
// Overridden to avoid warning about hiding the virtual function
|
// Overridden to avoid warning about hiding the virtual function
|
||||||
virtual bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) OVERRIDE;
|
virtual bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventType) override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
CButton* m_button[LISTMAXDISPLAY];
|
CButton* m_button[LISTMAXDISPLAY];
|
||||||
|
|
|
@ -60,7 +60,7 @@ public:
|
||||||
~CWindow();
|
~CWindow();
|
||||||
|
|
||||||
void Flush();
|
void Flush();
|
||||||
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg) OVERRIDE;
|
bool Create(Math::Point pos, Math::Point dim, int icon, EventType eventMsg) override;
|
||||||
CButton* CreateButton(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
CButton* CreateButton(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
||||||
CColor* CreateColor(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
CColor* CreateColor(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
||||||
CCheck* CreateCheck(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
CCheck* CreateCheck(Math::Point pos, Math::Point dim, int icon, EventType eventMsg);
|
||||||
|
@ -85,13 +85,13 @@ public:
|
||||||
EventType GetEventTypeFull();
|
EventType GetEventTypeFull();
|
||||||
EventType GetEventTypeClose();
|
EventType GetEventTypeClose();
|
||||||
|
|
||||||
virtual void SetName(std::string name, bool tooltip = true) OVERRIDE;
|
virtual void SetName(std::string name, bool tooltip = true) override;
|
||||||
|
|
||||||
void SetTrashEvent(bool bTrash);
|
void SetTrashEvent(bool bTrash);
|
||||||
bool GetTrashEvent();
|
bool GetTrashEvent();
|
||||||
|
|
||||||
void SetPos(Math::Point pos) OVERRIDE;
|
void SetPos(Math::Point pos) override;
|
||||||
void SetDim(Math::Point dim) OVERRIDE;
|
void SetDim(Math::Point dim) override;
|
||||||
|
|
||||||
void SetMinDim(Math::Point dim);
|
void SetMinDim(Math::Point dim);
|
||||||
void SetMaxDim(Math::Point dim);
|
void SetMaxDim(Math::Point dim);
|
||||||
|
@ -114,11 +114,11 @@ public:
|
||||||
void SetFixed(bool bFix);
|
void SetFixed(bool bFix);
|
||||||
bool GetFixed();
|
bool GetFixed();
|
||||||
|
|
||||||
bool GetTooltip(Math::Point pos, std::string &name) OVERRIDE;
|
bool GetTooltip(Math::Point pos, std::string &name) override;
|
||||||
|
|
||||||
bool EventProcess(const Event &event) OVERRIDE;
|
bool EventProcess(const Event &event) override;
|
||||||
|
|
||||||
void Draw() OVERRIDE;
|
void Draw() override;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
int BorderDetect(Math::Point pos);
|
int BorderDetect(Math::Point pos);
|
||||||
|
|
|
@ -47,7 +47,7 @@ struct FakeSystemTimeStamp : public SystemTimeStamp
|
||||||
class CApplicationWrapper : public CApplication
|
class CApplicationWrapper : public CApplication
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
Event CreateUpdateEvent() OVERRIDE
|
Event CreateUpdateEvent() override
|
||||||
{
|
{
|
||||||
return CApplication::CreateUpdateEvent();
|
return CApplication::CreateUpdateEvent();
|
||||||
}
|
}
|
||||||
|
@ -65,8 +65,8 @@ protected:
|
||||||
~ApplicationUT() NOEXCEPT
|
~ApplicationUT() NOEXCEPT
|
||||||
{}
|
{}
|
||||||
|
|
||||||
void SetUp() OVERRIDE;
|
void SetUp() override;
|
||||||
void TearDown() OVERRIDE;
|
void TearDown() override;
|
||||||
|
|
||||||
void NextInstant(long long diff);
|
void NextInstant(long long diff);
|
||||||
|
|
||||||
|
|
|
@ -41,8 +41,8 @@ protected:
|
||||||
~LightManagerUT() NOEXCEPT
|
~LightManagerUT() NOEXCEPT
|
||||||
{}
|
{}
|
||||||
|
|
||||||
void SetUp() OVERRIDE;
|
void SetUp() override;
|
||||||
void TearDown() OVERRIDE;
|
void TearDown() override;
|
||||||
|
|
||||||
void PrepareLightTesting(int maxLights, Math::Vector eyePos);
|
void PrepareLightTesting(int maxLights, Math::Vector eyePos);
|
||||||
void CheckLightSorting(EngineObjectType objectType, const std::vector<int>& expectedLights);
|
void CheckLightSorting(EngineObjectType objectType, const std::vector<int>& expectedLights);
|
||||||
|
|
Loading…
Reference in New Issue