Correct media compression format for planar images

Set most significant bit for chroma planes.

Signed-off-by: Filip Hazubski <filip.hazubski@intel.com>
This commit is contained in:
Filip Hazubski
2022-03-25 14:19:49 +00:00
committed by Compute-Runtime-Automation
parent 586e8510de
commit 3123ab5bf9
9 changed files with 71 additions and 10 deletions

View File

@@ -410,6 +410,7 @@ Image *Image::create(Context *context,
image->setQPitch(imgInfo.qPitch);
image->setSurfaceOffsets(imgInfo.offset, imgInfo.xOffset, imgInfo.yOffset, imgInfo.yOffsetForUVPlane);
image->setMipCount(imgInfo.mipCount);
image->setPlane(imgInfo.plane);
if (parentImage) {
image->setMediaPlaneType(static_cast<cl_uint>(imageDesc->image_depth));
image->setParentSharingHandler(parentImage->getSharingHandler());
@@ -516,6 +517,7 @@ Image *Image::createSharedImage(Context *context, SharingHandler *sharingHandler
sharedImage->setCubeFaceIndex(cubeFaceIndex);
sharedImage->setSurfaceOffsets(imgInfo.offset, imgInfo.xOffset, imgInfo.yOffset, imgInfo.yOffsetForUVPlane);
sharedImage->setMcsSurfaceInfo(mcsSurfaceInfo);
sharedImage->setPlane(imgInfo.plane);
return sharedImage;
}