1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26#ifndef MOD_SHARED_H_
27#define MOD_SHARED_H_
28
29enum color_transfer_func {
30 TRANSFER_FUNC_UNKNOWN,
31 TRANSFER_FUNC_SRGB,
32 TRANSFER_FUNC_BT709,
33 TRANSFER_FUNC_PQ2084,
34 TRANSFER_FUNC_PQ2084_INTERIM,
35 TRANSFER_FUNC_LINEAR_0_1,
36 TRANSFER_FUNC_LINEAR_0_125,
37 TRANSFER_FUNC_GAMMA_22,
38 TRANSFER_FUNC_GAMMA_26
39};
40
41enum vrr_packet_type {
42 PACKET_TYPE_VRR,
43 PACKET_TYPE_FS_V1,
44 PACKET_TYPE_FS_V2,
45 PACKET_TYPE_FS_V3,
46 PACKET_TYPE_VTEM
47};
48
49union lut3d_control_flags {
50 unsigned int raw;
51 struct {
52 unsigned int do_chroma_scale :1;
53 unsigned int spec_version :3;
54 unsigned int use_zero_display_black :1;
55 unsigned int use_zero_source_black :1;
56 unsigned int force_display_black :6;
57 unsigned int apply_display_gamma :1;
58 unsigned int exp_shaper_max :6;
59 unsigned int unity_3dlut :1;
60 unsigned int bypass_3dlut :1;
61 unsigned int use_3dlut :1;
62 unsigned int less_than_dcip3 :1;
63 unsigned int override_lum :1;
64 unsigned int use_gamut_map_lib :1;
65 unsigned int chromatic_adaptation_src :1;
66 unsigned int chromatic_adaptation_dst :1;
67 unsigned int do_blender_lut_degamma :1;
68 unsigned int reseved :4;
69 } bits;
70};
71
72enum tm_show_option_internal {
73 tm_show_option_internal_single_file = 0,
74 tm_show_option_internal_duplicate_file,
75 tm_show_option_internal_duplicate_sidebyside
76};
77
78enum lut3d_control_gamut_map {
79 lut3d_control_gamut_map_none = 0,
80 lut3d_control_gamut_map_tonemap,
81 lut3d_control_gamut_map_chto,
82 lut3d_control_gamut_map_chso,
83 lut3d_control_gamut_map_chci
84};
85
86enum lut3d_control_rotation_mode {
87 lut3d_control_rotation_mode_none = 0,
88 lut3d_control_rotation_mode_hue,
89 lut3d_control_rotation_mode_cc,
90 lut3d_control_rotation_mode_hue_cc
91};
92
93struct lut3d_settings {
94 unsigned char version;
95 union lut3d_control_flags flags;
96 union lut3d_control_flags flags2;
97 enum tm_show_option_internal option;
98 unsigned int min_lum;
99 unsigned int max_lum;
100 unsigned int min_lum2;
101 unsigned int max_lum2;
102 enum lut3d_control_gamut_map map;
103 enum lut3d_control_rotation_mode rotation;
104 enum lut3d_control_gamut_map map2;
105 enum lut3d_control_rotation_mode rotation2;
106};
107
108#endif
109