mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-21 05:09:34 -06:00
cleanup + some eolz
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5842 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
@ -66,7 +66,7 @@ bool Initialize()
|
||||
return false;
|
||||
}
|
||||
|
||||
if (0 < numPlatforms)
|
||||
if (0 < numPlatforms)
|
||||
{
|
||||
cl_platform_id* platforms = new cl_platform_id[numPlatforms];
|
||||
err = clGetPlatformIDs(numPlatforms, platforms, NULL);
|
||||
@ -106,7 +106,7 @@ bool Initialize()
|
||||
return false;
|
||||
}
|
||||
|
||||
// Create a compute context
|
||||
// Create a compute context
|
||||
g_context = clCreateContext(cprops, 1, &device_id, NULL, NULL, &err);
|
||||
if (!g_context)
|
||||
{
|
||||
@ -176,8 +176,8 @@ cl_kernel CompileKernel(cl_program program, const char *Function)
|
||||
cl_kernel kernel = clCreateKernel(program, Function, &err);
|
||||
if (!kernel || err != CL_SUCCESS)
|
||||
{
|
||||
char buffer[1024];
|
||||
sprintf(buffer, "Failed to create compute kernel '%s' !", Function);
|
||||
char buffer[1024];
|
||||
sprintf(buffer, "Failed to create compute kernel '%s' !", Function);
|
||||
HandleCLError(err, buffer);
|
||||
return NULL;
|
||||
}
|
||||
@ -191,7 +191,7 @@ void Destroy()
|
||||
#if defined(HAVE_OPENCL) && HAVE_OPENCL
|
||||
if(!g_context)
|
||||
return;
|
||||
clReleaseCommandQueue(g_cmdq);
|
||||
clReleaseCommandQueue(g_cmdq);
|
||||
clReleaseContext(g_context);
|
||||
g_context = NULL;
|
||||
g_cmdq = NULL;
|
||||
|
Reference in New Issue
Block a user