Skip to content

Commit 20ccbd0

Browse files
committed
clarify valid image dimensions
1 parent 5526b28 commit 20ccbd0

1 file changed

Lines changed: 25 additions & 18 deletions

File tree

api/opencl_runtime_layer.asciidoc

Lines changed: 25 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2786,28 +2786,35 @@ include::{generated}/api/structs/cl_image_desc.txt[]
27862786
{CL_MEM_OBJECT_IMAGE1D_ARRAY}, {CL_MEM_OBJECT_IMAGE2D},
27872787
{CL_MEM_OBJECT_IMAGE2D_ARRAY}, or {CL_MEM_OBJECT_IMAGE3D}.
27882788
* _image_width_ is the width of the image in pixels.
2789-
For a 2D image and image array, the image width must be a value {geq} 1 and
2790-
{leq} {CL_DEVICE_IMAGE2D_MAX_WIDTH}.
2791-
For a 3D image, the image width must be a value {geq} 1 and {leq}
2792-
{CL_DEVICE_IMAGE3D_MAX_WIDTH}.
2793-
For a 1D image buffer, the image width must be a value {geq} 1 and {leq}
2794-
{CL_DEVICE_IMAGE_MAX_BUFFER_SIZE}.
2795-
For a 1D image and 1D image array, the image width must be a value {geq} 1
2796-
and {leq} {CL_DEVICE_IMAGE2D_MAX_WIDTH}.
2789+
For a 1D image, 1D image array, 2D image, or 2D image array, the image width
2790+
must be greater than or equal to one and less than or equal to the
2791+
value returned for {CL_DEVICE_IMAGE2D_MAX_WIDTH} for all devices in the
2792+
context.
2793+
For a 3D image, the image width must be greater than or equal to one and
2794+
less than or equal to the value returned for {CL_DEVICE_IMAGE3D_MAX_WIDTH}
2795+
for all devices in the context.
2796+
For a 1D image buffer, the image width must be greater than or equal
2797+
to one and less than or equal to the value returned for
2798+
{CL_DEVICE_IMAGE_MAX_BUFFER_SIZE} for all devices in the context.
27972799
* _image_height_ is the height of the image in pixels.
2798-
This is only used if the image is a 2D or 3D image, or a 2D image array.
2799-
For a 2D image or image array, the image height must be a value {geq} 1 and
2800-
{leq} {CL_DEVICE_IMAGE2D_MAX_HEIGHT}.
2801-
For a 3D image, the image height must be a value {geq} 1 and {leq}
2802-
{CL_DEVICE_IMAGE3D_MAX_HEIGHT}.
2800+
It is only used if the image is a 2D image, 2D image array, or 3D image.
2801+
For a 2D image or 2D image array, the image height must greater than or
2802+
equal to one and less than or equal to the value returned for
2803+
{CL_DEVICE_IMAGE2D_MAX_HEIGHT} for all devices in the context.
2804+
For a 3D image, the image height must be greater than or equal to one and
2805+
less than or equal to the value returned for {CL_DEVICE_IMAGE3D_MAX_HEIGHT}
2806+
for all devices in the context.
28032807
* _image_depth_ is the depth of the image in pixels.
2804-
This is only used if the image is a 3D image and must be a value {geq} 1 and
2805-
{leq} {CL_DEVICE_IMAGE3D_MAX_DEPTH}.
2808+
It is only used if the image is a 3D image.
2809+
For a 3D image, the image depth must be greater than or equal to one and
2810+
less than or equal to the value returned for {CL_DEVICE_IMAGE3D_MAX_DEPTH}
2811+
for all devices in the context.
28062812
* _image_array_size_ footnote:[{fn-image-array-performance}] is the number of
28072813
images in the image array.
2808-
This is only used if the image is a 1D or 2D image array.
2809-
The values for `image_array_size`, if specified, must be a value {geq} 1 and
2810-
{leq} {CL_DEVICE_IMAGE_MAX_ARRAY_SIZE}.
2814+
It is only used if the image is a 1D image array or 2D image array.
2815+
For a 1D image array or 2D image array, the image array size must be
2816+
greater than or equal to one and less than or equal to the value returned
2817+
for {CL_DEVICE_IMAGE_MAX_ARRAY_SIZE} for all devices in the context.
28112818
* _image_row_pitch_ is the scan-line pitch in bytes.
28122819
The _image_row_pitch_ must be zero if _host_ptr_ is `NULL`,
28132820
ifdef::cl_khr_external_memory[]

0 commit comments

Comments
 (0)