Fixes #2529, guard SDL_d3math.* with the proper defines
authorGabriel Jacobo <gabomdq@gmail.com>
Sat, 10 May 2014 16:23:06 -0300
changeset 8764 3d5ef7548688
parent 8763 a8ef3ac69e3d
child 8765 cdf0aad10fea
Fixes #2529, guard SDL_d3math.* with the proper defines
src/render/SDL_d3dmath.c
src/render/SDL_d3dmath.h
--- a/src/render/SDL_d3dmath.c	Sat May 10 16:13:22 2014 -0300
+++ b/src/render/SDL_d3dmath.c	Sat May 10 16:23:06 2014 -0300
@@ -19,6 +19,8 @@
   3. This notice may not be removed or altered from any source distribution.
 */
 #include "../SDL_internal.h"
+
+#if (SDL_VIDEO_RENDER_D3D || SDL_VIDEO_RENDER_D3D11) && !SDL_RENDER_DISABLED
 #include "SDL_stdinc.h"
 
 #include "SDL_d3dmath.h"
@@ -126,6 +128,9 @@
     m._33 = 1.0f;
     m._44 = 1.0f;
     return m;
+
 }
 
+#endif /* (SDL_VIDEO_RENDER_D3D || SDL_VIDEO_RENDER_D3D11) && !SDL_RENDER_DISABLED */
+
 /* vi: set ts=4 sw=4 expandtab: */
--- a/src/render/SDL_d3dmath.h	Sat May 10 16:13:22 2014 -0300
+++ b/src/render/SDL_d3dmath.h	Sat May 10 16:23:06 2014 -0300
@@ -20,6 +20,7 @@
 */
 #include "../SDL_internal.h"
 
+#if (SDL_VIDEO_RENDER_D3D || SDL_VIDEO_RENDER_D3D11) && !SDL_RENDER_DISABLED
 
 /* Direct3D matrix math functions */
 
@@ -66,4 +67,6 @@
 Float4X4 MatrixRotationY(float r);
 Float4X4 MatrixRotationZ(float r);
 
+#endif /* (SDL_VIDEO_RENDER_D3D || SDL_VIDEO_RENDER_D3D11) && !SDL_RENDER_DISABLED */
+
 /* vi: set ts=4 sw=4 expandtab: */