summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/Src/OpenCL/OCLTextureDecoder.cpp
diff options
context:
space:
mode:
authorOrphis <orphiss@gmail.com>2010-06-29 02:23:09 +0000
committerOrphis <orphiss@gmail.com>2010-06-29 02:23:09 +0000
commit685bae34e511aa2632807c7e7ae6bfd37b4c60d8 (patch)
tree9c3e84b5780092315513eaff02fabb41ea64de48 /Source/Core/VideoCommon/Src/OpenCL/OCLTextureDecoder.cpp
parent374999d750dc91838aea9feedf8b28871d66623f (diff)
Dynamically load OpenCL on Windows with CLRun. There shouldn't be the need to make a separate build now or download a big SDK to link Dolphin.
If compilation fails, rebuild the whole solution as Visual Studio struggles with the not so complex project dependencies. ATI users still need to install the Stream SDK as it's the only way to have an OpenCL driver. NVidia users just have to install a recent driver (version 197 is tested and working). git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5808 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core/VideoCommon/Src/OpenCL/OCLTextureDecoder.cpp')
-rw-r--r--Source/Core/VideoCommon/Src/OpenCL/OCLTextureDecoder.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/Source/Core/VideoCommon/Src/OpenCL/OCLTextureDecoder.cpp b/Source/Core/VideoCommon/Src/OpenCL/OCLTextureDecoder.cpp
index 2cb9a13d22..b38a2b8f56 100644
--- a/Source/Core/VideoCommon/Src/OpenCL/OCLTextureDecoder.cpp
+++ b/Source/Core/VideoCommon/Src/OpenCL/OCLTextureDecoder.cpp
@@ -152,7 +152,7 @@ PC_TexFormat TexDecoder_Decode_OpenCL(u8 *dst, const u8 *src, int width, int hei
#if defined(HAVE_OPENCL) && HAVE_OPENCL
cl_int err;
sDecoderParameter& decoder = rgba ? g_DecodeParametersRGBA[texformat] : g_DecodeParametersNative[texformat];
- if(!decoder.name || !decoder.kernel || decoder.format == PC_TEX_FMT_NONE)
+ if(!g_Inited || !decoder.name || !decoder.kernel || decoder.format == PC_TEX_FMT_NONE)
return PC_TEX_FMT_NONE;
#ifdef DEBUG_OPENCL
@@ -193,7 +193,5 @@ PC_TexFormat TexDecoder_Decode_OpenCL(u8 *dst, const u8 *src, int width, int hei
#else
return PC_TEX_FMT_NONE;
#endif
-
- return PC_TEX_FMT_NONE;
}