mirror of
https://github.com/intel/compute-runtime.git
synced 2025-09-15 13:01:45 +08:00
Update setMediaImageArg() to use GMM API for tiling
Change-Id: I3e2d094ebfefa7c8c64babb9a715215edca563ea Signed-off-by: Dunajski, Bartosz <bartosz.dunajski@intel.com>
This commit is contained in:

committed by
sys_ocldev

parent
9c200530c8
commit
93f9f58a6c
@ -229,7 +229,10 @@ void ImageHw<GfxFamily>::setMediaImageArg(void *memory) {
|
||||
surfaceState->setHeight(static_cast<uint32_t>(getImageDesc().image_height));
|
||||
surfaceState->setPictureStructure(MEDIA_SURFACE_STATE::PICTURE_STRUCTURE_FRAME_PICTURE);
|
||||
|
||||
surfaceState->setTileMode(MEDIA_SURFACE_STATE::TILE_MODE_TILEMODE_YMAJOR);
|
||||
auto gmm = getGraphicsAllocation()->getDefaultGmm();
|
||||
auto tileMode = static_cast<typename MEDIA_SURFACE_STATE::TILE_MODE>(gmm->gmmResourceInfo->getTileModeSurfaceState());
|
||||
|
||||
surfaceState->setTileMode(tileMode);
|
||||
surfaceState->setSurfacePitch(static_cast<uint32_t>(getImageDesc().image_row_pitch));
|
||||
|
||||
surfaceState->setSurfaceFormat(surfaceFormat);
|
||||
|
Reference in New Issue
Block a user