refactored ocl/src/imgproc.cpp