Merge tag 'LA.QSSI.14.0.r1-11200-qssi.0' of https://git.codelinaro.org/clo/la/platform/vendor/qcom-opensource/display-commonsys into lineage-21.0
"LA.QSSI.14.0.r1-11200-qssi.0" * tag 'LA.QSSI.14.0.r1-11200-qssi.0' of https://git.codelinaro.org/clo/la/platform/vendor/qcom-opensource/display-commonsys: gralloc: Add handling for buffer dequeue duration metadata Change-Id: I0434a47052692f1632c554808f6b8812e8988b6b
This commit is contained in:
@@ -27,6 +27,13 @@
|
|||||||
* IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Changes from Qualcomm Innovation Center are provided under the following license:
|
||||||
|
*
|
||||||
|
* Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. All rights reserved.
|
||||||
|
* SPDX-License-Identifier: BSD-3-Clause-Clear
|
||||||
|
*/
|
||||||
|
|
||||||
#include "QtiGralloc.h"
|
#include "QtiGralloc.h"
|
||||||
|
|
||||||
#include <log/log.h>
|
#include <log/log.h>
|
||||||
@@ -308,6 +315,8 @@ MetadataType getMetadataType(uint32_t in) {
|
|||||||
return MetadataType_TimedRendering;
|
return MetadataType_TimedRendering;
|
||||||
case QTI_CUSTOM_CONTENT_METADATA:
|
case QTI_CUSTOM_CONTENT_METADATA:
|
||||||
return MetadataType_CustomContentMetadata;
|
return MetadataType_CustomContentMetadata;
|
||||||
|
case QTI_BUFFER_DEQUEUE_DURATION:
|
||||||
|
return MetadataType_BufferDequeueDuration;
|
||||||
default:
|
default:
|
||||||
return MetadataType_Invalid;
|
return MetadataType_Invalid;
|
||||||
}
|
}
|
||||||
@@ -443,6 +452,11 @@ Error get(void *buffer, uint32_t type, void *param) {
|
|||||||
case QTI_CUSTOM_CONTENT_METADATA:
|
case QTI_CUSTOM_CONTENT_METADATA:
|
||||||
err = decodeCustomContentMetadata(bytestream, param);
|
err = decodeCustomContentMetadata(bytestream, param);
|
||||||
break;
|
break;
|
||||||
|
case QTI_BUFFER_DEQUEUE_DURATION:
|
||||||
|
err = static_cast<Error>(android::gralloc4::decodeInt64(
|
||||||
|
qtigralloc::MetadataType_BufferDequeueDuration, bytestream,
|
||||||
|
reinterpret_cast<int64_t *>(param)));
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
param = nullptr;
|
param = nullptr;
|
||||||
return Error::UNSUPPORTED;
|
return Error::UNSUPPORTED;
|
||||||
@@ -526,6 +540,11 @@ Error set(void *buffer, uint32_t type, void *param) {
|
|||||||
case QTI_CUSTOM_CONTENT_METADATA:
|
case QTI_CUSTOM_CONTENT_METADATA:
|
||||||
err = encodeCustomContentMetadata(param, &bytestream);
|
err = encodeCustomContentMetadata(param, &bytestream);
|
||||||
break;
|
break;
|
||||||
|
case QTI_BUFFER_DEQUEUE_DURATION:
|
||||||
|
err = static_cast<Error>(android::gralloc4::encodeInt64(
|
||||||
|
qtigralloc::MetadataType_BufferDequeueDuration,
|
||||||
|
*reinterpret_cast<int64_t *>(param), &bytestream));
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
param = nullptr;
|
param = nullptr;
|
||||||
return Error::UNSUPPORTED;
|
return Error::UNSUPPORTED;
|
||||||
|
|||||||
Reference in New Issue
Block a user