1 /* 2 * Copyright (C) 2024 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 <cstdint> 20 21 /* 22 * Display colorimetry enums. 23 */ 24 // NOLINTBEGIN(readability-identifier-naming) 25 enum class Colormode : int32_t { 26 kNative, 27 kBt601_625, 28 kBt601_625Unadjusted, 29 kBt601_525, 30 kBt601_525Unadjusted, 31 kBt709, 32 kDciP3, 33 kSrgb, 34 kAdobeRgb, 35 kDisplayP3, 36 kBt2020, 37 kBt2100Pq, 38 kBt2100Hlg, 39 kDisplayBt2020, 40 }; 41 // NOLINTEND(readability-identifier-naming) 42 43 /** 44 * Display panel colorspace property values. 45 */ 46 enum class Colorspace : int32_t { 47 kDefault, 48 kSmpte170MYcc, 49 kBt709Ycc, 50 kXvycc601, 51 kXvycc709, 52 kSycc601, 53 kOpycc601, 54 kOprgb, 55 kBt2020Cycc, 56 kBt2020Rgb, 57 kBt2020Ycc, 58 kDciP3RgbD65, 59 kDciP3RgbTheater, 60 kRgbWideFixed, 61 kRgbWideFloat, 62 kBt601Ycc, 63 }; 64 65 /** 66 * Display panel orientation property values. 67 */ 68 enum PanelOrientation { 69 kModePanelOrientationNormal = 0, 70 kModePanelOrientationBottomUp, 71 kModePanelOrientationLeftUp, 72 kModePanelOrientationRightUp 73 }; 74 75 struct QueuedConfigTiming { 76 // In order for the new config to be applied, the client must send a new frame 77 // at this time. 78 int64_t refresh_time_ns; 79 80 // The time when the display will start to refresh at the new vsync period. 81 int64_t new_vsync_time_ns; 82 }; 83