1// LINT: LEGACY_NAMES
2syntax = "proto2";
3
4package wireless.android.partner.adl.proto;
5
6option java_package = "com.google.wireless.android.partner.adl.proto";
7option java_outer_classname = "CameraDeviceInfoProto";
8
9// Content of this file is generated from $(ANDROID_ROOT)/system/media/camera/doc
10// Keep internal protocol buffer definition in sync with this one
11// Camera related device information
12// Next Id: 9
13message CameraDeviceInfo {
14  // Supported profiles from CamcorderProfile.hasProfile
15  optional bool profile_480p = 1;
16  optional bool profile_720p = 2;
17  optional bool profile_1080p = 3;
18  optional bool profile_cif = 4;
19  optional bool profile_qcif = 5;
20  optional bool profile_qvga = 6;
21  optional int32 num_of_camera = 7;
22
23  message PerCameraInfo {
24    message Rational {
25        optional int32 numerator = 1;
26        optional int32 denominator = 2;
27    }
28
29    message Size {
30        optional int32 width = 1;
31        optional int32 height = 2;
32    }
33
34    message SizeF {
35        optional float width = 1;
36        optional float height = 2;
37    }
38
39    message Rect {
40        optional int32 left = 1;
41        optional int32 right = 2;
42        optional int32 top = 3;
43        optional int32 bottom = 4;
44    }
45
46    message StreamConfigurations {
47        message StreamConfig {
48            optional int32 format = 1;
49            optional int32 width = 2;
50            optional int32 height = 3;
51            optional bool input = 4;
52            optional int64 minFrameDuration = 5;
53        }
54        repeated StreamConfig availableStreamConfigurations = 1;
55    }
56
57    message RangeFloat {
58        optional int32 lower = 1;
59        optional int32 upper = 2;
60    }
61
62    message RangeInt {
63        optional int32 lower = 1;
64        optional int32 upper = 2;
65    }
66
67    message RangeLong {
68        optional int64 lower = 1;
69        optional int64 upper = 2;
70    }
71
72    message ColorSpaceTransform {
73        repeated Rational elements = 1;
74    }
75
76    message BlackLevelPattern {
77        repeated int32 black_level_pattern = 1;
78    }
79
80    message MultiResolutionStreamConfigurations {
81        message MultiResolutionStreamConfig {
82            optional int32 format = 1;
83            optional int32 width = 2;
84            optional int32 height = 3;
85            optional string cameraId = 4;
86            optional bool input = 5;
87        }
88        repeated MultiResolutionStreamConfig availableMultiResolutionConfigurations = 1;
89    }
90
91    optional string cameraId = 1;
92
93    // Start of codegen fields
94<%
95  section_idx = 1
96%>\
97% for sec in find_all_sections(metadata):
98## Reserve 2^16 tag id space for each section
99<%
100  idx = section_idx * pow(2,16)
101%>\
102% for entry in find_unique_entries(sec):
103% if entry.kind == 'static' and entry.visibility in ("public", "java_public"):
104    ${protobuf_type(entry)} ${protobuf_name(entry)} = ${idx};
105<%
106    idx += 1
107%>\
108% endif
109% endfor
110<%
111  section_idx += 1
112%>\
113% endfor
114    // End of codegen fields
115  }
116
117  // Per camera (front/back) informations
118  repeated PerCameraInfo per_camera_info = 8;
119} // CameraDeviceInfo
120
121