2017-12-21 00:45:38 +01:00
|
|
|
/*
|
2021-05-21 10:22:13 +00:00
|
|
|
* Copyright (C) 2018-2021 Intel Corporation
|
2018-09-18 09:11:08 +02:00
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: MIT
|
|
|
|
|
*
|
|
|
|
|
*/
|
2017-12-21 00:45:38 +01:00
|
|
|
|
2021-05-21 10:22:13 +00:00
|
|
|
#include "shared/test/common/mocks/mock_gmm_client_context_base.h"
|
2017-12-21 00:45:38 +01:00
|
|
|
|
2019-03-26 11:59:46 +01:00
|
|
|
namespace NEO {
|
2018-07-06 09:07:42 +02:00
|
|
|
|
|
|
|
|
GMM_RESOURCE_INFO *MockGmmClientContextBase::createResInfoObject(GMM_RESCREATE_PARAMS *pCreateParams) {
|
|
|
|
|
return reinterpret_cast<GMM_RESOURCE_INFO *>(new char[1]);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
GMM_RESOURCE_INFO *MockGmmClientContextBase::copyResInfoObject(GMM_RESOURCE_INFO *pSrcRes) {
|
|
|
|
|
return reinterpret_cast<GMM_RESOURCE_INFO *>(new char[1]);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void MockGmmClientContextBase::destroyResInfoObject(GMM_RESOURCE_INFO *pResInfo) {
|
|
|
|
|
delete[] reinterpret_cast<char *>(pResInfo);
|
2017-12-21 00:45:38 +01:00
|
|
|
}
|
2019-10-09 17:32:35 +02:00
|
|
|
|
|
|
|
|
uint8_t MockGmmClientContextBase::getSurfaceStateCompressionFormat(GMM_RESOURCE_FORMAT format) {
|
|
|
|
|
capturedFormat = format;
|
|
|
|
|
getSurfaceStateCompressionFormatCalled++;
|
|
|
|
|
return compressionFormatToReturn;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
uint8_t MockGmmClientContextBase::getMediaSurfaceStateCompressionFormat(GMM_RESOURCE_FORMAT format) {
|
|
|
|
|
capturedFormat = format;
|
|
|
|
|
getMediaSurfaceStateCompressionFormatCalled++;
|
|
|
|
|
return compressionFormatToReturn;
|
|
|
|
|
}
|
|
|
|
|
|
2019-03-26 11:59:46 +01:00
|
|
|
} // namespace NEO
|