blob: 94de8f115f5fa98456a6f8bec4bb36d0b3eb729a [file] [log] [blame]
Marissa Wall48586522019-11-19 14:01:36 -08001/*
2 * Copyright 2019 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#pragma once
18
19#include <aidl/android/hardware/graphics/common/BlendMode.h>
Marissa Wallef785e12019-12-12 14:26:59 -080020#include <aidl/android/hardware/graphics/common/ChromaSiting.h>
21#include <aidl/android/hardware/graphics/common/Compression.h>
22#include <aidl/android/hardware/graphics/common/Cta861_3.h>
Marissa Wall48586522019-11-19 14:01:36 -080023#include <aidl/android/hardware/graphics/common/Dataspace.h>
24#include <aidl/android/hardware/graphics/common/ExtendableType.h>
25#include <aidl/android/hardware/graphics/common/Interlaced.h>
26#include <aidl/android/hardware/graphics/common/PlaneLayout.h>
Joseph Murphy048552f2019-12-17 19:58:45 +000027#include <aidl/android/hardware/graphics/common/PlaneLayoutComponentType.h>
Marissa Wallef785e12019-12-12 14:26:59 -080028#include <aidl/android/hardware/graphics/common/Smpte2086.h>
29#include <aidl/android/hardware/graphics/common/StandardMetadataType.h>
30#include <aidl/android/hardware/graphics/common/XyColor.h>
Marissa Wall48586522019-11-19 14:01:36 -080031#include <android/hardware/graphics/mapper/4.0/IMapper.h>
32
33namespace android {
34
35namespace gralloc4 {
36
Marissa Wall48586522019-11-19 14:01:36 -080037#define GRALLOC4_STANDARD_METADATA_TYPE "android.hardware.graphics.common.StandardMetadataType"
Marissa Wall22b2de12019-12-02 18:11:43 -080038#define GRALLOC4_STANDARD_CHROMA_SITING "android.hardware.graphics.common.ChromaSiting"
39#define GRALLOC4_STANDARD_COMPRESSION "android.hardware.graphics.common.Compression"
40#define GRALLOC4_STANDARD_INTERLACED "android.hardware.graphics.common.Interlaced"
41#define GRALLOC4_STANDARD_PLANE_LAYOUT_COMPONENT_TYPE \
42 "android.hardware.graphics.common.PlaneLayoutComponentType"
Marissa Wall48586522019-11-19 14:01:36 -080043
44/*---------------------------------------------------------------------------------------------*/
45/**
46 * Definitions of the standard buffer metadata types. It is recommended that everyone uses
47 * these definitions directly for standard buffer metadata types.
48 */
49static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_BufferId = {
50 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::BUFFER_ID)
51};
52
53static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_Name = {
54 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::NAME)
55};
56
57static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_Width = {
58 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::WIDTH)
59};
60
61static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_Height = {
62 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::HEIGHT)
63};
64
65static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_LayerCount = {
66 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::LAYER_COUNT)
67};
68
69static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_PixelFormatRequested = {
70 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::PIXEL_FORMAT_REQUESTED)
71};
72
73static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_PixelFormatFourCC = {
74 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::PIXEL_FORMAT_FOURCC)
75};
76
77static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_PixelFormatModifier = {
78 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::PIXEL_FORMAT_MODIFIER)
79};
80
81static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_Usage = {
82 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::USAGE)
83};
84
85static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_AllocationSize = {
86 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::ALLOCATION_SIZE)
87};
88
89static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_ProtectedContent = {
90 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::PROTECTED_CONTENT)
91};
92
93static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_Compression = {
94 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::COMPRESSION)
95};
96
97static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_Interlaced = {
98 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::INTERLACED)
99};
100
101static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_ChromaSiting = {
102 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::CHROMA_SITING)
103};
104
105static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_PlaneLayouts = {
106 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::PLANE_LAYOUTS)
107};
108
109static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_Dataspace = {
110 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::DATASPACE)
111};
112
113static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType MetadataType_BlendMode = {
114 GRALLOC4_STANDARD_METADATA_TYPE, static_cast<int64_t>(aidl::android::hardware::graphics::common::StandardMetadataType::BLEND_MODE)
115};
116
Marissa Wallef785e12019-12-12 14:26:59 -0800117static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType
118 MetadataType_Smpte2086 = {GRALLOC4_STANDARD_METADATA_TYPE,
119 static_cast<int64_t>(aidl::android::hardware::graphics::common::
120 StandardMetadataType::SMPTE2086)};
121
122static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType
123 MetadataType_Cta861_3 = {GRALLOC4_STANDARD_METADATA_TYPE,
124 static_cast<int64_t>(aidl::android::hardware::graphics::common::
125 StandardMetadataType::CTA861_3)};
126
127static const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType
128 MetadataType_Smpte2094_40 = {GRALLOC4_STANDARD_METADATA_TYPE,
129 static_cast<int64_t>(
130 aidl::android::hardware::graphics::common::
131 StandardMetadataType::SMPTE2094_40)};
132
Marissa Wall48586522019-11-19 14:01:36 -0800133/*---------------------------------------------------------------------------------------------*/
134
135/**
136 * Definitions of the standard compression strategies. It is recommended that everyone uses
137 * these definitions directly for standard compression strategies.
138 */
Marissa Wall22b2de12019-12-02 18:11:43 -0800139static const aidl::android::hardware::graphics::common::ExtendableType Compression_None =
140 {GRALLOC4_STANDARD_COMPRESSION,
141 static_cast<int64_t>(aidl::android::hardware::graphics::common::Compression::NONE)};
Marissa Wall48586522019-11-19 14:01:36 -0800142
Marissa Wall22b2de12019-12-02 18:11:43 -0800143static const aidl::android::hardware::graphics::common::ExtendableType
144 Compression_DisplayStreamCompression =
145 {GRALLOC4_STANDARD_COMPRESSION,
146 static_cast<int64_t>(aidl::android::hardware::graphics::common::Compression::
147 DISPLAY_STREAM_COMPRESSION)};
Marissa Wall48586522019-11-19 14:01:36 -0800148
149/*---------------------------------------------------------------------------------------------*/
150
151/**
152 * Definitions of the standard interlaced strategies. It is recommended that everyone uses
153 * these definitions directly for standard interlaced strategies.
154 */
Marissa Wall22b2de12019-12-02 18:11:43 -0800155static const aidl::android::hardware::graphics::common::ExtendableType Interlaced_None =
156 {GRALLOC4_STANDARD_INTERLACED,
157 static_cast<int64_t>(aidl::android::hardware::graphics::common::Interlaced::NONE)};
Marissa Wall48586522019-11-19 14:01:36 -0800158
Marissa Wall22b2de12019-12-02 18:11:43 -0800159static const aidl::android::hardware::graphics::common::ExtendableType Interlaced_TopBottom =
160 {GRALLOC4_STANDARD_INTERLACED,
161 static_cast<int64_t>(aidl::android::hardware::graphics::common::Interlaced::TOP_BOTTOM)};
Marissa Wall48586522019-11-19 14:01:36 -0800162
Marissa Wall22b2de12019-12-02 18:11:43 -0800163static const aidl::android::hardware::graphics::common::ExtendableType Interlaced_RightLeft =
164 {GRALLOC4_STANDARD_INTERLACED,
165 static_cast<int64_t>(aidl::android::hardware::graphics::common::Interlaced::RIGHT_LEFT)};
Marissa Wall48586522019-11-19 14:01:36 -0800166
167/*---------------------------------------------------------------------------------------------*/
168
169/**
170 * Definitions of the standard chroma siting. It is recommended that everyone uses
171 * these definitions directly for standard chroma siting.
172 */
Marissa Wall22b2de12019-12-02 18:11:43 -0800173static const aidl::android::hardware::graphics::common::ExtendableType ChromaSiting_None =
174 {GRALLOC4_STANDARD_CHROMA_SITING,
175 static_cast<int64_t>(aidl::android::hardware::graphics::common::ChromaSiting::NONE)};
Marissa Wall48586522019-11-19 14:01:36 -0800176
Marissa Wall22b2de12019-12-02 18:11:43 -0800177static const aidl::android::hardware::graphics::common::ExtendableType ChromaSiting_Unknown =
178 {GRALLOC4_STANDARD_CHROMA_SITING,
179 static_cast<int64_t>(aidl::android::hardware::graphics::common::ChromaSiting::UNKNOWN)};
Marissa Wall48586522019-11-19 14:01:36 -0800180
Marissa Wall22b2de12019-12-02 18:11:43 -0800181static const aidl::android::hardware::graphics::common::ExtendableType
182 ChromaSiting_SitedInterstitial = {GRALLOC4_STANDARD_CHROMA_SITING,
183 static_cast<int64_t>(
184 aidl::android::hardware::graphics::common::
185 ChromaSiting::SITED_INTERSTITIAL)};
Marissa Wall48586522019-11-19 14:01:36 -0800186
Marissa Wall22b2de12019-12-02 18:11:43 -0800187static const aidl::android::hardware::graphics::common::ExtendableType
188 ChromaSiting_CositedHorizontal = {GRALLOC4_STANDARD_CHROMA_SITING,
189 static_cast<int64_t>(
190 aidl::android::hardware::graphics::common::
191 ChromaSiting::COSITED_HORIZONTAL)};
Marissa Wall48586522019-11-19 14:01:36 -0800192
193/*---------------------------------------------------------------------------------------------*/
194
195/**
196 * Definitions of the standard plane layout component types. It is recommended that everyone uses
197 * these definitions directly for standard plane layout component types
198 */
Marissa Wall22b2de12019-12-02 18:11:43 -0800199static const aidl::android::hardware::graphics::common::ExtendableType PlaneLayoutComponentType_Y =
200 {GRALLOC4_STANDARD_PLANE_LAYOUT_COMPONENT_TYPE,
201 static_cast<int64_t>(
202 aidl::android::hardware::graphics::common::PlaneLayoutComponentType::Y)};
Marissa Wall48586522019-11-19 14:01:36 -0800203
Marissa Wall22b2de12019-12-02 18:11:43 -0800204static const aidl::android::hardware::graphics::common::ExtendableType PlaneLayoutComponentType_CB =
205 {GRALLOC4_STANDARD_PLANE_LAYOUT_COMPONENT_TYPE,
206 static_cast<int64_t>(
207 aidl::android::hardware::graphics::common::PlaneLayoutComponentType::CB)};
Marissa Wall48586522019-11-19 14:01:36 -0800208
Marissa Wall22b2de12019-12-02 18:11:43 -0800209static const aidl::android::hardware::graphics::common::ExtendableType PlaneLayoutComponentType_CR =
210 {GRALLOC4_STANDARD_PLANE_LAYOUT_COMPONENT_TYPE,
211 static_cast<int64_t>(
212 aidl::android::hardware::graphics::common::PlaneLayoutComponentType::CR)};
Marissa Wall48586522019-11-19 14:01:36 -0800213
Marissa Wall22b2de12019-12-02 18:11:43 -0800214static const aidl::android::hardware::graphics::common::ExtendableType PlaneLayoutComponentType_R =
215 {GRALLOC4_STANDARD_PLANE_LAYOUT_COMPONENT_TYPE,
216 static_cast<int64_t>(
217 aidl::android::hardware::graphics::common::PlaneLayoutComponentType::R)};
Marissa Wall48586522019-11-19 14:01:36 -0800218
Marissa Wall22b2de12019-12-02 18:11:43 -0800219static const aidl::android::hardware::graphics::common::ExtendableType PlaneLayoutComponentType_G =
220 {GRALLOC4_STANDARD_PLANE_LAYOUT_COMPONENT_TYPE,
221 static_cast<int64_t>(
222 aidl::android::hardware::graphics::common::PlaneLayoutComponentType::G)};
Marissa Wall48586522019-11-19 14:01:36 -0800223
Marissa Wall22b2de12019-12-02 18:11:43 -0800224static const aidl::android::hardware::graphics::common::ExtendableType PlaneLayoutComponentType_B =
225 {GRALLOC4_STANDARD_PLANE_LAYOUT_COMPONENT_TYPE,
226 static_cast<int64_t>(
227 aidl::android::hardware::graphics::common::PlaneLayoutComponentType::B)};
Marissa Wall48586522019-11-19 14:01:36 -0800228
Marissa Wall22b2de12019-12-02 18:11:43 -0800229static const aidl::android::hardware::graphics::common::ExtendableType PlaneLayoutComponentType_A =
230 {GRALLOC4_STANDARD_PLANE_LAYOUT_COMPONENT_TYPE,
231 static_cast<int64_t>(
232 aidl::android::hardware::graphics::common::PlaneLayoutComponentType::A)};
Marissa Wall48586522019-11-19 14:01:36 -0800233
234/*---------------------------------------------------------------------------------------------*/
235
236/**
Marissa Wall48586522019-11-19 14:01:36 -0800237 * The functions below encode and decode standard metadata into a byte stream. It is STRONGLY
238 * recommended that both the vendor and system partitions use these functions when getting
239 * and setting metadata through gralloc 4 (IMapper 4.0).
240 */
241status_t encodeBufferId(uint64_t bufferId, android::hardware::hidl_vec<uint8_t>* outBufferId);
242status_t decodeBufferId(const android::hardware::hidl_vec<uint8_t>& bufferId, uint64_t* outBufferId);
243
244status_t encodeName(const std::string& name, android::hardware::hidl_vec<uint8_t>* outName);
245status_t decodeName(const android::hardware::hidl_vec<uint8_t>& name, std::string* outName);
246
247status_t encodeWidth(uint64_t width, android::hardware::hidl_vec<uint8_t>* outWidth);
248status_t decodeWidth(const android::hardware::hidl_vec<uint8_t>& width, uint64_t* outWidth);
249
250status_t encodeHeight(uint64_t height, android::hardware::hidl_vec<uint8_t>* outHeight);
251status_t decodeHeight(const android::hardware::hidl_vec<uint8_t>& height, uint64_t* outHeight);
252
253status_t encodeLayerCount(uint64_t layerCount, android::hardware::hidl_vec<uint8_t>* outLayerCount);
254status_t decodeLayerCount(const android::hardware::hidl_vec<uint8_t>& layerCount, uint64_t* outLayerCount);
255
256status_t encodePixelFormatRequested(const hardware::graphics::common::V1_2::PixelFormat& pixelFormatRequested, android::hardware::hidl_vec<uint8_t>* outPixelFormatRequested);
257status_t decodePixelFormatRequested(const android::hardware::hidl_vec<uint8_t>& pixelFormatRequested, hardware::graphics::common::V1_2::PixelFormat* outPixelFormatRequested);
258
259status_t encodePixelFormatFourCC(uint32_t pixelFormatFourCC, android::hardware::hidl_vec<uint8_t>* outPixelFormatFourCC);
260status_t decodePixelFormatFourCC(const android::hardware::hidl_vec<uint8_t>& pixelFormatFourCC, uint32_t* outPixelFormatFourCC);
261
262status_t encodePixelFormatModifier(uint64_t pixelFormatModifier, android::hardware::hidl_vec<uint8_t>* outPixelFormatModifier);
263status_t decodePixelFormatModifier(const android::hardware::hidl_vec<uint8_t>& pixelFormatModifier, uint64_t* outPixelFormatModifier);
264
265status_t encodeUsage(uint64_t usage, android::hardware::hidl_vec<uint8_t>* outUsage);
266status_t decodeUsage(const android::hardware::hidl_vec<uint8_t>& usage, uint64_t* outUsage);
267
268status_t encodeAllocationSize(uint64_t allocationSize, android::hardware::hidl_vec<uint8_t>* outAllocationSize);
269status_t decodeAllocationSize(const android::hardware::hidl_vec<uint8_t>& allocationSize, uint64_t* outAllocationSize);
270
271status_t encodeProtectedContent(uint64_t protectedContent, android::hardware::hidl_vec<uint8_t>* outProtectedContent);
272status_t decodeProtectedContent(const android::hardware::hidl_vec<uint8_t>& protectedContent, uint64_t* outProtectedContent);
273
274status_t encodeCompression(const aidl::android::hardware::graphics::common::ExtendableType& compression, android::hardware::hidl_vec<uint8_t>* outCompression);
275status_t decodeCompression(const android::hardware::hidl_vec<uint8_t>& compression, aidl::android::hardware::graphics::common::ExtendableType* outCompression);
276
277status_t encodeInterlaced(const aidl::android::hardware::graphics::common::ExtendableType& interlaced, android::hardware::hidl_vec<uint8_t>* outInterlaced);
278status_t decodeInterlaced(const android::hardware::hidl_vec<uint8_t>& interlaced, aidl::android::hardware::graphics::common::ExtendableType* outInterlaced);
279
280status_t encodeChromaSiting(const aidl::android::hardware::graphics::common::ExtendableType& chromaSiting, android::hardware::hidl_vec<uint8_t>* outChromaSiting);
281status_t decodeChromaSiting(const android::hardware::hidl_vec<uint8_t>& chromaSiting, aidl::android::hardware::graphics::common::ExtendableType* outChromaSiting);
282
283status_t encodePlaneLayouts(const std::vector<aidl::android::hardware::graphics::common::PlaneLayout>& planeLayouts, android::hardware::hidl_vec<uint8_t>* outPlaneLayouts);
284status_t decodePlaneLayouts(const android::hardware::hidl_vec<uint8_t>& planeLayouts, std::vector<aidl::android::hardware::graphics::common::PlaneLayout>* outPlaneLayouts);
285
286status_t encodeDataspace(const aidl::android::hardware::graphics::common::Dataspace& dataspace, android::hardware::hidl_vec<uint8_t>* outDataspace);
287status_t decodeDataspace(const android::hardware::hidl_vec<uint8_t>& dataspace, aidl::android::hardware::graphics::common::Dataspace* outDataspace);
288
289status_t encodeBlendMode(const aidl::android::hardware::graphics::common::BlendMode& blendMode, android::hardware::hidl_vec<uint8_t>* outBlendMode);
290status_t decodeBlendMode(const android::hardware::hidl_vec<uint8_t>& blendMode, aidl::android::hardware::graphics::common::BlendMode* outBlendMode);
291
Marissa Wallef785e12019-12-12 14:26:59 -0800292status_t encodeSmpte2086(
293 const std::optional<aidl::android::hardware::graphics::common::Smpte2086>& smpte2086,
294 android::hardware::hidl_vec<uint8_t>* outSmpte2086);
295status_t decodeSmpte2086(
296 const android::hardware::hidl_vec<uint8_t>& smpte2086,
297 std::optional<aidl::android::hardware::graphics::common::Smpte2086>* outSmpte2086);
298
299status_t encodeCta861_3(
300 const std::optional<aidl::android::hardware::graphics::common::Cta861_3>& cta861_3,
301 android::hardware::hidl_vec<uint8_t>* outCta861_3);
302status_t decodeCta861_3(
303 const android::hardware::hidl_vec<uint8_t>& cta861_3,
304 std::optional<aidl::android::hardware::graphics::common::Cta861_3>* outCta861_3);
305
306status_t encodeSmpte2094_40(const std::optional<std::vector<uint8_t>>& smpte2094_40,
307 android::hardware::hidl_vec<uint8_t>* outSmpte2094_40);
308status_t decodeSmpte2094_40(const android::hardware::hidl_vec<uint8_t>& smpte2094_40,
309 std::optional<std::vector<uint8_t>>* outSmpte2094_40);
310
Marissa Wall22b2de12019-12-02 18:11:43 -0800311/**
312 * The functions below can be used to parse extendable types.
313 */
314bool isStandardMetadataType(
315 const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType& metadataType);
316bool isStandardCompression(
317 const aidl::android::hardware::graphics::common::ExtendableType& compression);
318bool isStandardInterlaced(
319 const aidl::android::hardware::graphics::common::ExtendableType& interlaced);
320bool isStandardChromaSiting(
321 const aidl::android::hardware::graphics::common::ExtendableType& chromaSiting);
322bool isStandardPlaneLayoutComponentType(
323 const aidl::android::hardware::graphics::common::ExtendableType& planeLayoutComponentType);
324
325aidl::android::hardware::graphics::common::StandardMetadataType getStandardMetadataTypeValue(
326 const android::hardware::graphics::mapper::V4_0::IMapper::MetadataType& metadataType);
327aidl::android::hardware::graphics::common::Compression getStandardCompressionValue(
328 const aidl::android::hardware::graphics::common::ExtendableType& compression);
329aidl::android::hardware::graphics::common::Interlaced getStandardInterlacedValue(
330 const aidl::android::hardware::graphics::common::ExtendableType& interlaced);
331aidl::android::hardware::graphics::common::ChromaSiting getStandardChromaSitingValue(
332 const aidl::android::hardware::graphics::common::ExtendableType& chromaSiting);
333aidl::android::hardware::graphics::common::PlaneLayoutComponentType
334getStandardPlaneLayoutComponentTypeValue(
335 const aidl::android::hardware::graphics::common::ExtendableType& planeLayoutComponentType);
336
337/**
338 * The functions below return string representations of ExtendableTypes
339 */
340std::string getCompressionName(
341 const aidl::android::hardware::graphics::common::ExtendableType& compression);
342std::string getInterlacedName(
343 const aidl::android::hardware::graphics::common::ExtendableType& interlaced);
344std::string getChromaSitingName(
345 const aidl::android::hardware::graphics::common::ExtendableType& chromaSiting);
346std::string getPlaneLayoutComponentTypeName(
347 const aidl::android::hardware::graphics::common::ExtendableType& planeLayoutComponentType);
348
Marissa Wall48586522019-11-19 14:01:36 -0800349} // namespace gralloc4
350
351} // namespace android