• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #ifndef ANDROID_VR_HARDWARE_COMPOSER_DEFS_H
2 #define ANDROID_VR_HARDWARE_COMPOSER_DEFS_H
3 
4 #include <inttypes.h>
5 
6 #ifdef __cplusplus
7 extern "C" {
8 #endif
9 
10 // NOTE: These definitions must match the ones in
11 // //hardware/libhardware/include/hardware/hwcomposer2.h. They are used by the
12 // client side which does not have access to hwc2 headers.
13 enum DvrHwcBlendMode {
14   DVR_HWC_BLEND_MODE_INVALID = 0,
15   DVR_HWC_BLEND_MODE_NONE = 1,
16   DVR_HWC_BLEND_MODE_PREMULTIPLIED = 2,
17   DVR_HWC_BLEND_MODE_COVERAGE = 3,
18 };
19 
20 enum DvrHwcComposition {
21   DVR_HWC_COMPOSITION_INVALID = 0,
22   DVR_HWC_COMPOSITION_CLIENT = 1,
23   DVR_HWC_COMPOSITION_DEVICE = 2,
24   DVR_HWC_COMPOSITION_SOLID_COLOR = 3,
25   DVR_HWC_COMPOSITION_CURSOR = 4,
26   DVR_HWC_COMPOSITION_SIDEBAND = 5,
27 };
28 
29 enum DvrHwcTransform {
30   DVR_HWC_TRANSFORM_NONE = 0,
31   DVR_HWC_TRANSFORM_FLIP_H = 1,
32   DVR_HWC_TRANSFORM_FLIP_V = 2,
33   DVR_HWC_TRANSFORM_ROT_90 = 4,
34   DVR_HWC_TRANSFORM_ROT_180 = 3,
35   DVR_HWC_TRANSFORM_ROT_270 = 7,
36 };
37 
38 typedef uint64_t DvrHwcDisplay;
39 typedef uint64_t DvrHwcLayer;
40 
41 struct DvrHwcRecti {
42   int32_t left;
43   int32_t top;
44   int32_t right;
45   int32_t bottom;
46 };
47 
48 struct DvrHwcRectf {
49   float left;
50   float top;
51   float right;
52   float bottom;
53 };
54 
55 #ifdef __cplusplus
56 }  // extern "C"
57 #endif
58 
59 #endif  // ANDROID_DVR_HARDWARE_COMPOSER_DEFS_H
60