protected static long createContextFromType(CLPlatform platform, CLErrorHandler handler, NativeSizeBuffer properties, long deviceType) {
IntBuffer status = newDirectIntBuffer(1);
CLContextBinding cl = platform.getContextBinding();
long context = cl.clCreateContextFromType(properties, deviceType, handler, status);
checkForError(status.get(), "can not create CL context");
return context;
}