Initialize OpenCL context at the end of getDevice call.

Added for better compatibility with the current samples/test cases.
User now will be able to initialize OpenCL context explicitly with
ocl::getDevice api.
This may be obsoleted in future releases.
pull/939/head
peng xiao 12 years ago
parent 37091b086c
commit 97b86aa259
  1. 4
      modules/ocl/src/initialization.cpp

@ -333,6 +333,10 @@ namespace cv
oclinfo.push_back(ocltmpinfo);
}
}
if(devcienums > 0)
{
setDevice(oclinfo[0]);
}
return devcienums;
}

Loading…
Cancel
Save