]> git.sesse.net Git - casparcg/commitdiff
2.0. - Changed from GLEE to GLEW which is more frequently updated with the latest...
authorRonag <Ronag@362d55ac-95cf-4e76-9f9a-cbaa9c17b72d>
Sun, 7 Aug 2011 11:10:02 +0000 (11:10 +0000)
committerRonag <Ronag@362d55ac-95cf-4e76-9f9a-cbaa9c17b72d>
Sun, 7 Aug 2011 11:10:02 +0000 (11:10 +0000)
     - Use GL_ARB_SYNC instead of FENCE_NV, fences now work on both NVIDIA and AMD.
     - Make fence optional, if fence is not supported, then run without.

git-svn-id: https://casparcg.svn.sourceforge.net/svnroot/casparcg/server/branches/2.0.0.2@1072 362d55ac-95cf-4e76-9f9a-cbaa9c17b72d

14 files changed:
common/common.vcxproj
common/gl/gl_check.cpp
common/stdafx.h
core/StdAfx.h
core/core.vcxproj
core/mixer/gpu/fence.cpp
core/mixer/gpu/fence.h
core/mixer/gpu/ogl_device.cpp
core/mixer/image/image_mixer.cpp
dlls/glew32.dll [new file with mode: 0644]
modules/ogl/consumer/ogl_consumer.cpp
modules/ogl/ogl.vcxproj
shell/main.cpp
shell/shell.vcxproj

index ca578fa75eddcda0c0ce6c204f1a170122ecb557..af6f26cbf862cf762537cf5eecfd9561b05992ad 100644 (file)
   </ImportGroup>\r
   <PropertyGroup Label="UserMacros" />\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">\r
-    <IncludePath>..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.6\include\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
-    <LibraryPath>..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\;$(LibraryPath)</LibraryPath>\r
+    <IncludePath>..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.6\include\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\include;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
+    <LibraryPath>..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\;$(LibraryPath)</LibraryPath>\r
     <OutDir>$(ProjectDir)bin\$(Configuration)\</OutDir>\r
     <IntDir>$(ProjectDir)tmp\$(Configuration)\</IntDir>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">\r
-    <IncludePath>..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.6\include\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
-    <LibraryPath>..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\;$(LibraryPath)</LibraryPath>\r
+    <IncludePath>..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.6\include\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\include;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
+    <LibraryPath>..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\;$(LibraryPath)</LibraryPath>\r
     <OutDir>$(ProjectDir)bin\$(Configuration)\</OutDir>\r
     <IntDir>$(ProjectDir)tmp\$(Configuration)\</IntDir>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">\r
-    <IncludePath>..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.6\include\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
-    <LibraryPath>..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\;$(LibraryPath)</LibraryPath>\r
+    <IncludePath>..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.6\include\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\include;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
+    <LibraryPath>..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\;$(LibraryPath)</LibraryPath>\r
     <OutDir>$(ProjectDir)bin\$(Configuration)\</OutDir>\r
     <IntDir>$(ProjectDir)tmp\$(Configuration)\</IntDir>\r
   </PropertyGroup>\r
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">\r
-    <IncludePath>..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.6\include\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
-    <LibraryPath>..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\;$(LibraryPath)</LibraryPath>\r
+    <IncludePath>..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.6\include\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\include;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
+    <LibraryPath>..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\;$(LibraryPath)</LibraryPath>\r
     <OutDir>$(ProjectDir)bin\$(Configuration)\</OutDir>\r
     <IntDir>$(ProjectDir)tmp\$(Configuration)\</IntDir>\r
   </PropertyGroup>\r
index 659c7adc1c00a8d1f874aba19b692e6161fc6194..b11619b1b65270244def68575ba01662febe27cb 100644 (file)
@@ -28,7 +28,7 @@
 \r
 #include "gl_check.h"\r
 \r
-#include <Glee.h>\r
+#include <GL/glew.h>\r
 \r
 #include "../exception/exceptions.h"\r
 #include "../log/log.h"\r
index a7e056e534dcd8a33884d24f7eed5db00d0ade7c..23b352731e4821a493e825a88111b938dcf2b412 100644 (file)
@@ -29,7 +29,7 @@
 #define WIN32_LEAN_AND_MEAN\r
 \r
 #include <windows.h>\r
-#include <Glee.h>\r
+#include <GL/glew.h>\r
 \r
 #include "compiler\vs\disable_silly_warnings.h"\r
 \r
index 92f08195a723d4b139a6f9103ad9b74e627ba05f..06862034e276594d802a653a32dbd51017f7b6cc 100644 (file)
@@ -32,7 +32,7 @@
 #define NOMINMAX\r
 \r
 #include <Windows.h>\r
-#include <GLee.h>\r
+#include <GL/glew.h>\r
 #include <SFML/Window.hpp>\r
 \r
 #include <algorithm>\r
index 7ea2c9a272d38c9e54327df9bd67dd06ef28a6a0..e0ef9ce4ffa4fcb0fdcb86086a6242ee760da49a 100644 (file)
     <IntDir Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">$(ProjectDir)tmp\$(Configuration)\</IntDir>\r
     <IncludePath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\;..\dependencies\boost_1_44_0\;..\dependencies\tbb\include\;..\dependencies\SFML-1.6\include;..\dependencies\GLee5_4;$(IncludePath)</IncludePath>\r
     <IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\;..\dependencies\boost_1_44_0\;..\dependencies\tbb\include\;..\dependencies\SFML-1.6\include;..\dependencies\GLee5_4;$(IncludePath)</IncludePath>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\;..\dependencies\boost_1_44_0\;..\dependencies\tbb\include\;..\dependencies\SFML-1.6\include;..\dependencies\GLee5_4;$(IncludePath)</IncludePath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\;..\dependencies\boost_1_44_0\;..\dependencies\tbb\include\;..\dependencies\SFML-1.6\include;..\dependencies\glew-1.6.0\include;$(IncludePath)</IncludePath>\r
     <IncludePath Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">..\;..\dependencies\boost_1_44_0\;..\dependencies\tbb\include\;..\dependencies\SFML-1.6\include;..\dependencies\GLee5_4;$(IncludePath)</IncludePath>\r
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
-    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
+    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.6\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
     <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(ProjectDir)bin\$(Configuration)\</OutDir>\r
     <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)bin\$(Configuration)\</OutDir>\r
index fca4a608b56bed9d1de16bccb252cfe53151fa88..3c29d4fa46cc8ba2e59cd55e28d764126fde5e6c 100644 (file)
@@ -7,43 +7,71 @@
 #include <common/gl/gl_check.h>\r
 \r
 namespace caspar { namespace core {\r
-       \r
-fence::fence() : id_(0){}\r
 \r
-fence::~fence()\r
+struct fence::implementation\r
 {\r
-       if(id_)\r
-               glDeleteFencesNV(1, &id_);\r
+       GLsync sync_;\r
+\r
+       implementation() : sync_(0){}\r
+       ~implementation(){glDeleteSync(sync_);}\r
+               \r
+       void set()\r
+       {\r
+               glDeleteSync(sync_);\r
+               sync_ = glFenceSync(GL_SYNC_GPU_COMMANDS_COMPLETE, 0);\r
+       }\r
+\r
+       bool ready() const\r
+       {\r
+               GLsizei length = 0;\r
+               int values[] = {0};\r
+\r
+               GL(glGetSynciv(sync_, GL_SYNC_STATUS, 1, &length, values));\r
+\r
+               return sync_ ? values[0] == GL_SIGNALED : true;\r
+       }\r
+\r
+       void wait(ogl_device& ogl)\r
+       {       \r
+               int delay = 0;\r
+               if(!ogl.invoke([this]{return ready();}, high_priority))\r
+               {\r
+                       while(!ogl.invoke([this]{return ready();}, normal_priority))\r
+                       {\r
+                               delay += 3;\r
+                               Sleep(3);\r
+                       }\r
+               }\r
+\r
+               if(delay > 0)\r
+                       CASPAR_LOG(warning) << L"[ogl_device] Performance warning. GPU was not ready during requested host read-back. Delayed by atleast: " << delay << L" ms.";\r
+       }\r
+};\r
+       \r
+fence::fence() \r
+{\r
+       if(GLEW_ARB_sync)\r
+               impl_.reset(new implementation());\r
+       else\r
+               CASPAR_LOG(warning) << "GL_SYNC not supported, running without fences. This might cause performance degradation when running multiple channels.";\r
+\r
 }\r
 \r
-void fence::set()\r
+void fence::set() \r
 {\r
-       if(id_)\r
-               glDeleteFencesNV(1, &id_);\r
-                       \r
-       GL(glGenFencesNV(1, &id_));\r
-       GL(glSetFenceNV(id_, GL_ALL_COMPLETED_NV));\r
+       if(impl_)\r
+               impl_->set();\r
 }\r
 \r
-bool fence::ready() const\r
+bool fence::ready() const \r
 {\r
-       return id_ ? GL2(glTestFenceNV(id_)) != GL_FALSE : true;\r
+       return impl_ ? impl_->ready() : true;\r
 }\r
 \r
 void fence::wait(ogl_device& ogl)\r
-{      \r
-       int delay = 0;\r
-       if(!ogl.invoke([this]{return ready();}, high_priority))\r
-       {\r
-               while(!ogl.invoke([this]{return ready();}, normal_priority))\r
-               {\r
-                       delay += 3;\r
-                       Sleep(3);\r
-               }\r
-       }\r
-\r
-       if(delay > 0)\r
-               CASPAR_LOG(warning) << L"[ogl_device] Performance warning. GPU was not ready during requested host read-back. Delayed by atleast: " << delay << L" ms.";\r
+{\r
+       if(impl_)\r
+               impl_->wait(ogl);\r
 }\r
 \r
 }}
\ No newline at end of file
index 911159196a29596a49c9f905a2969e0ffadc6ff8..5a142160d4123518fa1b151d0f6810542d664d1e 100644 (file)
@@ -1,18 +1,21 @@
 #pragma once\r
 \r
+#include <memory>\r
+\r
 namespace caspar { namespace core {\r
        \r
 class ogl_device;\r
 \r
 class fence\r
 {\r
-       unsigned int id_;\r
 public:\r
        fence();\r
-       ~fence();\r
        void set();\r
        bool ready() const;\r
        void wait(ogl_device& ogl);\r
+private:\r
+       struct implementation;\r
+       std::shared_ptr<implementation> impl_;\r
 };\r
 \r
 }}\r
index 7cbe5a9ed7a7f46952fa947f0edbe267d21c815e..1cafb65c1716330d50b1f2545bc8ac0455dd778b 100644 (file)
@@ -34,7 +34,13 @@ ogl_device::ogl_device() : executor_(L"ogl_device")
        {\r
                context_.reset(new sf::Context());\r
                context_->SetActive(true);\r
-                                               \r
+               \r
+               if (glewInit() != GLEW_OK)\r
+                       BOOST_THROW_EXCEPTION(gl::ogl_exception() << msg_info("Failed to initialize GLEW."));\r
+                               \r
+               if(!GLEW_VERSION_3_2)\r
+                       CASPAR_LOG(warning) << "Missing OpenGL 3.2 support.";\r
+       \r
                GL(glGenFramebuffers(1, &fbo_));                \r
                GL(glBindFramebuffer(GL_FRAMEBUFFER_EXT, fbo_));\r
                GL(glReadBuffer(GL_COLOR_ATTACHMENT0_EXT));\r
index 32eab2a28fd16a857fef94dfdcb3ff7ea075480e..edf7d9bf16cf1250535a8c3db14cd3b504dc5114 100644 (file)
@@ -72,12 +72,6 @@ public:
                , mode_stack_(1, video_mode::progressive)\r
        {\r
                initialize_buffers();\r
-\r
-               channel_.ogl().invoke([=]\r
-               {\r
-                       if(!GLEE_VERSION_3_0)\r
-                               CASPAR_LOG(warning) << "Missing OpenGL 3.0 support.";//BOOST_THROW_EXCEPTION(not_supported() << msg_info("Missing OpenGL 3.0 support."));\r
-               });\r
        }\r
 \r
        ~implementation()\r
diff --git a/dlls/glew32.dll b/dlls/glew32.dll
new file mode 100644 (file)
index 0000000..7f55467
Binary files /dev/null and b/dlls/glew32.dll differ
index f36e4808927d283562a38bc5eaf5fc68986ac24e..35178486a12ac47a8b687cd4eac3b587aa9f954f 100644 (file)
@@ -21,7 +21,7 @@
 #define NOMINMAX\r
 \r
 #include <windows.h>\r
-#include <Glee.h>\r
+#include <GL/glew.h>\r
 #include <SFML/Window.hpp>\r
 \r
 #include "ogl_consumer.h"\r
@@ -144,7 +144,7 @@ public:
 #endif         \r
                executor_.invoke([=]\r
                {\r
-                       if(!GLEE_VERSION_2_1)\r
+                       if(!GLEW_VERSION_2_1)\r
                                BOOST_THROW_EXCEPTION(not_supported() << msg_info("Missing OpenGL 2.1 support."));\r
 \r
                        window_.Create(sf::VideoMode(screen_width_, screen_height_, 32), narrow(print()), windowed_ ? sf::Style::Resize : sf::Style::Fullscreen);\r
index b049d5fb16d1d9f40e1527aa3b8e9281c504ea6c..9570b7045a513d5fc253871ce65d2d8951b78f49 100644 (file)
     <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(ProjectDir)tmp\$(Configuration)\</IntDir>\r
     <IntDir Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">$(ProjectDir)tmp\$(Configuration)\</IntDir>\r
     <IntDir Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">$(ProjectDir)tmp\$(Configuration)\</IntDir>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\..\;..\..\dependencies\boost_1_44_0\;..\..\dependencies\GLee5_4\;..\..\dependencies\tbb\include\;..\..\dependencies\SFML-1.6\include;$(IncludePath)</IncludePath>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\..\;..\..\dependencies\boost_1_44_0\;..\..\dependencies\GLee5_4\;..\..\dependencies\tbb\include\;..\..\dependencies\SFML-1.6\include;$(IncludePath)</IncludePath>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\..\;..\..\dependencies\boost_1_44_0\;..\..\dependencies\GLee5_4\;..\..\dependencies\tbb\include\;..\..\dependencies\SFML-1.6\include;$(IncludePath)</IncludePath>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">..\..\;..\..\dependencies\boost_1_44_0\;..\..\dependencies\GLee5_4\;..\..\dependencies\tbb\include\;..\..\dependencies\SFML-1.6\include;$(IncludePath)</IncludePath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\..\;..\..\dependencies\boost_1_44_0\;..\..\dependencies\glew-1.6.0\include;..\..\dependencies\tbb\include\;..\..\dependencies\SFML-1.6\include;$(IncludePath)</IncludePath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\..\;..\..\dependencies\boost_1_44_0\;..\..\dependencies\glew-1.6.0\include;..\..\dependencies\tbb\include\;..\..\dependencies\SFML-1.6\include;$(IncludePath)</IncludePath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\..\;..\..\dependencies\boost_1_44_0\;..\..\dependencies\glew-1.6.0\include;..\..\dependencies\tbb\include\;..\..\dependencies\SFML-1.6\include;$(IncludePath)</IncludePath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">..\..\;..\..\dependencies\boost_1_44_0\;..\..\dependencies\glew-1.6.0\include;..\..\dependencies\tbb\include\;..\..\dependencies\SFML-1.6\include;$(IncludePath)</IncludePath>\r
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\..\dependencies\boost_1_44_0\stage\lib\;..\..\dependencies\ffmpeg 0.8\lib\;..\..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\..\dependencies\boost_1_44_0\stage\lib\;..\..\dependencies\ffmpeg 0.8\lib\;..\..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
     <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\..\dependencies\boost_1_44_0\stage\lib\;..\..\dependencies\ffmpeg 0.8\lib\;..\..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
index d6404c0f9aba6bd1fe8255cd3f7a903eaddf3d40..322877da3cdbd38781ed6bca0d047c161d5f463c 100644 (file)
@@ -37,6 +37,8 @@
 #include <windows.h>\r
 #include <atlbase.h>\r
 \r
+#include <GL/glew.h>\r
+\r
 #include <core/mixer/gpu/ogl_device.h>\r
 \r
 #include <protocol/amcp/AMCPProtocolStrategy.h>\r
index d1ab88d27a96459035d1fc417b5be680bbc5691e..4b1a152a5473da786ba86caa90f7609914edf1e0 100644 (file)
     <IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)tmp\$(Configuration)\</IntDir>\r
     <IntDir Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">$(SolutionDir)tmp\$(Configuration)\</IntDir>\r
     <IntDir Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">$(SolutionDir)tmp\$(Configuration)\</IntDir>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.8\include\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.8\include\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.8\include\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
-    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.8\include\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
-    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">C:\Program\Microsoft DirectX SDK (June 2010)\Lib\x86;..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.8\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
-    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">C:\Program\Microsoft DirectX SDK (June 2010)\Lib\x86;..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.8\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
-    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">C:\Program\Microsoft DirectX SDK (June 2010)\Lib\x86;..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.8\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
-    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">C:\Program\Microsoft DirectX SDK (June 2010)\Lib\x86;..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.8\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\GLee5_4\;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.8\include\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\include;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.8\include\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\include;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.8\include\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\include;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
+    <IncludePath Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">..\dependencies\BluefishSDK_V5_8_0_31\Inc\;..\dependencies\boost_1_44_0\;..\dependencies\ffmpeg 0.8\include\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\include;..\dependencies\SFML-1.6\include\;..\dependencies\tbb\include\;$(IncludePath)</IncludePath>\r
+    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">C:\Program\Microsoft DirectX SDK (June 2010)\Lib\x86;..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.8\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
+    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">C:\Program\Microsoft DirectX SDK (June 2010)\Lib\x86;..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.8\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
+    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">C:\Program\Microsoft DirectX SDK (June 2010)\Lib\x86;..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.8\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
+    <LibraryPath Condition="'$(Configuration)|$(Platform)'=='Develop|Win32'">C:\Program\Microsoft DirectX SDK (June 2010)\Lib\x86;..\dependencies\BluefishSDK_V5_8_0_31\Lib\;..\dependencies\boost_1_44_0\stage\lib\;..\dependencies\ffmpeg 0.8\lib\;..\dependencies\FreeImage\Dist\;..\dependencies\glew-1.6.0\lib;..\dependencies\SFML-1.6\lib\;..\dependencies\tbb\lib\ia32\vc10\;$(LibraryPath)</LibraryPath>\r
     <OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)bin\$(Configuration)\</OutDir>\r
     <OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)bin\$(Configuration)\</OutDir>\r
     <OutDir Condition="'$(Configuration)|$(Platform)'=='Profile|Win32'">$(SolutionDir)bin\$(Configuration)\</OutDir>\r
       <ForcedIncludeFiles>common/compiler/vs/disable_silly_warnings.h</ForcedIncludeFiles>\r
     </ClCompile>\r
     <Link>\r
-      <AdditionalDependencies>sfml-system-d.lib;sfml-audio-d.lib;sfml-window-d.lib;sfml-graphics-d.lib;OpenGL32.lib;FreeImage.lib;Winmm.lib;Ws2_32.lib;avformat.lib;avcodec.lib;avutil.lib;avfilter.lib;swscale.lib;tbb.lib;Glee.lib</AdditionalDependencies>\r
+      <AdditionalDependencies>sfml-system-d.lib;sfml-audio-d.lib;sfml-window-d.lib;sfml-graphics-d.lib;OpenGL32.lib;FreeImage.lib;Winmm.lib;Ws2_32.lib;avformat.lib;avcodec.lib;avutil.lib;avfilter.lib;swscale.lib;tbb.lib;glew32.lib</AdditionalDependencies>\r
       <Version>\r
       </Version>\r
       <AdditionalLibraryDirectories>%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
@@ -231,7 +231,7 @@ copy "$(ProjectDir)casparcg.config" "$(OutDir)"</Command>
       </Command>\r
     </PreLinkEvent>\r
     <Link>\r
-      <AdditionalDependencies>sfml-system.lib;sfml-audio.lib;sfml-window.lib;sfml-graphics.lib;OpenGL32.lib;FreeImage.lib;Winmm.lib;Ws2_32.lib;avformat.lib;avcodec.lib;avutil.lib;avfilter.lib;swscale.lib;tbb.lib;Glee.lib</AdditionalDependencies>\r
+      <AdditionalDependencies>sfml-system.lib;sfml-audio.lib;sfml-window.lib;sfml-graphics.lib;OpenGL32.lib;FreeImage.lib;Winmm.lib;Ws2_32.lib;avformat.lib;avcodec.lib;avutil.lib;avfilter.lib;swscale.lib;tbb.lib;glew32.lib</AdditionalDependencies>\r
       <Version>\r
       </Version>\r
       <AdditionalLibraryDirectories>%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
@@ -286,7 +286,7 @@ copy "$(ProjectDir)casparcg.config" "$(OutDir)"</Command>
       </Command>\r
     </PreLinkEvent>\r
     <Link>\r
-      <AdditionalDependencies>sfml-system.lib;sfml-audio.lib;sfml-window.lib;sfml-graphics.lib;OpenGL32.lib;FreeImage.lib;Winmm.lib;Ws2_32.lib;avformat.lib;avcodec.lib;avutil.lib;avfilter.lib;swscale.lib;tbb.lib;Glee.lib</AdditionalDependencies>\r
+      <AdditionalDependencies>sfml-system.lib;sfml-audio.lib;sfml-window.lib;sfml-graphics.lib;OpenGL32.lib;FreeImage.lib;Winmm.lib;Ws2_32.lib;avformat.lib;avcodec.lib;avutil.lib;avfilter.lib;swscale.lib;tbb.lib;glew32.lib</AdditionalDependencies>\r
       <Version>\r
       </Version>\r
       <AdditionalLibraryDirectories>%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r
@@ -341,7 +341,7 @@ copy "$(ProjectDir)casparcg.config" "$(OutDir)"</Command>
       </Command>\r
     </PreLinkEvent>\r
     <Link>\r
-      <AdditionalDependencies>sfml-system.lib;sfml-audio.lib;sfml-window.lib;sfml-graphics.lib;OpenGL32.lib;FreeImage.lib;Winmm.lib;Ws2_32.lib;avformat.lib;avcodec.lib;avutil.lib;avfilter.lib;swscale.lib;tbb.lib;Glee.lib</AdditionalDependencies>\r
+      <AdditionalDependencies>sfml-system.lib;sfml-audio.lib;sfml-window.lib;sfml-graphics.lib;OpenGL32.lib;FreeImage.lib;Winmm.lib;Ws2_32.lib;avformat.lib;avcodec.lib;avutil.lib;avfilter.lib;swscale.lib;tbb.lib;glew32.lib</AdditionalDependencies>\r
       <Version>\r
       </Version>\r
       <AdditionalLibraryDirectories>%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>\r