diff --git a/include/eepp/audio/csoundbuffer.hpp b/include/eepp/audio/csoundbuffer.hpp index f6db5a977..466cf0289 100755 --- a/include/eepp/audio/csoundbuffer.hpp +++ b/include/eepp/audio/csoundbuffer.hpp @@ -4,6 +4,7 @@ #include #include #include +#include namespace EE { namespace Audio { diff --git a/include/eepp/base.hpp b/include/eepp/base.hpp index 865645a90..29d623504 100644 --- a/include/eepp/base.hpp +++ b/include/eepp/base.hpp @@ -1,33 +1,6 @@ #ifndef EE_BASE_HPP #define EE_BASE_HPP -#undef M_E -#undef M_PI -#undef INFINITY - -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include - -#include -#include - -#include -#include -#include -#include -#include -#include -#include - #include #include diff --git a/include/eepp/base/allocator.hpp b/include/eepp/base/allocator.hpp index 679757c56..6fdc91a8c 100644 --- a/include/eepp/base/allocator.hpp +++ b/include/eepp/base/allocator.hpp @@ -2,6 +2,7 @@ #define EE_ALLOCATOR_HPP #include +#include namespace EE { diff --git a/include/eepp/base/base.hpp b/include/eepp/base/base.hpp index c8697c27a..b22c752b6 100644 --- a/include/eepp/base/base.hpp +++ b/include/eepp/base/base.hpp @@ -6,6 +6,5 @@ #include #include #include -#include #endif diff --git a/include/eepp/base/memorymanager.hpp b/include/eepp/base/memorymanager.hpp index be5554a1f..ce36c0b4b 100644 --- a/include/eepp/base/memorymanager.hpp +++ b/include/eepp/base/memorymanager.hpp @@ -3,6 +3,7 @@ #include #include +#include #include #include #include diff --git a/include/eepp/base/stlcontainers.hpp b/include/eepp/base/stlcontainers.hpp index 69b0e7005..60825f8d7 100644 --- a/include/eepp/base/stlcontainers.hpp +++ b/include/eepp/base/stlcontainers.hpp @@ -2,6 +2,9 @@ #define EE_STLCONTAINERS_HPP #include +#include +#include +#include namespace EE { template > diff --git a/include/eepp/declares.hpp b/include/eepp/declares.hpp index fb068cb14..8f30a7a08 100644 --- a/include/eepp/declares.hpp +++ b/include/eepp/declares.hpp @@ -2,6 +2,7 @@ #define EE_DECLARES_HPP #include +#include #define EE_PLATFORM_WIN 1 #define EE_PLATFORM_LINUX 2 diff --git a/include/eepp/gaming/clightmanager.hpp b/include/eepp/gaming/clightmanager.hpp index 73a0d1f96..439c42752 100644 --- a/include/eepp/gaming/clightmanager.hpp +++ b/include/eepp/gaming/clightmanager.hpp @@ -3,6 +3,7 @@ #include #include +#include namespace EE { namespace Gaming { diff --git a/include/eepp/gaming/cobjectlayer.hpp b/include/eepp/gaming/cobjectlayer.hpp index bb63b0ac7..39b6da4d9 100644 --- a/include/eepp/gaming/cobjectlayer.hpp +++ b/include/eepp/gaming/cobjectlayer.hpp @@ -3,6 +3,7 @@ #include #include +#include namespace EE { namespace Gaming { diff --git a/include/eepp/graphics/cconsole.hpp b/include/eepp/graphics/cconsole.hpp index 03b9e8d3a..1387e7291 100755 --- a/include/eepp/graphics/cconsole.hpp +++ b/include/eepp/graphics/cconsole.hpp @@ -6,6 +6,7 @@ #include #include #include +#include using namespace EE::Window; diff --git a/include/eepp/math/math.hpp b/include/eepp/math/math.hpp index 2721ca4d7..29dcab2d0 100755 --- a/include/eepp/math/math.hpp +++ b/include/eepp/math/math.hpp @@ -2,6 +2,7 @@ #define EECMATH_H #include +#include namespace EE { namespace Math { diff --git a/include/eepp/system/ciostreamfile.hpp b/include/eepp/system/ciostreamfile.hpp index 7347abce1..5c318937d 100644 --- a/include/eepp/system/ciostreamfile.hpp +++ b/include/eepp/system/ciostreamfile.hpp @@ -2,6 +2,8 @@ #define EE_SYSTEMCIOSTREAMFILE_HPP #include +#include +#include namespace EE { namespace System { diff --git a/include/eepp/system/cobjectloader.hpp b/include/eepp/system/cobjectloader.hpp index 990d35ad9..788727b02 100644 --- a/include/eepp/system/cobjectloader.hpp +++ b/include/eepp/system/cobjectloader.hpp @@ -3,6 +3,7 @@ #include #include +#include namespace EE { namespace System { diff --git a/include/eepp/system/tcontainer.hpp b/include/eepp/system/tcontainer.hpp index 61cbe5477..bf931d8b9 100644 --- a/include/eepp/system/tcontainer.hpp +++ b/include/eepp/system/tcontainer.hpp @@ -2,6 +2,7 @@ #define EE_SYSTEMTCONTAINER_HPP #include +#include namespace EE { namespace System { diff --git a/include/eepp/system/tresourcemanager.hpp b/include/eepp/system/tresourcemanager.hpp index b096684ac..5739ebaa5 100644 --- a/include/eepp/system/tresourcemanager.hpp +++ b/include/eepp/system/tresourcemanager.hpp @@ -2,6 +2,7 @@ #define EE_SYSTEMTRESOURCEMANAGER_HPP #include +#include namespace EE { namespace System { diff --git a/include/eepp/ui/cuimenu.hpp b/include/eepp/ui/cuimenu.hpp index 2a9414aba..c55751a3b 100644 --- a/include/eepp/ui/cuimenu.hpp +++ b/include/eepp/ui/cuimenu.hpp @@ -6,6 +6,7 @@ #include #include #include +#include namespace EE { namespace UI { diff --git a/include/eepp/ui/cuitabwidget.hpp b/include/eepp/ui/cuitabwidget.hpp index 051e0c9a7..2fbfde281 100644 --- a/include/eepp/ui/cuitabwidget.hpp +++ b/include/eepp/ui/cuitabwidget.hpp @@ -3,6 +3,7 @@ #include #include +#include namespace EE { namespace UI { diff --git a/include/eepp/utils/cinterpolation.hpp b/include/eepp/utils/cinterpolation.hpp index 8caf1ffd8..77fe181cb 100644 --- a/include/eepp/utils/cinterpolation.hpp +++ b/include/eepp/utils/cinterpolation.hpp @@ -2,6 +2,7 @@ #define EE_UTILSCINTERPOLATION_H #include +#include namespace EE { namespace Utils { diff --git a/include/eepp/utils/cwaypoints.hpp b/include/eepp/utils/cwaypoints.hpp index 99332fa8f..3fdb214db 100755 --- a/include/eepp/utils/cwaypoints.hpp +++ b/include/eepp/utils/cwaypoints.hpp @@ -3,6 +3,7 @@ #include #include +#include namespace EE { namespace Utils { diff --git a/include/eepp/utils/polygon2.hpp b/include/eepp/utils/polygon2.hpp index 6cd2a6c7b..299ea6709 100755 --- a/include/eepp/utils/polygon2.hpp +++ b/include/eepp/utils/polygon2.hpp @@ -4,6 +4,7 @@ #include #include #include +#include namespace EE { namespace Utils { diff --git a/include/eepp/utils/string.hpp b/include/eepp/utils/string.hpp index 2633660cb..19fd4bc50 100755 --- a/include/eepp/utils/string.hpp +++ b/include/eepp/utils/string.hpp @@ -2,6 +2,9 @@ #define EE_UTILSCSTRING_H #include +#include +#include +#include namespace EE { namespace Utils { diff --git a/include/eepp/utils/utils.hpp b/include/eepp/utils/utils.hpp index 12a585878..aec61725f 100755 --- a/include/eepp/utils/utils.hpp +++ b/include/eepp/utils/utils.hpp @@ -3,6 +3,7 @@ #include #include +#include namespace EE { namespace Utils { /** @return True if the file exists ( false if is a directory, to know if directory exists use IsDirectory ) */ diff --git a/include/eepp/window/ccursormanager.hpp b/include/eepp/window/ccursormanager.hpp index efecd2351..6da0925a5 100644 --- a/include/eepp/window/ccursormanager.hpp +++ b/include/eepp/window/ccursormanager.hpp @@ -12,6 +12,8 @@ using namespace EE::Graphics; #include using namespace EE::Window::Cursor; +#include + namespace EE { namespace Window { class EE_API cCursorManager { diff --git a/projects/linux/ee.creator.user b/projects/linux/ee.creator.user index 5d99383bf..e59e5ba24 100644 --- a/projects/linux/ee.creator.user +++ b/projects/linux/ee.creator.user @@ -1,6 +1,6 @@ - + ProjectExplorer.Project.ActiveTarget @@ -57,8 +57,8 @@ false - -j4 -e DEBUGBUILD=yes SHARED_BACKEND=no test - + -j4 -e DEBUGBUILD=yes SHARED_BACKEND=no BACKENDS_ALL=yes test + make true diff --git a/projects/linux/ee.files b/projects/linux/ee.files index 78721bab9..e363f21a8 100644 --- a/projects/linux/ee.files +++ b/projects/linux/ee.files @@ -526,8 +526,6 @@ ../../src/eepp/graphics/renderer/shaders/basegl3.vert ../../src/eepp/graphics/renderer/shaders/basegl3.frag ../../src/examples/external_shader/external_shader.cpp -../../Makefile.base -../../Makefile ../../src/eepp/helper/haikuttf/sophist.h ../../src/eepp/helper/haikuttf/hkmutex.hpp ../../src/eepp/helper/haikuttf/hkglyph.hpp @@ -539,12 +537,6 @@ ../../src/eepp/helper/haikuttf/hkglyph.cpp ../../src/eepp/helper/haikuttf/hkfontmanager.cpp ../../src/eepp/helper/haikuttf/hkfont.cpp -../../src/eepp/helper/SOIL/stbi_DDS_c.h -../../src/eepp/helper/SOIL/stb_image_write.c -../../src/eepp/helper/SOIL/stb_image.c -../../src/eepp/helper/SOIL/image_helper.c -../../src/eepp/helper/SOIL/image_DXT.c -../../src/eepp/helper/SOIL/SOIL.c ../../include/eepp/window.hpp ../../include/eepp/utils.hpp ../../include/eepp/ui.hpp diff --git a/projects/windows/ee.files b/projects/windows/ee.files index c8edd81bc..e363f21a8 100644 --- a/projects/windows/ee.files +++ b/projects/windows/ee.files @@ -126,17 +126,16 @@ ../../include/eepp/graphics/vbohelper.hpp ../../include/eepp/graphics/renders.hpp ../../include/eepp/graphics/pixelperfect.hpp -../../include/eepp/graphics/packerhelper.hpp ../../include/eepp/graphics/glhelper.hpp ../../include/eepp/graphics/fonthelper.hpp ../../include/eepp/graphics/cvertexbuffervbo.hpp ../../include/eepp/graphics/cvertexbufferogl.hpp -../../include/eepp/graphics/cvertexbuffermanager.hpp +../../src/eepp/graphics/cvertexbuffermanager.hpp ../../include/eepp/graphics/cvertexbuffer.hpp ../../include/eepp/graphics/cttffontloader.hpp ../../include/eepp/graphics/cttffont.hpp -../../include/eepp/graphics/ctexturepackertex.hpp -../../include/eepp/graphics/ctexturepackernode.hpp +../../src/eepp/graphics/ctexturepackertex.hpp +../../src/eepp/graphics/ctexturepackernode.hpp ../../include/eepp/graphics/ctexturepacker.hpp ../../include/eepp/graphics/ctextureloader.hpp ../../include/eepp/graphics/ctexturegrouploader.hpp @@ -159,9 +158,7 @@ ../../include/eepp/graphics/cimage.hpp ../../include/eepp/graphics/cglobalshapegroup.hpp ../../include/eepp/graphics/cglobalbatchrenderer.hpp -../../include/eepp/graphics/cframebufferpbuffer.hpp -../../include/eepp/graphics/cframebuffermanager.hpp -../../include/eepp/graphics/cframebufferfbo.hpp +../../src/eepp/graphics/cframebuffermanager.hpp ../../include/eepp/graphics/cframebuffer.hpp ../../include/eepp/graphics/cfontmanager.hpp ../../include/eepp/graphics/cfont.hpp @@ -378,7 +375,6 @@ ../../include/eepp/window/ccursormanager.hpp ../../include/eepp/window/ccursor.hpp ../../include/eepp/window/cclipboard.hpp -../../include/eepp/window/cbackend.hpp ../../include/eepp/window/base.hpp ../../src/eepp/window/inputhelper.cpp ../../src/eepp/window/cwindow.cpp @@ -514,9 +510,6 @@ ../../src/examples/empty_window/empty_window.cpp ../../src/test/eetest.hpp ../../src/test/eetest.cpp -../../src/eeiv/capp.hpp -../../src/eeiv/eeiv.cpp -../../src/eeiv/capp.cpp ../../src/eepp/graphics/renderer/shaders/primitive.vert ../../src/eepp/graphics/renderer/shaders/primitive.frag ../../src/eepp/graphics/renderer/shaders/pointsprite.vert @@ -533,3 +526,46 @@ ../../src/eepp/graphics/renderer/shaders/basegl3.vert ../../src/eepp/graphics/renderer/shaders/basegl3.frag ../../src/examples/external_shader/external_shader.cpp +../../src/eepp/helper/haikuttf/sophist.h +../../src/eepp/helper/haikuttf/hkmutex.hpp +../../src/eepp/helper/haikuttf/hkglyph.hpp +../../src/eepp/helper/haikuttf/hkfontmanager.hpp +../../src/eepp/helper/haikuttf/hkfont.hpp +../../src/eepp/helper/haikuttf/hkbase.hpp +../../src/eepp/helper/haikuttf/haikuttf.hpp +../../src/eepp/helper/haikuttf/hkmutex.cpp +../../src/eepp/helper/haikuttf/hkglyph.cpp +../../src/eepp/helper/haikuttf/hkfontmanager.cpp +../../src/eepp/helper/haikuttf/hkfont.cpp +../../include/eepp/window.hpp +../../include/eepp/utils.hpp +../../include/eepp/ui.hpp +../../include/eepp/system.hpp +../../include/eepp/physics.hpp +../../include/eepp/math.hpp +../../include/eepp/graphics.hpp +../../include/eepp/gaming.hpp +../../include/eepp/ee.hpp +../../include/eepp/declares.hpp +../../include/eepp/base.hpp +../../include/eepp/audio.hpp +../../src/eepp/window/backend/SFML/cwindowsfml.hpp +../../src/eepp/window/backend/SFML/cjoysticksfml.hpp +../../src/eepp/window/backend/SFML/cjoystickmanagersfml.hpp +../../src/eepp/window/backend/SFML/cinputsfml.hpp +../../src/eepp/window/backend/SFML/ccursorsfml.hpp +../../src/eepp/window/backend/SFML/ccursormanagersfml.hpp +../../src/eepp/window/backend/SFML/cclipboardsfml.hpp +../../src/eepp/window/backend/SFML/cbackendsfml.hpp +../../src/eepp/window/backend/SFML/cwindowsfml.cpp +../../src/eepp/window/backend/SFML/cjoysticksfml.cpp +../../src/eepp/window/backend/SFML/cjoystickmanagersfml.cpp +../../src/eepp/window/backend/SFML/cinputsfml.cpp +../../src/eepp/window/backend/SFML/ccursorsfml.cpp +../../src/eepp/window/backend/SFML/ccursormanagersfml.cpp +../../src/eepp/window/backend/SFML/cclipboardsfml.cpp +../../src/eepp/window/cbackend.hpp +../../src/eepp/graphics/cframebufferpbuffer.hpp +../../src/eepp/graphics/cframebufferfbo.hpp +../../src/eepp/graphics/renderer/rendererhelper.hpp +../../include/eepp/graphics/packerhelper.hpp diff --git a/src/eepp/audio/csoundbuffer.cpp b/src/eepp/audio/csoundbuffer.cpp index 1bd68b63f..0b527ed17 100755 --- a/src/eepp/audio/csoundbuffer.cpp +++ b/src/eepp/audio/csoundbuffer.cpp @@ -2,6 +2,7 @@ #include #include #include +#include namespace EE { namespace Audio { diff --git a/src/eepp/audio/openal.cpp b/src/eepp/audio/openal.cpp index c03178b0a..8ea1d1c57 100644 --- a/src/eepp/audio/openal.cpp +++ b/src/eepp/audio/openal.cpp @@ -1,5 +1,6 @@ #include #include +#include namespace EE { namespace Audio { diff --git a/src/eepp/base/debug.cpp b/src/eepp/base/debug.cpp index 1edd57ceb..5a43d258c 100644 --- a/src/eepp/base/debug.cpp +++ b/src/eepp/base/debug.cpp @@ -1,5 +1,8 @@ #include #include +#include +#include + using namespace EE::System; #ifdef EE_COMPILER_MSVC diff --git a/src/eepp/gaming/mapeditor/cmapeditor.cpp b/src/eepp/gaming/mapeditor/cmapeditor.cpp index ecbb98ffd..938ca8c51 100644 --- a/src/eepp/gaming/mapeditor/cmapeditor.cpp +++ b/src/eepp/gaming/mapeditor/cmapeditor.cpp @@ -25,6 +25,8 @@ #include #include +#include + using namespace EE::Graphics; namespace EE { namespace Gaming { namespace MapEditor { diff --git a/src/eepp/graphics/cconsole.cpp b/src/eepp/graphics/cconsole.cpp index e7bbc3bbb..728251d2b 100755 --- a/src/eepp/graphics/cconsole.cpp +++ b/src/eepp/graphics/cconsole.cpp @@ -4,6 +4,8 @@ #include #include #include +#include +#include using namespace EE::Window; diff --git a/src/eepp/graphics/ctexturefactory.cpp b/src/eepp/graphics/ctexturefactory.cpp index e2ad2a973..e0278e1e5 100755 --- a/src/eepp/graphics/ctexturefactory.cpp +++ b/src/eepp/graphics/ctexturefactory.cpp @@ -250,7 +250,7 @@ void cTextureFactory::SetPreBlendFunc( const EE_PRE_BLEND_FUNC& blend, bool forc GLi->BlendFunc(GL_DST_COLOR,GL_ZERO); break; case ALPHA_NONE: - // AVOID COMPILER WARNING + // Avoid compiler warning break; case ALPHA_CUSTOM: break; diff --git a/src/eepp/graphics/ctexturepacker.cpp b/src/eepp/graphics/ctexturepacker.cpp index b9d321dbc..d7d33d737 100644 --- a/src/eepp/graphics/ctexturepacker.cpp +++ b/src/eepp/graphics/ctexturepacker.cpp @@ -4,6 +4,7 @@ #include #include #include +#include namespace EE { namespace Graphics { diff --git a/src/eepp/graphics/renderer/rendererhelper.hpp b/src/eepp/graphics/renderer/rendererhelper.hpp index d267ccb0b..05bba7daa 100644 --- a/src/eepp/graphics/renderer/rendererhelper.hpp +++ b/src/eepp/graphics/renderer/rendererhelper.hpp @@ -5,6 +5,7 @@ #ifdef EE_GL3_ENABLED +#include #include namespace EE { namespace Graphics { namespace Private { diff --git a/include/eepp/helper/SOIL/SOIL.h b/src/eepp/helper/SOIL/SOIL.h similarity index 100% rename from include/eepp/helper/SOIL/SOIL.h rename to src/eepp/helper/SOIL/SOIL.h diff --git a/include/eepp/helper/SOIL/image_DXT.h b/src/eepp/helper/SOIL/image_DXT.h similarity index 100% rename from include/eepp/helper/SOIL/image_DXT.h rename to src/eepp/helper/SOIL/image_DXT.h diff --git a/include/eepp/helper/SOIL/image_helper.h b/src/eepp/helper/SOIL/image_helper.h similarity index 100% rename from include/eepp/helper/SOIL/image_helper.h rename to src/eepp/helper/SOIL/image_helper.h diff --git a/include/eepp/helper/SOIL/stb_image.h b/src/eepp/helper/SOIL/stb_image.h similarity index 100% rename from include/eepp/helper/SOIL/stb_image.h rename to src/eepp/helper/SOIL/stb_image.h diff --git a/include/eepp/helper/SOIL/stb_image_write.h b/src/eepp/helper/SOIL/stb_image_write.h similarity index 100% rename from include/eepp/helper/SOIL/stb_image_write.h rename to src/eepp/helper/SOIL/stb_image_write.h diff --git a/include/eepp/helper/SOIL/stbi_DDS.h b/src/eepp/helper/SOIL/stbi_DDS.h similarity index 100% rename from include/eepp/helper/SOIL/stbi_DDS.h rename to src/eepp/helper/SOIL/stbi_DDS.h diff --git a/src/eepp/physics/cphysicsmanager.cpp b/src/eepp/physics/cphysicsmanager.cpp index 8958de7b8..3db0d0d34 100644 --- a/src/eepp/physics/cphysicsmanager.cpp +++ b/src/eepp/physics/cphysicsmanager.cpp @@ -3,6 +3,7 @@ #include #include #include +#include CP_NAMESPACE_BEGIN diff --git a/src/eepp/system/cinifile.cpp b/src/eepp/system/cinifile.cpp index 076fe7f3b..067bccad7 100755 --- a/src/eepp/system/cinifile.cpp +++ b/src/eepp/system/cinifile.cpp @@ -3,6 +3,7 @@ #include #include #include +#include namespace EE { namespace System { diff --git a/src/eepp/system/clog.cpp b/src/eepp/system/clog.cpp index afa1fa82e..c1aa39a10 100755 --- a/src/eepp/system/clog.cpp +++ b/src/eepp/system/clog.cpp @@ -1,4 +1,5 @@ #include +#include namespace EE { namespace System { diff --git a/src/eepp/system/platform/posix/cthreadimpl.cpp b/src/eepp/system/platform/posix/cthreadimpl.cpp index 7fdda9739..437e1e9de 100644 --- a/src/eepp/system/platform/posix/cthreadimpl.cpp +++ b/src/eepp/system/platform/posix/cthreadimpl.cpp @@ -1,5 +1,6 @@ #include #include +#include namespace EE { namespace System { namespace Platform { diff --git a/src/eepp/system/platform/win/cthreadimpl.cpp b/src/eepp/system/platform/win/cthreadimpl.cpp index ca9a548b8..2c1daa0ee 100644 --- a/src/eepp/system/platform/win/cthreadimpl.cpp +++ b/src/eepp/system/platform/win/cthreadimpl.cpp @@ -1,5 +1,6 @@ #include #include +#include namespace EE { namespace System { namespace Platform { diff --git a/src/eepp/ui/cuicommondialog.cpp b/src/eepp/ui/cuicommondialog.cpp index e1403f28d..57fb166f5 100644 --- a/src/eepp/ui/cuicommondialog.cpp +++ b/src/eepp/ui/cuicommondialog.cpp @@ -2,6 +2,7 @@ #include #include #include +#include namespace EE { namespace UI { diff --git a/src/eepp/ui/cuimanager.cpp b/src/eepp/ui/cuimanager.cpp index cae3b8f31..6267fb613 100644 --- a/src/eepp/ui/cuimanager.cpp +++ b/src/eepp/ui/cuimanager.cpp @@ -1,5 +1,6 @@ #include #include +#include namespace EE { namespace UI { diff --git a/src/eepp/ui/tools/ctexturegroupeditor.cpp b/src/eepp/ui/tools/ctexturegroupeditor.cpp index 621b270da..bdd4ba9be 100644 --- a/src/eepp/ui/tools/ctexturegroupeditor.cpp +++ b/src/eepp/ui/tools/ctexturegroupeditor.cpp @@ -5,6 +5,7 @@ #include #include #include +#include namespace EE { namespace UI { namespace Tools { diff --git a/src/eepp/utils/string.cpp b/src/eepp/utils/string.cpp index a4aff6279..3dbe2309a 100644 --- a/src/eepp/utils/string.cpp +++ b/src/eepp/utils/string.cpp @@ -1,5 +1,7 @@ #include #include +#include +#include namespace EE { namespace Utils { diff --git a/src/eepp/utils/utils.cpp b/src/eepp/utils/utils.cpp index 7942b0697..98aba6720 100755 --- a/src/eepp/utils/utils.cpp +++ b/src/eepp/utils/utils.cpp @@ -6,6 +6,8 @@ using namespace EE::System; #include #if defined( EE_PLATFORM_POSIX ) + #include + #if EE_PLATFORM != EE_PLATFORM_ANDROID #include #else @@ -35,9 +37,6 @@ using namespace EE::System; #if EE_PLATFORM == EE_PLATFORM_WIN #include -#endif - -#if EE_PLATFORM == EE_PLATFORM_WIN #include #else #include @@ -51,7 +50,7 @@ using namespace EE::System; #endif #endif -static bool TickStarted = false; +namespace EE { namespace Utils { #if EE_PLATFORM == EE_PLATFORM_WIN @@ -215,10 +214,6 @@ static LARGE_INTEGER hires_ticks_per_second; #endif -#if defined( EE_PLATFORM_POSIX ) - #include -#endif - #ifdef EE_PLATFORM_POSIX #ifdef EE_HAVE_CLOCK_GETTIME @@ -229,8 +224,6 @@ static struct timeval start; #endif -namespace EE { namespace Utils { - std::string GetOSName() { #if defined( EE_PLATFORM_POSIX ) struct utsname os; @@ -269,23 +262,26 @@ bool FileExists( const std::string& Filepath ) { } static void eeStartTicks() { -#if EE_PLATFORM == EE_PLATFORM_WIN - QueryPerformanceFrequency(&hires_ticks_per_second); - QueryPerformanceCounter(&hires_start_ticks); -#else - #ifdef EE_HAVE_CLOCK_GETTIME - clock_gettime(CLOCK_MONOTONIC, &start); - #else - gettimeofday(&start, NULL); - #endif -#endif + static bool TickStarted = false; - TickStarted = true; + if ( !TickStarted ) { + #if EE_PLATFORM == EE_PLATFORM_WIN + QueryPerformanceFrequency(&hires_ticks_per_second); + QueryPerformanceCounter(&hires_start_ticks); + #else + #ifdef EE_HAVE_CLOCK_GETTIME + clock_gettime(CLOCK_MONOTONIC, &start); + #else + gettimeofday(&start, NULL); + #endif + #endif + + TickStarted = true; + } } Uint32 eeGetTicks() { - if ( !TickStarted ) - eeStartTicks(); + eeStartTicks(); #if EE_PLATFORM == EE_PLATFORM_WIN LARGE_INTEGER hires_now; diff --git a/src/eepp/window/backend/allegro5/cwindowal.cpp b/src/eepp/window/backend/allegro5/cwindowal.cpp index 4a9e28c01..8e35c7e0a 100644 --- a/src/eepp/window/backend/allegro5/cwindowal.cpp +++ b/src/eepp/window/backend/allegro5/cwindowal.cpp @@ -11,12 +11,25 @@ #include #if EE_PLATFORM == EE_PLATFORM_WIN -#include -#define WGL_NV_video_out + #include + #define WGL_NV_video_out #elif defined( EE_X11_PLATFORM ) + #include + #include +#endif -#include +#include #include +#include + +#include +#include +#include +#include + +namespace EE { namespace Window { namespace Backend { namespace Al { + +#if defined( EE_X11_PLATFORM ) struct ALLEGRO_SYSTEM_XGLX { @@ -61,7 +74,7 @@ struct ALLEGRO_SYSTEM_XGLX struct ALLEGRO_DISPLAY_XGLX { ALLEGRO_DISPLAY display; - Window window; + ::Window window; int xscreen; int adapter; GLXWindow glxwindow; @@ -81,6 +94,7 @@ struct ALLEGRO_DISPLAY_XGLX int x, y; bool mouse_warp; }; + static _AL_MUTEX * al_display_mutex = NULL; static void al_display_lock() { @@ -97,16 +111,6 @@ static void al_display_unlock() { #endif -#include -#include -#include - -#include -#include -#include - -namespace EE { namespace Window { namespace Backend { namespace Al { - cWindowAl::cWindowAl( WindowSettings Settings, ContextSettings Context ) : cWindow( Settings, Context, eeNew( cClipboardAl, ( this ) ), eeNew( cInputAl, ( this ) ), eeNew( cCursorManagerAl, ( this ) ) ), mDisplay( NULL ), diff --git a/src/examples/external_shader/external_shader.cpp b/src/examples/external_shader/external_shader.cpp index 224b18915..9fed085ac 100644 --- a/src/examples/external_shader/external_shader.cpp +++ b/src/examples/external_shader/external_shader.cpp @@ -1,6 +1,8 @@ #include /// This example is based on the WebGL demo from http://minimal.be/lab/fluGL/ +namespace Demo_ExternalShader { + Uint32 ParticlesNum = 30000; cWindow * win = NULL; cShaderProgram * ShaderProgram = NULL; @@ -76,6 +78,9 @@ void videoResize() { } } +} +using namespace Demo_ExternalShader; + EE_MAIN_FUNC int main (int argc, char * argv []) { win = cEngine::instance()->CreateWindow( WindowSettings( 960, 640, 32, WindowStyle::Default, "", "eepp - External Shaders" ), ContextSettings( true ) ); diff --git a/src/test/eetest.cpp b/src/test/eetest.cpp index 43f7def9e..3385ff276 100644 --- a/src/test/eetest.cpp +++ b/src/test/eetest.cpp @@ -1,6 +1,6 @@ #include "eetest.hpp" -namespace EE { namespace Demo { +namespace Demo_Test { void cEETest::Init() { EE = cEngine::instance(); @@ -1916,10 +1916,10 @@ void cEETest::End() { cEngine::DestroySingleton(); } -}} +} EE_MAIN_FUNC int main (int argc, char * argv []) { - EE::Demo::cEETest * Test = eeNew( EE::Demo::cEETest, () ); + Demo_Test::cEETest * Test = eeNew( Demo_Test::cEETest, () ); Test->Process(); diff --git a/src/test/eetest.hpp b/src/test/eetest.hpp index 594eb9eb1..42d04d5c3 100644 --- a/src/test/eetest.hpp +++ b/src/test/eetest.hpp @@ -3,7 +3,7 @@ #include -namespace EE { namespace Demo { +namespace Demo_Test { class cUITest : public cUIControlAnim { public: @@ -305,6 +305,6 @@ class cEETest : private cThread { void OnShowMenu( const cUIEvent * Event ); }; -}} +} #endif