diff options
author | Rodeo <[email protected]> | 2013-10-11 13:50:31 +0000 |
---|---|---|
committer | Rodeo <[email protected]> | 2013-10-11 13:50:31 +0000 |
commit | e37de0578bba59362c27ad636d9bf20085a47388 (patch) | |
tree | 0fa9bc9c15469f81ca672b6f6cb9f4397b46cc68 /libhb | |
parent | 58bd6b80db26fc71a101c0dbdf4633deea5c0c34 (diff) |
hb_get_opencl_env: remove dead code.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@5832 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb')
-rw-r--r-- | libhb/openclwrapper.c | 39 |
1 files changed, 3 insertions, 36 deletions
diff --git a/libhb/openclwrapper.c b/libhb/openclwrapper.c index 9c45ea145..adc0f38b3 100644 --- a/libhb/openclwrapper.c +++ b/libhb/openclwrapper.c @@ -1075,41 +1075,8 @@ int hb_opencl_stats() */ int hb_get_opencl_env() { - int i = 0; - cl_int status; - cl_uint numDevices; - cl_device_id *devices; - - /*initialize devices, context, comand_queue*/ - status = hb_init_opencl_env( &gpu_env ); - if( status ) - return(1); - status = clGetContextInfo( gpu_env.context, - CL_CONTEXT_NUM_DEVICES, - sizeof(numDevices), - &numDevices, - NULL ); - if( status != CL_SUCCESS ) - return 0; - - devices = (cl_device_id*)malloc( sizeof(cl_device_id) * numDevices ); - if( devices == NULL ) - return 0; - - /* grab the handles to all of the devices in the context. */ - status = clGetContextInfo( gpu_env.context, - CL_CONTEXT_DEVICES, - sizeof(cl_device_id) * numDevices, - devices, - NULL ); - - if( devices != NULL ) - { - free( devices ); - devices = NULL; - } - - return status; + /* initialize devices, context, command_queue */ + return hb_init_opencl_env(&gpu_env); } /** @@ -1223,7 +1190,7 @@ void hb_opencl_info_print() version, NULL); hb_log("GPU #%d: %s %s", i + 1, vendor, name); - hb_log(" - OpenCL driver version: %s", version); + hb_log(" - driver version: %s", version); } } |