Additions to section 5.8.1 –Creating Program Objects:
The built-in image read functions will perform
sRGB to linear RGB conversions if the image is
an sRGB image. Writing to sRGB images from a
kernel is an optional extension. The
cl_khr_srgb_image_writes
extension will be reported in the
CL_DEVICE_EXTENSIONS
string
if a device supports writing to sRGB images using
write_imagef.
clGetSupportedImageFormats
will return the supported sRGB images if
CL_MEM_READ_WRITE
or
CL_MEM_WRITE_ONLY
is specified in
flags
argument and the
device supports writing to an sRGB image. If
cl_khr_srgb_image_writes
is supported, the
built-in image write functions will perform
the linear to sRGB conversion.
Only the R, G and B components are converted from linear to sRGB and vice-versa. The alpha component is returned as is.