Fix -Wundef warnings due to use of unguarded SDL_VIDEO_RENDER_D3D

This commit is contained in:
Anonymous Maarten committed 2023-03-28 19:29:43 +02:00
1 parent ed7a589334
commit e7b67b346f
5 files changed
+7 -7

No files matched your search

+1 -1
View File
@@ -20,7 +20,7 @@
*/ */
#include "SDL_internal.h" #include "SDL_internal.h"
#if (SDL_VIDEO_RENDER_D3D || SDL_VIDEO_RENDER_D3D11 || SDL_VIDEO_RENDER_D3D12) && !SDL_RENDER_DISABLED #if (defined(SDL_VIDEO_RENDER_D3D) || SDL_VIDEO_RENDER_D3D11 || SDL_VIDEO_RENDER_D3D12) && !SDL_RENDER_DISABLED
#include "SDL_d3dmath.h" #include "SDL_d3dmath.h"
+1 -1
View File
@@ -20,7 +20,7 @@
*/ */
#include "SDL_internal.h" #include "SDL_internal.h"
#if (SDL_VIDEO_RENDER_D3D || SDL_VIDEO_RENDER_D3D11 || SDL_VIDEO_RENDER_D3D12) && !SDL_RENDER_DISABLED #if (defined(SDL_VIDEO_RENDER_D3D) || SDL_VIDEO_RENDER_D3D11 || SDL_VIDEO_RENDER_D3D12) && !SDL_RENDER_DISABLED
/* Set up for C function definitions, even when using C++ */ /* Set up for C function definitions, even when using C++ */
#ifdef __cplusplus #ifdef __cplusplus
+1 -1
View File
@@ -95,7 +95,7 @@ static const SDL_RenderDriver *render_drivers[] = {
#if SDL_VIDEO_RENDER_D3D11 #if SDL_VIDEO_RENDER_D3D11
&D3D11_RenderDriver, &D3D11_RenderDriver,
#endif #endif
#if SDL_VIDEO_RENDER_D3D #ifdef SDL_VIDEO_RENDER_D3D
&D3D_RenderDriver, &D3D_RenderDriver,
#endif #endif
#if SDL_VIDEO_RENDER_METAL #if SDL_VIDEO_RENDER_METAL
+3 -3
View File
@@ -20,7 +20,7 @@
*/ */
#include "SDL_internal.h" #include "SDL_internal.h"
#if SDL_VIDEO_RENDER_D3D && !SDL_RENDER_DISABLED #if defined(SDL_VIDEO_RENDER_D3D) && !SDL_RENDER_DISABLED
#include "../../core/windows/SDL_windows.h" #include "../../core/windows/SDL_windows.h"
@@ -30,7 +30,7 @@
#include <SDL3/SDL_syswm.h> #include <SDL3/SDL_syswm.h>
#if SDL_VIDEO_RENDER_D3D #ifdef SDL_VIDEO_RENDER_D3D
#define D3D_DEBUG_INFO #define D3D_DEBUG_INFO
#include <d3d9.h> #include <d3d9.h>
#endif #endif
@@ -1735,7 +1735,7 @@ SDL_GetRenderD3D9Device(SDL_Renderer *renderer)
{ {
IDirect3DDevice9 *device = NULL; IDirect3DDevice9 *device = NULL;
#if SDL_VIDEO_RENDER_D3D && !SDL_RENDER_DISABLED #if defined(SDL_VIDEO_RENDER_D3D) && !SDL_RENDER_DISABLED
D3D_RenderData *data = (D3D_RenderData *)renderer->driverdata; D3D_RenderData *data = (D3D_RenderData *)renderer->driverdata;
/* Make sure that this is a D3D renderer */ /* Make sure that this is a D3D renderer */
+1 -1
View File
@@ -20,7 +20,7 @@
*/ */
#include "SDL_internal.h" #include "SDL_internal.h"
#if SDL_VIDEO_RENDER_D3D && !SDL_RENDER_DISABLED #if defined(SDL_VIDEO_RENDER_D3D) && !SDL_RENDER_DISABLED
#include "../../core/windows/SDL_windows.h" #include "../../core/windows/SDL_windows.h"