Add a function to query ocl device info

Currently the function only supports wavefront size query
This commit is contained in:
peng xiao
2013-03-26 15:36:49 +08:00
parent f7b40cdc63
commit 0c19a07bf4
2 changed files with 50 additions and 0 deletions

View File

@@ -123,6 +123,16 @@ namespace cv
// returns whether the current context supports image2d_t format or not
bool CV_EXPORTS support_image2d(Context *clCxt = Context::getContext());
// the enums are used to query device information
// currently only support wavefront size queries
enum DEVICE_INFO
{
WAVEFRONT_SIZE, //in AMD speak
WARP_SIZE = WAVEFRONT_SIZE //in nvidia speak
};
//info should have been pre-allocated
void CV_EXPORTS queryDeviceInfo(DEVICE_INFO info_type, void* info);
}//namespace ocl
}//namespace cv