Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add additional clarification for num_mip_levels #1272

Merged
merged 1 commit into from
Oct 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions api/footnotes.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,11 @@ This feature is provided for identifying memory leaks. \
Implementations are encouraged to favor this option as it makes it more likely that errors will be managed by applications. \
]

:fn-single-mipmap-level: pass:n[ \
Therefore, specifying _num_mip_levels_ equal to either `0` or `1` creates an image with a single mipmap level. \
]


:fn-srgb-image-requirements: pass:n[ \
Support for reading from the {CL_sRGBA} image channel order is optional for 1D image buffers. \
Support for writing to the {CL_sRGBA} image channel order is optional for all image types. \
Expand Down
15 changes: 9 additions & 6 deletions api/opencl_runtime_layer.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -2665,14 +2665,17 @@ endif::cl_khr_external_memory[]
_image_height_ for a 2D image array or a 3D image, must be {geq} the
image row pitch for a 1D image array, and must be a multiple of the
image row pitch.
* _num_mip_levels_ must be
ifndef::cl_khr_mipmap_image[0.]
* _num_mip_levels_ must be `0`, indicating that the image has a single
ifndef::cl_khr_mipmap_image[]
mipmap level.
endif::cl_khr_mipmap_image[]
ifdef::cl_khr_mipmap_image[]
0 unless the {cl_khr_mipmap_image_EXT} extension is supported, in which
case it may be a nonzero value specifying the number of mipmap
levels in the image.
mipmap level, unless the {cl_khr_mipmap_image_EXT} extension is supported.
bashbaug marked this conversation as resolved.
Show resolved Hide resolved
When the {cl_khr_mipmap_image_EXT} extension is supported, _num_mip_levels_
may additionally specify the total number of mipmap levels in the image,
including the base level footnote:[{fn-single-mipmap-level}].
endif::cl_khr_mipmap_image[]
* _num_samples_ must be 0.
* _num_samples_ must be `0`.
* _mem_object_ may refer to a valid buffer or image memory object.
`mem_object` can be a buffer memory object if `image_type` is
{CL_MEM_OBJECT_IMAGE1D_BUFFER} or
Expand Down