Path: blob/21.2-virgl/include/android_stub/android/hdr_metadata.h
4547 views
/*1* Copyright 2019 The Android Open Source Project2*3* Licensed under the Apache License, Version 2.0 (the "License");4* you may not use this file except in compliance with the License.5* You may obtain a copy of the License at6*7* http://www.apache.org/licenses/LICENSE-2.08*9* Unless required by applicable law or agreed to in writing, software10* distributed under the License is distributed on an "AS IS" BASIS,11* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.12* See the License for the specific language governing permissions and13* limitations under the License.14*/1516/**17* @file hdr_metadata.h18*/1920#ifndef ANDROID_HDR_METADATA_H21#define ANDROID_HDR_METADATA_H2223#include <inttypes.h>2425#include <sys/cdefs.h>2627__BEGIN_DECLS2829/**30* These structures are used to define the display's capabilities for HDR content.31* They can be used to better tone map content to user's display.32*/3334/**35* HDR metadata standards that are supported by Android.36*/37enum AHdrMetadataType : uint32_t {38HDR10_SMPTE2086 = 1,39HDR10_CTA861_3 = 2,40HDR10PLUS_SEI = 3,41};4243/**44* Color is defined in CIE XYZ coordinates.45*/46struct AColor_xy {47float x;48float y;49};5051/**52* SMPTE ST 2086 "Mastering Display Color Volume" static metadata53*/54struct AHdrMetadata_smpte2086 {55struct AColor_xy displayPrimaryRed;56struct AColor_xy displayPrimaryGreen;57struct AColor_xy displayPrimaryBlue;58struct AColor_xy whitePoint;59float maxLuminance;60float minLuminance;61};6263/**64* CTA 861.3 "HDR Static Metadata Extension" static metadata65*/66struct AHdrMetadata_cta861_3 {67float maxContentLightLevel;68float maxFrameAverageLightLevel;69};7071__END_DECLS7273#endif // ANDROID_HDR_METADATA_H747576