1 // Generated by the protocol buffer compiler. DO NOT EDIT!
2 // source: protos/perfetto/trace/android/surfaceflinger_transactions.proto
3
4 #include "protos/perfetto/trace/android/surfaceflinger_transactions.pb.h"
5
6 #include <algorithm>
7 #include <cstdint>
8
9 #include <google/protobuf/io/coded_stream.h>
10 #include <google/protobuf/extension_set.h>
11 #include <google/protobuf/wire_format_lite.h>
12 #include <google/protobuf/io/zero_copy_stream_impl_lite.h>
13 // @@protoc_insertion_point(includes)
14 #include <google/protobuf/port_def.inc>
15
16 PROTOBUF_PRAGMA_INIT_SEG
17
18 namespace _pb = ::PROTOBUF_NAMESPACE_ID;
19 namespace _pbi = _pb::internal;
20
21 namespace perfetto {
22 namespace protos {
TransactionTraceFile(::_pbi::ConstantInitialized)23 PROTOBUF_CONSTEXPR TransactionTraceFile::TransactionTraceFile(
24 ::_pbi::ConstantInitialized): _impl_{
25 /*decltype(_impl_._has_bits_)*/{}
26 , /*decltype(_impl_._cached_size_)*/{}
27 , /*decltype(_impl_.entry_)*/{}
28 , /*decltype(_impl_.magic_number_)*/::uint64_t{0u}
29 , /*decltype(_impl_.real_to_elapsed_time_offset_nanos_)*/::uint64_t{0u}
30 , /*decltype(_impl_.version_)*/0u} {}
31 struct TransactionTraceFileDefaultTypeInternal {
TransactionTraceFileDefaultTypeInternalperfetto::protos::TransactionTraceFileDefaultTypeInternal32 PROTOBUF_CONSTEXPR TransactionTraceFileDefaultTypeInternal()
33 : _instance(::_pbi::ConstantInitialized{}) {}
~TransactionTraceFileDefaultTypeInternalperfetto::protos::TransactionTraceFileDefaultTypeInternal34 ~TransactionTraceFileDefaultTypeInternal() {}
35 union { // NOLINT(misc-non-private-member-variables-in-classes)
36 TransactionTraceFile _instance;
37 };
38 };
39 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 TransactionTraceFileDefaultTypeInternal _TransactionTraceFile_default_instance_;
TransactionTraceEntry(::_pbi::ConstantInitialized)40 PROTOBUF_CONSTEXPR TransactionTraceEntry::TransactionTraceEntry(
41 ::_pbi::ConstantInitialized): _impl_{
42 /*decltype(_impl_._has_bits_)*/{}
43 , /*decltype(_impl_._cached_size_)*/{}
44 , /*decltype(_impl_.transactions_)*/{}
45 , /*decltype(_impl_.added_layers_)*/{}
46 , /*decltype(_impl_.destroyed_layers_)*/{}
47 , /*decltype(_impl_.added_displays_)*/{}
48 , /*decltype(_impl_.removed_displays_)*/{}
49 , /*decltype(_impl_.destroyed_layer_handles_)*/{}
50 , /*decltype(_impl_.displays_)*/{}
51 , /*decltype(_impl_.elapsed_realtime_nanos_)*/::int64_t{0}
52 , /*decltype(_impl_.vsync_id_)*/::int64_t{0}
53 , /*decltype(_impl_.displays_changed_)*/false} {}
54 struct TransactionTraceEntryDefaultTypeInternal {
TransactionTraceEntryDefaultTypeInternalperfetto::protos::TransactionTraceEntryDefaultTypeInternal55 PROTOBUF_CONSTEXPR TransactionTraceEntryDefaultTypeInternal()
56 : _instance(::_pbi::ConstantInitialized{}) {}
~TransactionTraceEntryDefaultTypeInternalperfetto::protos::TransactionTraceEntryDefaultTypeInternal57 ~TransactionTraceEntryDefaultTypeInternal() {}
58 union { // NOLINT(misc-non-private-member-variables-in-classes)
59 TransactionTraceEntry _instance;
60 };
61 };
62 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 TransactionTraceEntryDefaultTypeInternal _TransactionTraceEntry_default_instance_;
DisplayInfo(::_pbi::ConstantInitialized)63 PROTOBUF_CONSTEXPR DisplayInfo::DisplayInfo(
64 ::_pbi::ConstantInitialized): _impl_{
65 /*decltype(_impl_._has_bits_)*/{}
66 , /*decltype(_impl_._cached_size_)*/{}
67 , /*decltype(_impl_.transform_inverse_)*/nullptr
68 , /*decltype(_impl_.transform_)*/nullptr
69 , /*decltype(_impl_.layer_stack_)*/0u
70 , /*decltype(_impl_.display_id_)*/0
71 , /*decltype(_impl_.logical_width_)*/0
72 , /*decltype(_impl_.logical_height_)*/0
73 , /*decltype(_impl_.receives_input_)*/false
74 , /*decltype(_impl_.is_secure_)*/false
75 , /*decltype(_impl_.is_primary_)*/false
76 , /*decltype(_impl_.is_virtual_)*/false
77 , /*decltype(_impl_.rotation_flags_)*/0
78 , /*decltype(_impl_.transform_hint_)*/0} {}
79 struct DisplayInfoDefaultTypeInternal {
DisplayInfoDefaultTypeInternalperfetto::protos::DisplayInfoDefaultTypeInternal80 PROTOBUF_CONSTEXPR DisplayInfoDefaultTypeInternal()
81 : _instance(::_pbi::ConstantInitialized{}) {}
~DisplayInfoDefaultTypeInternalperfetto::protos::DisplayInfoDefaultTypeInternal82 ~DisplayInfoDefaultTypeInternal() {}
83 union { // NOLINT(misc-non-private-member-variables-in-classes)
84 DisplayInfo _instance;
85 };
86 };
87 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 DisplayInfoDefaultTypeInternal _DisplayInfo_default_instance_;
LayerCreationArgs(::_pbi::ConstantInitialized)88 PROTOBUF_CONSTEXPR LayerCreationArgs::LayerCreationArgs(
89 ::_pbi::ConstantInitialized): _impl_{
90 /*decltype(_impl_._has_bits_)*/{}
91 , /*decltype(_impl_._cached_size_)*/{}
92 , /*decltype(_impl_.name_)*/{&::_pbi::fixed_address_empty_string, ::_pbi::ConstantInitialized{}}
93 , /*decltype(_impl_.layer_id_)*/0u
94 , /*decltype(_impl_.flags_)*/0u
95 , /*decltype(_impl_.parent_id_)*/0u
96 , /*decltype(_impl_.mirror_from_id_)*/0u
97 , /*decltype(_impl_.add_to_root_)*/false
98 , /*decltype(_impl_.layer_stack_to_mirror_)*/0u} {}
99 struct LayerCreationArgsDefaultTypeInternal {
LayerCreationArgsDefaultTypeInternalperfetto::protos::LayerCreationArgsDefaultTypeInternal100 PROTOBUF_CONSTEXPR LayerCreationArgsDefaultTypeInternal()
101 : _instance(::_pbi::ConstantInitialized{}) {}
~LayerCreationArgsDefaultTypeInternalperfetto::protos::LayerCreationArgsDefaultTypeInternal102 ~LayerCreationArgsDefaultTypeInternal() {}
103 union { // NOLINT(misc-non-private-member-variables-in-classes)
104 LayerCreationArgs _instance;
105 };
106 };
107 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 LayerCreationArgsDefaultTypeInternal _LayerCreationArgs_default_instance_;
Transform(::_pbi::ConstantInitialized)108 PROTOBUF_CONSTEXPR Transform::Transform(
109 ::_pbi::ConstantInitialized): _impl_{
110 /*decltype(_impl_._has_bits_)*/{}
111 , /*decltype(_impl_._cached_size_)*/{}
112 , /*decltype(_impl_.dsdx_)*/0
113 , /*decltype(_impl_.dtdx_)*/0
114 , /*decltype(_impl_.dtdy_)*/0
115 , /*decltype(_impl_.dsdy_)*/0
116 , /*decltype(_impl_.tx_)*/0
117 , /*decltype(_impl_.ty_)*/0} {}
118 struct TransformDefaultTypeInternal {
TransformDefaultTypeInternalperfetto::protos::TransformDefaultTypeInternal119 PROTOBUF_CONSTEXPR TransformDefaultTypeInternal()
120 : _instance(::_pbi::ConstantInitialized{}) {}
~TransformDefaultTypeInternalperfetto::protos::TransformDefaultTypeInternal121 ~TransformDefaultTypeInternal() {}
122 union { // NOLINT(misc-non-private-member-variables-in-classes)
123 Transform _instance;
124 };
125 };
126 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 TransformDefaultTypeInternal _Transform_default_instance_;
TransactionState(::_pbi::ConstantInitialized)127 PROTOBUF_CONSTEXPR TransactionState::TransactionState(
128 ::_pbi::ConstantInitialized): _impl_{
129 /*decltype(_impl_._has_bits_)*/{}
130 , /*decltype(_impl_._cached_size_)*/{}
131 , /*decltype(_impl_.layer_changes_)*/{}
132 , /*decltype(_impl_.display_changes_)*/{}
133 , /*decltype(_impl_.merged_transaction_ids_)*/{}
134 , /*decltype(_impl_.pid_)*/0
135 , /*decltype(_impl_.uid_)*/0
136 , /*decltype(_impl_.vsync_id_)*/::int64_t{0}
137 , /*decltype(_impl_.post_time_)*/::int64_t{0}
138 , /*decltype(_impl_.transaction_id_)*/::uint64_t{0u}
139 , /*decltype(_impl_.input_event_id_)*/0} {}
140 struct TransactionStateDefaultTypeInternal {
TransactionStateDefaultTypeInternalperfetto::protos::TransactionStateDefaultTypeInternal141 PROTOBUF_CONSTEXPR TransactionStateDefaultTypeInternal()
142 : _instance(::_pbi::ConstantInitialized{}) {}
~TransactionStateDefaultTypeInternalperfetto::protos::TransactionStateDefaultTypeInternal143 ~TransactionStateDefaultTypeInternal() {}
144 union { // NOLINT(misc-non-private-member-variables-in-classes)
145 TransactionState _instance;
146 };
147 };
148 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 TransactionStateDefaultTypeInternal _TransactionState_default_instance_;
LayerState_Matrix22(::_pbi::ConstantInitialized)149 PROTOBUF_CONSTEXPR LayerState_Matrix22::LayerState_Matrix22(
150 ::_pbi::ConstantInitialized): _impl_{
151 /*decltype(_impl_._has_bits_)*/{}
152 , /*decltype(_impl_._cached_size_)*/{}
153 , /*decltype(_impl_.dsdx_)*/0
154 , /*decltype(_impl_.dtdx_)*/0
155 , /*decltype(_impl_.dtdy_)*/0
156 , /*decltype(_impl_.dsdy_)*/0} {}
157 struct LayerState_Matrix22DefaultTypeInternal {
LayerState_Matrix22DefaultTypeInternalperfetto::protos::LayerState_Matrix22DefaultTypeInternal158 PROTOBUF_CONSTEXPR LayerState_Matrix22DefaultTypeInternal()
159 : _instance(::_pbi::ConstantInitialized{}) {}
~LayerState_Matrix22DefaultTypeInternalperfetto::protos::LayerState_Matrix22DefaultTypeInternal160 ~LayerState_Matrix22DefaultTypeInternal() {}
161 union { // NOLINT(misc-non-private-member-variables-in-classes)
162 LayerState_Matrix22 _instance;
163 };
164 };
165 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 LayerState_Matrix22DefaultTypeInternal _LayerState_Matrix22_default_instance_;
LayerState_Color3(::_pbi::ConstantInitialized)166 PROTOBUF_CONSTEXPR LayerState_Color3::LayerState_Color3(
167 ::_pbi::ConstantInitialized): _impl_{
168 /*decltype(_impl_._has_bits_)*/{}
169 , /*decltype(_impl_._cached_size_)*/{}
170 , /*decltype(_impl_.r_)*/0
171 , /*decltype(_impl_.g_)*/0
172 , /*decltype(_impl_.b_)*/0} {}
173 struct LayerState_Color3DefaultTypeInternal {
LayerState_Color3DefaultTypeInternalperfetto::protos::LayerState_Color3DefaultTypeInternal174 PROTOBUF_CONSTEXPR LayerState_Color3DefaultTypeInternal()
175 : _instance(::_pbi::ConstantInitialized{}) {}
~LayerState_Color3DefaultTypeInternalperfetto::protos::LayerState_Color3DefaultTypeInternal176 ~LayerState_Color3DefaultTypeInternal() {}
177 union { // NOLINT(misc-non-private-member-variables-in-classes)
178 LayerState_Color3 _instance;
179 };
180 };
181 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 LayerState_Color3DefaultTypeInternal _LayerState_Color3_default_instance_;
LayerState_BufferData(::_pbi::ConstantInitialized)182 PROTOBUF_CONSTEXPR LayerState_BufferData::LayerState_BufferData(
183 ::_pbi::ConstantInitialized): _impl_{
184 /*decltype(_impl_._has_bits_)*/{}
185 , /*decltype(_impl_._cached_size_)*/{}
186 , /*decltype(_impl_.buffer_id_)*/::uint64_t{0u}
187 , /*decltype(_impl_.width_)*/0u
188 , /*decltype(_impl_.height_)*/0u
189 , /*decltype(_impl_.frame_number_)*/::uint64_t{0u}
190 , /*decltype(_impl_.cached_buffer_id_)*/::uint64_t{0u}
191 , /*decltype(_impl_.flags_)*/0u
192 , /*decltype(_impl_.pixel_format_)*/0
193 , /*decltype(_impl_.usage_)*/::uint64_t{0u}} {}
194 struct LayerState_BufferDataDefaultTypeInternal {
LayerState_BufferDataDefaultTypeInternalperfetto::protos::LayerState_BufferDataDefaultTypeInternal195 PROTOBUF_CONSTEXPR LayerState_BufferDataDefaultTypeInternal()
196 : _instance(::_pbi::ConstantInitialized{}) {}
~LayerState_BufferDataDefaultTypeInternalperfetto::protos::LayerState_BufferDataDefaultTypeInternal197 ~LayerState_BufferDataDefaultTypeInternal() {}
198 union { // NOLINT(misc-non-private-member-variables-in-classes)
199 LayerState_BufferData _instance;
200 };
201 };
202 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 LayerState_BufferDataDefaultTypeInternal _LayerState_BufferData_default_instance_;
LayerState_WindowInfo(::_pbi::ConstantInitialized)203 PROTOBUF_CONSTEXPR LayerState_WindowInfo::LayerState_WindowInfo(
204 ::_pbi::ConstantInitialized): _impl_{
205 /*decltype(_impl_._has_bits_)*/{}
206 , /*decltype(_impl_._cached_size_)*/{}
207 , /*decltype(_impl_.touchable_region_)*/nullptr
208 , /*decltype(_impl_.touchable_region_crop_)*/nullptr
209 , /*decltype(_impl_.transform_)*/nullptr
210 , /*decltype(_impl_.layout_params_flags_)*/0u
211 , /*decltype(_impl_.layout_params_type_)*/0
212 , /*decltype(_impl_.surface_inset_)*/0
213 , /*decltype(_impl_.focusable_)*/false
214 , /*decltype(_impl_.has_wallpaper_)*/false
215 , /*decltype(_impl_.replace_touchable_region_with_crop_)*/false
216 , /*decltype(_impl_.global_scale_factor_)*/0
217 , /*decltype(_impl_.crop_layer_id_)*/0u
218 , /*decltype(_impl_.input_config_)*/0u} {}
219 struct LayerState_WindowInfoDefaultTypeInternal {
LayerState_WindowInfoDefaultTypeInternalperfetto::protos::LayerState_WindowInfoDefaultTypeInternal220 PROTOBUF_CONSTEXPR LayerState_WindowInfoDefaultTypeInternal()
221 : _instance(::_pbi::ConstantInitialized{}) {}
~LayerState_WindowInfoDefaultTypeInternalperfetto::protos::LayerState_WindowInfoDefaultTypeInternal222 ~LayerState_WindowInfoDefaultTypeInternal() {}
223 union { // NOLINT(misc-non-private-member-variables-in-classes)
224 LayerState_WindowInfo _instance;
225 };
226 };
227 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 LayerState_WindowInfoDefaultTypeInternal _LayerState_WindowInfo_default_instance_;
LayerState(::_pbi::ConstantInitialized)228 PROTOBUF_CONSTEXPR LayerState::LayerState(
229 ::_pbi::ConstantInitialized): _impl_{
230 /*decltype(_impl_._has_bits_)*/{}
231 , /*decltype(_impl_._cached_size_)*/{}
232 , /*decltype(_impl_.blur_regions_)*/{}
233 , /*decltype(_impl_.matrix_)*/nullptr
234 , /*decltype(_impl_.color_)*/nullptr
235 , /*decltype(_impl_.transparent_region_)*/nullptr
236 , /*decltype(_impl_.crop_)*/nullptr
237 , /*decltype(_impl_.buffer_data_)*/nullptr
238 , /*decltype(_impl_.color_transform_)*/nullptr
239 , /*decltype(_impl_.window_info_handle_)*/nullptr
240 , /*decltype(_impl_.buffer_crop_)*/nullptr
241 , /*decltype(_impl_.destination_frame_)*/nullptr
242 , /*decltype(_impl_.what_)*/::uint64_t{0u}
243 , /*decltype(_impl_.layer_id_)*/0u
244 , /*decltype(_impl_.x_)*/0
245 , /*decltype(_impl_.y_)*/0
246 , /*decltype(_impl_.z_)*/0
247 , /*decltype(_impl_.w_)*/0u
248 , /*decltype(_impl_.h_)*/0u
249 , /*decltype(_impl_.layer_stack_)*/0u
250 , /*decltype(_impl_.flags_)*/0u
251 , /*decltype(_impl_.mask_)*/0u
252 , /*decltype(_impl_.corner_radius_)*/0
253 , /*decltype(_impl_.background_blur_radius_)*/0u
254 , /*decltype(_impl_.parent_id_)*/0u
255 , /*decltype(_impl_.relative_parent_id_)*/0u
256 , /*decltype(_impl_.alpha_)*/0
257 , /*decltype(_impl_.transform_)*/0u
258 , /*decltype(_impl_.api_)*/0
259 , /*decltype(_impl_.bg_color_alpha_)*/0
260 , /*decltype(_impl_.transform_to_display_inverse_)*/false
261 , /*decltype(_impl_.has_sideband_stream_)*/false
262 , /*decltype(_impl_.color_space_agnostic_)*/false
263 , /*decltype(_impl_.auto_refresh_)*/false
264 , /*decltype(_impl_.bg_color_dataspace_)*/0
265 , /*decltype(_impl_.shadow_radius_)*/0
266 , /*decltype(_impl_.frame_rate_selection_priority_)*/0
267 , /*decltype(_impl_.frame_rate_)*/0
268 , /*decltype(_impl_.frame_rate_compatibility_)*/0
269 , /*decltype(_impl_.change_frame_rate_strategy_)*/0
270 , /*decltype(_impl_.frame_number_)*/::uint64_t{0u}
271 , /*decltype(_impl_.fixed_transform_hint_)*/0u
272 , /*decltype(_impl_.is_trusted_overlay_)*/false
273 , /*decltype(_impl_.drop_input_mode_)*/0
274 , /*decltype(_impl_.trusted_overlay_)*/0} {}
275 struct LayerStateDefaultTypeInternal {
LayerStateDefaultTypeInternalperfetto::protos::LayerStateDefaultTypeInternal276 PROTOBUF_CONSTEXPR LayerStateDefaultTypeInternal()
277 : _instance(::_pbi::ConstantInitialized{}) {}
~LayerStateDefaultTypeInternalperfetto::protos::LayerStateDefaultTypeInternal278 ~LayerStateDefaultTypeInternal() {}
279 union { // NOLINT(misc-non-private-member-variables-in-classes)
280 LayerState _instance;
281 };
282 };
283 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 LayerStateDefaultTypeInternal _LayerState_default_instance_;
DisplayState(::_pbi::ConstantInitialized)284 PROTOBUF_CONSTEXPR DisplayState::DisplayState(
285 ::_pbi::ConstantInitialized): _impl_{
286 /*decltype(_impl_._has_bits_)*/{}
287 , /*decltype(_impl_._cached_size_)*/{}
288 , /*decltype(_impl_.layer_stack_space_rect_)*/nullptr
289 , /*decltype(_impl_.oriented_display_space_rect_)*/nullptr
290 , /*decltype(_impl_.id_)*/0
291 , /*decltype(_impl_.what_)*/0u
292 , /*decltype(_impl_.flags_)*/0u
293 , /*decltype(_impl_.layer_stack_)*/0u
294 , /*decltype(_impl_.orientation_)*/0u
295 , /*decltype(_impl_.width_)*/0u
296 , /*decltype(_impl_.height_)*/0u} {}
297 struct DisplayStateDefaultTypeInternal {
DisplayStateDefaultTypeInternalperfetto::protos::DisplayStateDefaultTypeInternal298 PROTOBUF_CONSTEXPR DisplayStateDefaultTypeInternal()
299 : _instance(::_pbi::ConstantInitialized{}) {}
~DisplayStateDefaultTypeInternalperfetto::protos::DisplayStateDefaultTypeInternal300 ~DisplayStateDefaultTypeInternal() {}
301 union { // NOLINT(misc-non-private-member-variables-in-classes)
302 DisplayState _instance;
303 };
304 };
305 PROTOBUF_ATTRIBUTE_NO_DESTROY PROTOBUF_CONSTINIT PROTOBUF_ATTRIBUTE_INIT_PRIORITY1 DisplayStateDefaultTypeInternal _DisplayState_default_instance_;
306 } // namespace protos
307 } // namespace perfetto
308 namespace perfetto {
309 namespace protos {
TransactionTraceFile_MagicNumber_IsValid(int value)310 bool TransactionTraceFile_MagicNumber_IsValid(int value) {
311 switch (value) {
312 case 0:
313 case 1162035538:
314 case 1415073364:
315 return true;
316 default:
317 return false;
318 }
319 }
320
321 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> TransactionTraceFile_MagicNumber_strings[3] = {};
322
323 static const char TransactionTraceFile_MagicNumber_names[] =
324 "INVALID"
325 "MAGIC_NUMBER_H"
326 "MAGIC_NUMBER_L";
327
328 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry TransactionTraceFile_MagicNumber_entries[] = {
329 { {TransactionTraceFile_MagicNumber_names + 0, 7}, 0 },
330 { {TransactionTraceFile_MagicNumber_names + 7, 14}, 1162035538 },
331 { {TransactionTraceFile_MagicNumber_names + 21, 14}, 1415073364 },
332 };
333
334 static const int TransactionTraceFile_MagicNumber_entries_by_number[] = {
335 0, // 0 -> INVALID
336 1, // 1162035538 -> MAGIC_NUMBER_H
337 2, // 1415073364 -> MAGIC_NUMBER_L
338 };
339
TransactionTraceFile_MagicNumber_Name(TransactionTraceFile_MagicNumber value)340 const std::string& TransactionTraceFile_MagicNumber_Name(
341 TransactionTraceFile_MagicNumber value) {
342 static const bool dummy =
343 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
344 TransactionTraceFile_MagicNumber_entries,
345 TransactionTraceFile_MagicNumber_entries_by_number,
346 3, TransactionTraceFile_MagicNumber_strings);
347 (void) dummy;
348 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
349 TransactionTraceFile_MagicNumber_entries,
350 TransactionTraceFile_MagicNumber_entries_by_number,
351 3, value);
352 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
353 TransactionTraceFile_MagicNumber_strings[idx].get();
354 }
TransactionTraceFile_MagicNumber_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,TransactionTraceFile_MagicNumber * value)355 bool TransactionTraceFile_MagicNumber_Parse(
356 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, TransactionTraceFile_MagicNumber* value) {
357 int int_value;
358 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
359 TransactionTraceFile_MagicNumber_entries, 3, name, &int_value);
360 if (success) {
361 *value = static_cast<TransactionTraceFile_MagicNumber>(int_value);
362 }
363 return success;
364 }
365 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
366 constexpr TransactionTraceFile_MagicNumber TransactionTraceFile::INVALID;
367 constexpr TransactionTraceFile_MagicNumber TransactionTraceFile::MAGIC_NUMBER_L;
368 constexpr TransactionTraceFile_MagicNumber TransactionTraceFile::MAGIC_NUMBER_H;
369 constexpr TransactionTraceFile_MagicNumber TransactionTraceFile::MagicNumber_MIN;
370 constexpr TransactionTraceFile_MagicNumber TransactionTraceFile::MagicNumber_MAX;
371 constexpr int TransactionTraceFile::MagicNumber_ARRAYSIZE;
372 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
LayerState_BufferData_BufferDataChange_IsValid(int value)373 bool LayerState_BufferData_BufferDataChange_IsValid(int value) {
374 switch (value) {
375 case 0:
376 case 1:
377 case 2:
378 case 4:
379 return true;
380 default:
381 return false;
382 }
383 }
384
385 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> LayerState_BufferData_BufferDataChange_strings[4] = {};
386
387 static const char LayerState_BufferData_BufferDataChange_names[] =
388 "BufferDataChangeNone"
389 "cachedBufferChanged"
390 "fenceChanged"
391 "frameNumberChanged";
392
393 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry LayerState_BufferData_BufferDataChange_entries[] = {
394 { {LayerState_BufferData_BufferDataChange_names + 0, 20}, 0 },
395 { {LayerState_BufferData_BufferDataChange_names + 20, 19}, 4 },
396 { {LayerState_BufferData_BufferDataChange_names + 39, 12}, 1 },
397 { {LayerState_BufferData_BufferDataChange_names + 51, 18}, 2 },
398 };
399
400 static const int LayerState_BufferData_BufferDataChange_entries_by_number[] = {
401 0, // 0 -> BufferDataChangeNone
402 2, // 1 -> fenceChanged
403 3, // 2 -> frameNumberChanged
404 1, // 4 -> cachedBufferChanged
405 };
406
LayerState_BufferData_BufferDataChange_Name(LayerState_BufferData_BufferDataChange value)407 const std::string& LayerState_BufferData_BufferDataChange_Name(
408 LayerState_BufferData_BufferDataChange value) {
409 static const bool dummy =
410 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
411 LayerState_BufferData_BufferDataChange_entries,
412 LayerState_BufferData_BufferDataChange_entries_by_number,
413 4, LayerState_BufferData_BufferDataChange_strings);
414 (void) dummy;
415 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
416 LayerState_BufferData_BufferDataChange_entries,
417 LayerState_BufferData_BufferDataChange_entries_by_number,
418 4, value);
419 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
420 LayerState_BufferData_BufferDataChange_strings[idx].get();
421 }
LayerState_BufferData_BufferDataChange_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,LayerState_BufferData_BufferDataChange * value)422 bool LayerState_BufferData_BufferDataChange_Parse(
423 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LayerState_BufferData_BufferDataChange* value) {
424 int int_value;
425 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
426 LayerState_BufferData_BufferDataChange_entries, 4, name, &int_value);
427 if (success) {
428 *value = static_cast<LayerState_BufferData_BufferDataChange>(int_value);
429 }
430 return success;
431 }
432 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
433 constexpr LayerState_BufferData_BufferDataChange LayerState_BufferData::BufferDataChangeNone;
434 constexpr LayerState_BufferData_BufferDataChange LayerState_BufferData::fenceChanged;
435 constexpr LayerState_BufferData_BufferDataChange LayerState_BufferData::frameNumberChanged;
436 constexpr LayerState_BufferData_BufferDataChange LayerState_BufferData::cachedBufferChanged;
437 constexpr LayerState_BufferData_BufferDataChange LayerState_BufferData::BufferDataChange_MIN;
438 constexpr LayerState_BufferData_BufferDataChange LayerState_BufferData::BufferDataChange_MAX;
439 constexpr int LayerState_BufferData::BufferDataChange_ARRAYSIZE;
440 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
LayerState_BufferData_PixelFormat_IsValid(int value)441 bool LayerState_BufferData_PixelFormat_IsValid(int value) {
442 switch (value) {
443 case -4:
444 case -3:
445 case -2:
446 case -1:
447 case 0:
448 case 1:
449 case 2:
450 case 3:
451 case 4:
452 case 5:
453 case 6:
454 case 7:
455 case 22:
456 case 43:
457 case 56:
458 return true;
459 default:
460 return false;
461 }
462 }
463
464 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> LayerState_BufferData_PixelFormat_strings[15] = {};
465
466 static const char LayerState_BufferData_PixelFormat_names[] =
467 "PIXEL_FORMAT_BGRA_8888"
468 "PIXEL_FORMAT_CUSTOM"
469 "PIXEL_FORMAT_OPAQUE"
470 "PIXEL_FORMAT_RGBA_1010102"
471 "PIXEL_FORMAT_RGBA_4444"
472 "PIXEL_FORMAT_RGBA_5551"
473 "PIXEL_FORMAT_RGBA_8888"
474 "PIXEL_FORMAT_RGBA_FP16"
475 "PIXEL_FORMAT_RGBX_8888"
476 "PIXEL_FORMAT_RGB_565"
477 "PIXEL_FORMAT_RGB_888"
478 "PIXEL_FORMAT_R_8"
479 "PIXEL_FORMAT_TRANSLUCENT"
480 "PIXEL_FORMAT_TRANSPARENT"
481 "PIXEL_FORMAT_UNKNOWN";
482
483 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry LayerState_BufferData_PixelFormat_entries[] = {
484 { {LayerState_BufferData_PixelFormat_names + 0, 22}, 5 },
485 { {LayerState_BufferData_PixelFormat_names + 22, 19}, -4 },
486 { {LayerState_BufferData_PixelFormat_names + 41, 19}, -1 },
487 { {LayerState_BufferData_PixelFormat_names + 60, 25}, 43 },
488 { {LayerState_BufferData_PixelFormat_names + 85, 22}, 7 },
489 { {LayerState_BufferData_PixelFormat_names + 107, 22}, 6 },
490 { {LayerState_BufferData_PixelFormat_names + 129, 22}, 1 },
491 { {LayerState_BufferData_PixelFormat_names + 151, 22}, 22 },
492 { {LayerState_BufferData_PixelFormat_names + 173, 22}, 2 },
493 { {LayerState_BufferData_PixelFormat_names + 195, 20}, 4 },
494 { {LayerState_BufferData_PixelFormat_names + 215, 20}, 3 },
495 { {LayerState_BufferData_PixelFormat_names + 235, 16}, 56 },
496 { {LayerState_BufferData_PixelFormat_names + 251, 24}, -3 },
497 { {LayerState_BufferData_PixelFormat_names + 275, 24}, -2 },
498 { {LayerState_BufferData_PixelFormat_names + 299, 20}, 0 },
499 };
500
501 static const int LayerState_BufferData_PixelFormat_entries_by_number[] = {
502 1, // -4 -> PIXEL_FORMAT_CUSTOM
503 12, // -3 -> PIXEL_FORMAT_TRANSLUCENT
504 13, // -2 -> PIXEL_FORMAT_TRANSPARENT
505 2, // -1 -> PIXEL_FORMAT_OPAQUE
506 14, // 0 -> PIXEL_FORMAT_UNKNOWN
507 6, // 1 -> PIXEL_FORMAT_RGBA_8888
508 8, // 2 -> PIXEL_FORMAT_RGBX_8888
509 10, // 3 -> PIXEL_FORMAT_RGB_888
510 9, // 4 -> PIXEL_FORMAT_RGB_565
511 0, // 5 -> PIXEL_FORMAT_BGRA_8888
512 5, // 6 -> PIXEL_FORMAT_RGBA_5551
513 4, // 7 -> PIXEL_FORMAT_RGBA_4444
514 7, // 22 -> PIXEL_FORMAT_RGBA_FP16
515 3, // 43 -> PIXEL_FORMAT_RGBA_1010102
516 11, // 56 -> PIXEL_FORMAT_R_8
517 };
518
LayerState_BufferData_PixelFormat_Name(LayerState_BufferData_PixelFormat value)519 const std::string& LayerState_BufferData_PixelFormat_Name(
520 LayerState_BufferData_PixelFormat value) {
521 static const bool dummy =
522 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
523 LayerState_BufferData_PixelFormat_entries,
524 LayerState_BufferData_PixelFormat_entries_by_number,
525 15, LayerState_BufferData_PixelFormat_strings);
526 (void) dummy;
527 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
528 LayerState_BufferData_PixelFormat_entries,
529 LayerState_BufferData_PixelFormat_entries_by_number,
530 15, value);
531 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
532 LayerState_BufferData_PixelFormat_strings[idx].get();
533 }
LayerState_BufferData_PixelFormat_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,LayerState_BufferData_PixelFormat * value)534 bool LayerState_BufferData_PixelFormat_Parse(
535 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LayerState_BufferData_PixelFormat* value) {
536 int int_value;
537 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
538 LayerState_BufferData_PixelFormat_entries, 15, name, &int_value);
539 if (success) {
540 *value = static_cast<LayerState_BufferData_PixelFormat>(int_value);
541 }
542 return success;
543 }
544 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
545 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_UNKNOWN;
546 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_CUSTOM;
547 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_TRANSLUCENT;
548 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_TRANSPARENT;
549 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_OPAQUE;
550 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_RGBA_8888;
551 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_RGBX_8888;
552 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_RGB_888;
553 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_RGB_565;
554 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_BGRA_8888;
555 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_RGBA_5551;
556 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_RGBA_4444;
557 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_RGBA_FP16;
558 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_RGBA_1010102;
559 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PIXEL_FORMAT_R_8;
560 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PixelFormat_MIN;
561 constexpr LayerState_BufferData_PixelFormat LayerState_BufferData::PixelFormat_MAX;
562 constexpr int LayerState_BufferData::PixelFormat_ARRAYSIZE;
563 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
LayerState_ChangesLsb_IsValid(int value)564 bool LayerState_ChangesLsb_IsValid(int value) {
565 switch (value) {
566 case -2147483647 - 1:
567 case 0:
568 case 1:
569 case 2:
570 case 8:
571 case 16:
572 case 32:
573 case 64:
574 case 128:
575 case 1024:
576 case 2048:
577 case 8192:
578 case 16384:
579 case 32768:
580 case 65536:
581 case 262144:
582 case 524288:
583 case 1048576:
584 case 2097152:
585 case 4194304:
586 case 8388608:
587 case 16777216:
588 case 33554432:
589 case 67108864:
590 case 134217728:
591 case 268435456:
592 case 536870912:
593 case 1073741824:
594 return true;
595 default:
596 return false;
597 }
598 }
599
600 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> LayerState_ChangesLsb_strings[28] = {};
601
602 static const char LayerState_ChangesLsb_names[] =
603 "eAcquireFenceChanged"
604 "eAlphaChanged"
605 "eApiChanged"
606 "eBufferChanged"
607 "eBufferCropChanged"
608 "eBufferTransformChanged"
609 "eChangesLsbNone"
610 "eColorChanged"
611 "eColorTransformChanged"
612 "eCornerRadiusChanged"
613 "eCropChanged"
614 "eDataspaceChanged"
615 "eFlagsChanged"
616 "eHasListenerCallbacksChanged"
617 "eHdrMetadataChanged"
618 "eInputInfoChanged"
619 "eLayerChanged"
620 "eLayerStackChanged"
621 "eMatrixChanged"
622 "ePositionChanged"
623 "eRelativeLayerChanged"
624 "eReleaseBufferListenerChanged"
625 "eReparent"
626 "eShadowRadiusChanged"
627 "eSidebandStreamChanged"
628 "eSurfaceDamageRegionChanged"
629 "eTransformToDisplayInverseChanged"
630 "eTransparentRegionChanged";
631
632 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry LayerState_ChangesLsb_entries[] = {
633 { {LayerState_ChangesLsb_names + 0, 20}, 4194304 },
634 { {LayerState_ChangesLsb_names + 20, 13}, 8 },
635 { {LayerState_ChangesLsb_names + 33, 11}, 67108864 },
636 { {LayerState_ChangesLsb_names + 44, 14}, 2097152 },
637 { {LayerState_ChangesLsb_names + 58, 18}, 8192 },
638 { {LayerState_ChangesLsb_names + 76, 23}, 262144 },
639 { {LayerState_ChangesLsb_names + 99, 15}, 0 },
640 { {LayerState_ChangesLsb_names + 114, 13}, 65536 },
641 { {LayerState_ChangesLsb_names + 127, 22}, 268435456 },
642 { {LayerState_ChangesLsb_names + 149, 20}, -2147483648 },
643 { {LayerState_ChangesLsb_names + 169, 12}, 1048576 },
644 { {LayerState_ChangesLsb_names + 181, 17}, 8388608 },
645 { {LayerState_ChangesLsb_names + 198, 13}, 64 },
646 { {LayerState_ChangesLsb_names + 211, 28}, 536870912 },
647 { {LayerState_ChangesLsb_names + 239, 19}, 16777216 },
648 { {LayerState_ChangesLsb_names + 258, 17}, 1073741824 },
649 { {LayerState_ChangesLsb_names + 275, 13}, 2 },
650 { {LayerState_ChangesLsb_names + 288, 18}, 128 },
651 { {LayerState_ChangesLsb_names + 306, 14}, 16 },
652 { {LayerState_ChangesLsb_names + 320, 16}, 1 },
653 { {LayerState_ChangesLsb_names + 336, 21}, 16384 },
654 { {LayerState_ChangesLsb_names + 357, 29}, 1024 },
655 { {LayerState_ChangesLsb_names + 386, 9}, 32768 },
656 { {LayerState_ChangesLsb_names + 395, 20}, 2048 },
657 { {LayerState_ChangesLsb_names + 415, 22}, 134217728 },
658 { {LayerState_ChangesLsb_names + 437, 27}, 33554432 },
659 { {LayerState_ChangesLsb_names + 464, 33}, 524288 },
660 { {LayerState_ChangesLsb_names + 497, 25}, 32 },
661 };
662
663 static const int LayerState_ChangesLsb_entries_by_number[] = {
664 9, // -2147483648 -> eCornerRadiusChanged
665 6, // 0 -> eChangesLsbNone
666 19, // 1 -> ePositionChanged
667 16, // 2 -> eLayerChanged
668 1, // 8 -> eAlphaChanged
669 18, // 16 -> eMatrixChanged
670 27, // 32 -> eTransparentRegionChanged
671 12, // 64 -> eFlagsChanged
672 17, // 128 -> eLayerStackChanged
673 21, // 1024 -> eReleaseBufferListenerChanged
674 23, // 2048 -> eShadowRadiusChanged
675 4, // 8192 -> eBufferCropChanged
676 20, // 16384 -> eRelativeLayerChanged
677 22, // 32768 -> eReparent
678 7, // 65536 -> eColorChanged
679 5, // 262144 -> eBufferTransformChanged
680 26, // 524288 -> eTransformToDisplayInverseChanged
681 10, // 1048576 -> eCropChanged
682 3, // 2097152 -> eBufferChanged
683 0, // 4194304 -> eAcquireFenceChanged
684 11, // 8388608 -> eDataspaceChanged
685 14, // 16777216 -> eHdrMetadataChanged
686 25, // 33554432 -> eSurfaceDamageRegionChanged
687 2, // 67108864 -> eApiChanged
688 24, // 134217728 -> eSidebandStreamChanged
689 8, // 268435456 -> eColorTransformChanged
690 13, // 536870912 -> eHasListenerCallbacksChanged
691 15, // 1073741824 -> eInputInfoChanged
692 };
693
LayerState_ChangesLsb_Name(LayerState_ChangesLsb value)694 const std::string& LayerState_ChangesLsb_Name(
695 LayerState_ChangesLsb value) {
696 static const bool dummy =
697 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
698 LayerState_ChangesLsb_entries,
699 LayerState_ChangesLsb_entries_by_number,
700 28, LayerState_ChangesLsb_strings);
701 (void) dummy;
702 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
703 LayerState_ChangesLsb_entries,
704 LayerState_ChangesLsb_entries_by_number,
705 28, value);
706 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
707 LayerState_ChangesLsb_strings[idx].get();
708 }
LayerState_ChangesLsb_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,LayerState_ChangesLsb * value)709 bool LayerState_ChangesLsb_Parse(
710 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LayerState_ChangesLsb* value) {
711 int int_value;
712 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
713 LayerState_ChangesLsb_entries, 28, name, &int_value);
714 if (success) {
715 *value = static_cast<LayerState_ChangesLsb>(int_value);
716 }
717 return success;
718 }
719 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
720 constexpr LayerState_ChangesLsb LayerState::eChangesLsbNone;
721 constexpr LayerState_ChangesLsb LayerState::ePositionChanged;
722 constexpr LayerState_ChangesLsb LayerState::eLayerChanged;
723 constexpr LayerState_ChangesLsb LayerState::eAlphaChanged;
724 constexpr LayerState_ChangesLsb LayerState::eMatrixChanged;
725 constexpr LayerState_ChangesLsb LayerState::eTransparentRegionChanged;
726 constexpr LayerState_ChangesLsb LayerState::eFlagsChanged;
727 constexpr LayerState_ChangesLsb LayerState::eLayerStackChanged;
728 constexpr LayerState_ChangesLsb LayerState::eReleaseBufferListenerChanged;
729 constexpr LayerState_ChangesLsb LayerState::eShadowRadiusChanged;
730 constexpr LayerState_ChangesLsb LayerState::eBufferCropChanged;
731 constexpr LayerState_ChangesLsb LayerState::eRelativeLayerChanged;
732 constexpr LayerState_ChangesLsb LayerState::eReparent;
733 constexpr LayerState_ChangesLsb LayerState::eColorChanged;
734 constexpr LayerState_ChangesLsb LayerState::eBufferTransformChanged;
735 constexpr LayerState_ChangesLsb LayerState::eTransformToDisplayInverseChanged;
736 constexpr LayerState_ChangesLsb LayerState::eCropChanged;
737 constexpr LayerState_ChangesLsb LayerState::eBufferChanged;
738 constexpr LayerState_ChangesLsb LayerState::eAcquireFenceChanged;
739 constexpr LayerState_ChangesLsb LayerState::eDataspaceChanged;
740 constexpr LayerState_ChangesLsb LayerState::eHdrMetadataChanged;
741 constexpr LayerState_ChangesLsb LayerState::eSurfaceDamageRegionChanged;
742 constexpr LayerState_ChangesLsb LayerState::eApiChanged;
743 constexpr LayerState_ChangesLsb LayerState::eSidebandStreamChanged;
744 constexpr LayerState_ChangesLsb LayerState::eColorTransformChanged;
745 constexpr LayerState_ChangesLsb LayerState::eHasListenerCallbacksChanged;
746 constexpr LayerState_ChangesLsb LayerState::eInputInfoChanged;
747 constexpr LayerState_ChangesLsb LayerState::eCornerRadiusChanged;
748 constexpr LayerState_ChangesLsb LayerState::ChangesLsb_MIN;
749 constexpr LayerState_ChangesLsb LayerState::ChangesLsb_MAX;
750 constexpr int LayerState::ChangesLsb_ARRAYSIZE;
751 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
LayerState_ChangesMsb_IsValid(int value)752 bool LayerState_ChangesMsb_IsValid(int value) {
753 switch (value) {
754 case 0:
755 case 1:
756 case 2:
757 case 4:
758 case 8:
759 case 16:
760 case 32:
761 case 64:
762 case 128:
763 case 256:
764 case 512:
765 case 1024:
766 case 2048:
767 case 4096:
768 case 8192:
769 case 16384:
770 case 32768:
771 return true;
772 default:
773 return false;
774 }
775 }
776
777 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> LayerState_ChangesMsb_strings[17] = {};
778
779 static const char LayerState_ChangesMsb_names[] =
780 "eAutoRefreshChanged"
781 "eBackgroundBlurRadiusChanged"
782 "eBackgroundColorChanged"
783 "eBlurRegionsChanged"
784 "eCachedBufferChanged"
785 "eChangesMsbNone"
786 "eColorSpaceAgnosticChanged"
787 "eDestinationFrameChanged"
788 "eDropInputModeChanged"
789 "eFixedTransformHintChanged"
790 "eFrameNumberChanged"
791 "eFrameRateChanged"
792 "eFrameRateSelectionPriority"
793 "eMetadataChanged"
794 "eProducerDisconnect"
795 "eStretchChanged"
796 "eTrustedOverlayChanged";
797
798 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry LayerState_ChangesMsb_entries[] = {
799 { {LayerState_ChangesMsb_names + 0, 19}, 4096 },
800 { {LayerState_ChangesMsb_names + 19, 28}, 128 },
801 { {LayerState_ChangesMsb_names + 47, 23}, 4 },
802 { {LayerState_ChangesMsb_names + 70, 19}, 2048 },
803 { {LayerState_ChangesMsb_names + 89, 20}, 2 },
804 { {LayerState_ChangesMsb_names + 109, 15}, 0 },
805 { {LayerState_ChangesMsb_names + 124, 26}, 16 },
806 { {LayerState_ChangesMsb_names + 150, 24}, 1 },
807 { {LayerState_ChangesMsb_names + 174, 21}, 32768 },
808 { {LayerState_ChangesMsb_names + 195, 26}, 512 },
809 { {LayerState_ChangesMsb_names + 221, 19}, 1024 },
810 { {LayerState_ChangesMsb_names + 240, 17}, 64 },
811 { {LayerState_ChangesMsb_names + 257, 27}, 32 },
812 { {LayerState_ChangesMsb_names + 284, 16}, 8 },
813 { {LayerState_ChangesMsb_names + 300, 19}, 256 },
814 { {LayerState_ChangesMsb_names + 319, 15}, 8192 },
815 { {LayerState_ChangesMsb_names + 334, 22}, 16384 },
816 };
817
818 static const int LayerState_ChangesMsb_entries_by_number[] = {
819 5, // 0 -> eChangesMsbNone
820 7, // 1 -> eDestinationFrameChanged
821 4, // 2 -> eCachedBufferChanged
822 2, // 4 -> eBackgroundColorChanged
823 13, // 8 -> eMetadataChanged
824 6, // 16 -> eColorSpaceAgnosticChanged
825 12, // 32 -> eFrameRateSelectionPriority
826 11, // 64 -> eFrameRateChanged
827 1, // 128 -> eBackgroundBlurRadiusChanged
828 14, // 256 -> eProducerDisconnect
829 9, // 512 -> eFixedTransformHintChanged
830 10, // 1024 -> eFrameNumberChanged
831 3, // 2048 -> eBlurRegionsChanged
832 0, // 4096 -> eAutoRefreshChanged
833 15, // 8192 -> eStretchChanged
834 16, // 16384 -> eTrustedOverlayChanged
835 8, // 32768 -> eDropInputModeChanged
836 };
837
LayerState_ChangesMsb_Name(LayerState_ChangesMsb value)838 const std::string& LayerState_ChangesMsb_Name(
839 LayerState_ChangesMsb value) {
840 static const bool dummy =
841 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
842 LayerState_ChangesMsb_entries,
843 LayerState_ChangesMsb_entries_by_number,
844 17, LayerState_ChangesMsb_strings);
845 (void) dummy;
846 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
847 LayerState_ChangesMsb_entries,
848 LayerState_ChangesMsb_entries_by_number,
849 17, value);
850 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
851 LayerState_ChangesMsb_strings[idx].get();
852 }
LayerState_ChangesMsb_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,LayerState_ChangesMsb * value)853 bool LayerState_ChangesMsb_Parse(
854 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LayerState_ChangesMsb* value) {
855 int int_value;
856 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
857 LayerState_ChangesMsb_entries, 17, name, &int_value);
858 if (success) {
859 *value = static_cast<LayerState_ChangesMsb>(int_value);
860 }
861 return success;
862 }
863 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
864 constexpr LayerState_ChangesMsb LayerState::eChangesMsbNone;
865 constexpr LayerState_ChangesMsb LayerState::eDestinationFrameChanged;
866 constexpr LayerState_ChangesMsb LayerState::eCachedBufferChanged;
867 constexpr LayerState_ChangesMsb LayerState::eBackgroundColorChanged;
868 constexpr LayerState_ChangesMsb LayerState::eMetadataChanged;
869 constexpr LayerState_ChangesMsb LayerState::eColorSpaceAgnosticChanged;
870 constexpr LayerState_ChangesMsb LayerState::eFrameRateSelectionPriority;
871 constexpr LayerState_ChangesMsb LayerState::eFrameRateChanged;
872 constexpr LayerState_ChangesMsb LayerState::eBackgroundBlurRadiusChanged;
873 constexpr LayerState_ChangesMsb LayerState::eProducerDisconnect;
874 constexpr LayerState_ChangesMsb LayerState::eFixedTransformHintChanged;
875 constexpr LayerState_ChangesMsb LayerState::eFrameNumberChanged;
876 constexpr LayerState_ChangesMsb LayerState::eBlurRegionsChanged;
877 constexpr LayerState_ChangesMsb LayerState::eAutoRefreshChanged;
878 constexpr LayerState_ChangesMsb LayerState::eStretchChanged;
879 constexpr LayerState_ChangesMsb LayerState::eTrustedOverlayChanged;
880 constexpr LayerState_ChangesMsb LayerState::eDropInputModeChanged;
881 constexpr LayerState_ChangesMsb LayerState::ChangesMsb_MIN;
882 constexpr LayerState_ChangesMsb LayerState::ChangesMsb_MAX;
883 constexpr int LayerState::ChangesMsb_ARRAYSIZE;
884 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
LayerState_Flags_IsValid(int value)885 bool LayerState_Flags_IsValid(int value) {
886 switch (value) {
887 case 0:
888 case 1:
889 case 2:
890 case 64:
891 case 128:
892 case 256:
893 case 512:
894 return true;
895 default:
896 return false;
897 }
898 }
899
900 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> LayerState_Flags_strings[7] = {};
901
902 static const char LayerState_Flags_names[] =
903 "eEnableBackpressure"
904 "eFlagsNone"
905 "eLayerHidden"
906 "eLayerIsDisplayDecoration"
907 "eLayerOpaque"
908 "eLayerSecure"
909 "eLayerSkipScreenshot";
910
911 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry LayerState_Flags_entries[] = {
912 { {LayerState_Flags_names + 0, 19}, 256 },
913 { {LayerState_Flags_names + 19, 10}, 0 },
914 { {LayerState_Flags_names + 29, 12}, 1 },
915 { {LayerState_Flags_names + 41, 25}, 512 },
916 { {LayerState_Flags_names + 66, 12}, 2 },
917 { {LayerState_Flags_names + 78, 12}, 128 },
918 { {LayerState_Flags_names + 90, 20}, 64 },
919 };
920
921 static const int LayerState_Flags_entries_by_number[] = {
922 1, // 0 -> eFlagsNone
923 2, // 1 -> eLayerHidden
924 4, // 2 -> eLayerOpaque
925 6, // 64 -> eLayerSkipScreenshot
926 5, // 128 -> eLayerSecure
927 0, // 256 -> eEnableBackpressure
928 3, // 512 -> eLayerIsDisplayDecoration
929 };
930
LayerState_Flags_Name(LayerState_Flags value)931 const std::string& LayerState_Flags_Name(
932 LayerState_Flags value) {
933 static const bool dummy =
934 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
935 LayerState_Flags_entries,
936 LayerState_Flags_entries_by_number,
937 7, LayerState_Flags_strings);
938 (void) dummy;
939 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
940 LayerState_Flags_entries,
941 LayerState_Flags_entries_by_number,
942 7, value);
943 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
944 LayerState_Flags_strings[idx].get();
945 }
LayerState_Flags_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,LayerState_Flags * value)946 bool LayerState_Flags_Parse(
947 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LayerState_Flags* value) {
948 int int_value;
949 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
950 LayerState_Flags_entries, 7, name, &int_value);
951 if (success) {
952 *value = static_cast<LayerState_Flags>(int_value);
953 }
954 return success;
955 }
956 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
957 constexpr LayerState_Flags LayerState::eFlagsNone;
958 constexpr LayerState_Flags LayerState::eLayerHidden;
959 constexpr LayerState_Flags LayerState::eLayerOpaque;
960 constexpr LayerState_Flags LayerState::eLayerSkipScreenshot;
961 constexpr LayerState_Flags LayerState::eLayerSecure;
962 constexpr LayerState_Flags LayerState::eEnableBackpressure;
963 constexpr LayerState_Flags LayerState::eLayerIsDisplayDecoration;
964 constexpr LayerState_Flags LayerState::Flags_MIN;
965 constexpr LayerState_Flags LayerState::Flags_MAX;
966 constexpr int LayerState::Flags_ARRAYSIZE;
967 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
LayerState_DropInputMode_IsValid(int value)968 bool LayerState_DropInputMode_IsValid(int value) {
969 switch (value) {
970 case 0:
971 case 1:
972 case 2:
973 return true;
974 default:
975 return false;
976 }
977 }
978
979 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> LayerState_DropInputMode_strings[3] = {};
980
981 static const char LayerState_DropInputMode_names[] =
982 "ALL"
983 "NONE"
984 "OBSCURED";
985
986 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry LayerState_DropInputMode_entries[] = {
987 { {LayerState_DropInputMode_names + 0, 3}, 1 },
988 { {LayerState_DropInputMode_names + 3, 4}, 0 },
989 { {LayerState_DropInputMode_names + 7, 8}, 2 },
990 };
991
992 static const int LayerState_DropInputMode_entries_by_number[] = {
993 1, // 0 -> NONE
994 0, // 1 -> ALL
995 2, // 2 -> OBSCURED
996 };
997
LayerState_DropInputMode_Name(LayerState_DropInputMode value)998 const std::string& LayerState_DropInputMode_Name(
999 LayerState_DropInputMode value) {
1000 static const bool dummy =
1001 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
1002 LayerState_DropInputMode_entries,
1003 LayerState_DropInputMode_entries_by_number,
1004 3, LayerState_DropInputMode_strings);
1005 (void) dummy;
1006 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
1007 LayerState_DropInputMode_entries,
1008 LayerState_DropInputMode_entries_by_number,
1009 3, value);
1010 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
1011 LayerState_DropInputMode_strings[idx].get();
1012 }
LayerState_DropInputMode_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,LayerState_DropInputMode * value)1013 bool LayerState_DropInputMode_Parse(
1014 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, LayerState_DropInputMode* value) {
1015 int int_value;
1016 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
1017 LayerState_DropInputMode_entries, 3, name, &int_value);
1018 if (success) {
1019 *value = static_cast<LayerState_DropInputMode>(int_value);
1020 }
1021 return success;
1022 }
1023 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
1024 constexpr LayerState_DropInputMode LayerState::NONE;
1025 constexpr LayerState_DropInputMode LayerState::ALL;
1026 constexpr LayerState_DropInputMode LayerState::OBSCURED;
1027 constexpr LayerState_DropInputMode LayerState::DropInputMode_MIN;
1028 constexpr LayerState_DropInputMode LayerState::DropInputMode_MAX;
1029 constexpr int LayerState::DropInputMode_ARRAYSIZE;
1030 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
DisplayState_Changes_IsValid(int value)1031 bool DisplayState_Changes_IsValid(int value) {
1032 switch (value) {
1033 case 0:
1034 case 1:
1035 case 2:
1036 case 4:
1037 case 8:
1038 case 16:
1039 return true;
1040 default:
1041 return false;
1042 }
1043 }
1044
1045 static ::PROTOBUF_NAMESPACE_ID::internal::ExplicitlyConstructed<std::string> DisplayState_Changes_strings[6] = {};
1046
1047 static const char DisplayState_Changes_names[] =
1048 "eChangesNone"
1049 "eDisplayProjectionChanged"
1050 "eDisplaySizeChanged"
1051 "eFlagsChanged"
1052 "eLayerStackChanged"
1053 "eSurfaceChanged";
1054
1055 static const ::PROTOBUF_NAMESPACE_ID::internal::EnumEntry DisplayState_Changes_entries[] = {
1056 { {DisplayState_Changes_names + 0, 12}, 0 },
1057 { {DisplayState_Changes_names + 12, 25}, 4 },
1058 { {DisplayState_Changes_names + 37, 19}, 8 },
1059 { {DisplayState_Changes_names + 56, 13}, 16 },
1060 { {DisplayState_Changes_names + 69, 18}, 2 },
1061 { {DisplayState_Changes_names + 87, 15}, 1 },
1062 };
1063
1064 static const int DisplayState_Changes_entries_by_number[] = {
1065 0, // 0 -> eChangesNone
1066 5, // 1 -> eSurfaceChanged
1067 4, // 2 -> eLayerStackChanged
1068 1, // 4 -> eDisplayProjectionChanged
1069 2, // 8 -> eDisplaySizeChanged
1070 3, // 16 -> eFlagsChanged
1071 };
1072
DisplayState_Changes_Name(DisplayState_Changes value)1073 const std::string& DisplayState_Changes_Name(
1074 DisplayState_Changes value) {
1075 static const bool dummy =
1076 ::PROTOBUF_NAMESPACE_ID::internal::InitializeEnumStrings(
1077 DisplayState_Changes_entries,
1078 DisplayState_Changes_entries_by_number,
1079 6, DisplayState_Changes_strings);
1080 (void) dummy;
1081 int idx = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumName(
1082 DisplayState_Changes_entries,
1083 DisplayState_Changes_entries_by_number,
1084 6, value);
1085 return idx == -1 ? ::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString() :
1086 DisplayState_Changes_strings[idx].get();
1087 }
DisplayState_Changes_Parse(::PROTOBUF_NAMESPACE_ID::ConstStringParam name,DisplayState_Changes * value)1088 bool DisplayState_Changes_Parse(
1089 ::PROTOBUF_NAMESPACE_ID::ConstStringParam name, DisplayState_Changes* value) {
1090 int int_value;
1091 bool success = ::PROTOBUF_NAMESPACE_ID::internal::LookUpEnumValue(
1092 DisplayState_Changes_entries, 6, name, &int_value);
1093 if (success) {
1094 *value = static_cast<DisplayState_Changes>(int_value);
1095 }
1096 return success;
1097 }
1098 #if (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
1099 constexpr DisplayState_Changes DisplayState::eChangesNone;
1100 constexpr DisplayState_Changes DisplayState::eSurfaceChanged;
1101 constexpr DisplayState_Changes DisplayState::eLayerStackChanged;
1102 constexpr DisplayState_Changes DisplayState::eDisplayProjectionChanged;
1103 constexpr DisplayState_Changes DisplayState::eDisplaySizeChanged;
1104 constexpr DisplayState_Changes DisplayState::eFlagsChanged;
1105 constexpr DisplayState_Changes DisplayState::Changes_MIN;
1106 constexpr DisplayState_Changes DisplayState::Changes_MAX;
1107 constexpr int DisplayState::Changes_ARRAYSIZE;
1108 #endif // (__cplusplus < 201703) && (!defined(_MSC_VER) || (_MSC_VER >= 1900 && _MSC_VER < 1912))
1109
1110 // ===================================================================
1111
1112 class TransactionTraceFile::_Internal {
1113 public:
1114 using HasBits = decltype(std::declval<TransactionTraceFile>()._impl_._has_bits_);
set_has_magic_number(HasBits * has_bits)1115 static void set_has_magic_number(HasBits* has_bits) {
1116 (*has_bits)[0] |= 1u;
1117 }
set_has_real_to_elapsed_time_offset_nanos(HasBits * has_bits)1118 static void set_has_real_to_elapsed_time_offset_nanos(HasBits* has_bits) {
1119 (*has_bits)[0] |= 2u;
1120 }
set_has_version(HasBits * has_bits)1121 static void set_has_version(HasBits* has_bits) {
1122 (*has_bits)[0] |= 4u;
1123 }
1124 };
1125
TransactionTraceFile(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)1126 TransactionTraceFile::TransactionTraceFile(::PROTOBUF_NAMESPACE_ID::Arena* arena,
1127 bool is_message_owned)
1128 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
1129 SharedCtor(arena, is_message_owned);
1130 // @@protoc_insertion_point(arena_constructor:perfetto.protos.TransactionTraceFile)
1131 }
TransactionTraceFile(const TransactionTraceFile & from)1132 TransactionTraceFile::TransactionTraceFile(const TransactionTraceFile& from)
1133 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
1134 TransactionTraceFile* const _this = this; (void)_this;
1135 new (&_impl_) Impl_{
1136 decltype(_impl_._has_bits_){from._impl_._has_bits_}
1137 , /*decltype(_impl_._cached_size_)*/{}
1138 , decltype(_impl_.entry_){from._impl_.entry_}
1139 , decltype(_impl_.magic_number_){}
1140 , decltype(_impl_.real_to_elapsed_time_offset_nanos_){}
1141 , decltype(_impl_.version_){}};
1142
1143 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
1144 ::memcpy(&_impl_.magic_number_, &from._impl_.magic_number_,
1145 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.version_) -
1146 reinterpret_cast<char*>(&_impl_.magic_number_)) + sizeof(_impl_.version_));
1147 // @@protoc_insertion_point(copy_constructor:perfetto.protos.TransactionTraceFile)
1148 }
1149
SharedCtor(::_pb::Arena * arena,bool is_message_owned)1150 inline void TransactionTraceFile::SharedCtor(
1151 ::_pb::Arena* arena, bool is_message_owned) {
1152 (void)arena;
1153 (void)is_message_owned;
1154 new (&_impl_) Impl_{
1155 decltype(_impl_._has_bits_){}
1156 , /*decltype(_impl_._cached_size_)*/{}
1157 , decltype(_impl_.entry_){arena}
1158 , decltype(_impl_.magic_number_){::uint64_t{0u}}
1159 , decltype(_impl_.real_to_elapsed_time_offset_nanos_){::uint64_t{0u}}
1160 , decltype(_impl_.version_){0u}
1161 };
1162 }
1163
~TransactionTraceFile()1164 TransactionTraceFile::~TransactionTraceFile() {
1165 // @@protoc_insertion_point(destructor:perfetto.protos.TransactionTraceFile)
1166 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
1167 (void)arena;
1168 return;
1169 }
1170 SharedDtor();
1171 }
1172
SharedDtor()1173 inline void TransactionTraceFile::SharedDtor() {
1174 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
1175 _impl_.entry_.~RepeatedPtrField();
1176 }
1177
SetCachedSize(int size) const1178 void TransactionTraceFile::SetCachedSize(int size) const {
1179 _impl_._cached_size_.Set(size);
1180 }
1181
Clear()1182 void TransactionTraceFile::Clear() {
1183 // @@protoc_insertion_point(message_clear_start:perfetto.protos.TransactionTraceFile)
1184 ::uint32_t cached_has_bits = 0;
1185 // Prevent compiler warnings about cached_has_bits being unused
1186 (void) cached_has_bits;
1187
1188 _impl_.entry_.Clear();
1189 cached_has_bits = _impl_._has_bits_[0];
1190 if (cached_has_bits & 0x00000007u) {
1191 ::memset(&_impl_.magic_number_, 0, static_cast<size_t>(
1192 reinterpret_cast<char*>(&_impl_.version_) -
1193 reinterpret_cast<char*>(&_impl_.magic_number_)) + sizeof(_impl_.version_));
1194 }
1195 _impl_._has_bits_.Clear();
1196 _internal_metadata_.Clear<std::string>();
1197 }
1198
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)1199 const char* TransactionTraceFile::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
1200 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
1201 _Internal::HasBits has_bits{};
1202 while (!ctx->Done(&ptr)) {
1203 ::uint32_t tag;
1204 ptr = ::_pbi::ReadTag(ptr, &tag);
1205 switch (tag >> 3) {
1206 // optional fixed64 magic_number = 1;
1207 case 1:
1208 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 9)) {
1209 _Internal::set_has_magic_number(&has_bits);
1210 _impl_.magic_number_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<::uint64_t>(ptr);
1211 ptr += sizeof(::uint64_t);
1212 } else {
1213 goto handle_unusual;
1214 }
1215 continue;
1216 // repeated .perfetto.protos.TransactionTraceEntry entry = 2;
1217 case 2:
1218 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
1219 ptr -= 1;
1220 do {
1221 ptr += 1;
1222 ptr = ctx->ParseMessage(_internal_add_entry(), ptr);
1223 CHK_(ptr);
1224 if (!ctx->DataAvailable(ptr)) break;
1225 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<18>(ptr));
1226 } else {
1227 goto handle_unusual;
1228 }
1229 continue;
1230 // optional fixed64 real_to_elapsed_time_offset_nanos = 3;
1231 case 3:
1232 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 25)) {
1233 _Internal::set_has_real_to_elapsed_time_offset_nanos(&has_bits);
1234 _impl_.real_to_elapsed_time_offset_nanos_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<::uint64_t>(ptr);
1235 ptr += sizeof(::uint64_t);
1236 } else {
1237 goto handle_unusual;
1238 }
1239 continue;
1240 // optional uint32 version = 4;
1241 case 4:
1242 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
1243 _Internal::set_has_version(&has_bits);
1244 _impl_.version_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
1245 CHK_(ptr);
1246 } else {
1247 goto handle_unusual;
1248 }
1249 continue;
1250 default:
1251 goto handle_unusual;
1252 } // switch
1253 handle_unusual:
1254 if ((tag == 0) || ((tag & 7) == 4)) {
1255 CHK_(ptr);
1256 ctx->SetLastTag(tag);
1257 goto message_done;
1258 }
1259 ptr = UnknownFieldParse(
1260 tag,
1261 _internal_metadata_.mutable_unknown_fields<std::string>(),
1262 ptr, ctx);
1263 CHK_(ptr != nullptr);
1264 } // while
1265 message_done:
1266 _impl_._has_bits_.Or(has_bits);
1267 return ptr;
1268 failure:
1269 ptr = nullptr;
1270 goto message_done;
1271 #undef CHK_
1272 }
1273
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const1274 ::uint8_t* TransactionTraceFile::_InternalSerialize(
1275 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
1276 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.TransactionTraceFile)
1277 ::uint32_t cached_has_bits = 0;
1278 (void) cached_has_bits;
1279
1280 cached_has_bits = _impl_._has_bits_[0];
1281 // optional fixed64 magic_number = 1;
1282 if (cached_has_bits & 0x00000001u) {
1283 target = stream->EnsureSpace(target);
1284 target = ::_pbi::WireFormatLite::WriteFixed64ToArray(1, this->_internal_magic_number(), target);
1285 }
1286
1287 // repeated .perfetto.protos.TransactionTraceEntry entry = 2;
1288 for (unsigned i = 0,
1289 n = static_cast<unsigned>(this->_internal_entry_size()); i < n; i++) {
1290 const auto& repfield = this->_internal_entry(i);
1291 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1292 InternalWriteMessage(2, repfield, repfield.GetCachedSize(), target, stream);
1293 }
1294
1295 // optional fixed64 real_to_elapsed_time_offset_nanos = 3;
1296 if (cached_has_bits & 0x00000002u) {
1297 target = stream->EnsureSpace(target);
1298 target = ::_pbi::WireFormatLite::WriteFixed64ToArray(3, this->_internal_real_to_elapsed_time_offset_nanos(), target);
1299 }
1300
1301 // optional uint32 version = 4;
1302 if (cached_has_bits & 0x00000004u) {
1303 target = stream->EnsureSpace(target);
1304 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(4, this->_internal_version(), target);
1305 }
1306
1307 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1308 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
1309 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
1310 }
1311 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.TransactionTraceFile)
1312 return target;
1313 }
1314
ByteSizeLong() const1315 size_t TransactionTraceFile::ByteSizeLong() const {
1316 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.TransactionTraceFile)
1317 size_t total_size = 0;
1318
1319 ::uint32_t cached_has_bits = 0;
1320 // Prevent compiler warnings about cached_has_bits being unused
1321 (void) cached_has_bits;
1322
1323 // repeated .perfetto.protos.TransactionTraceEntry entry = 2;
1324 total_size += 1UL * this->_internal_entry_size();
1325 for (const auto& msg : this->_impl_.entry_) {
1326 total_size +=
1327 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
1328 }
1329
1330 cached_has_bits = _impl_._has_bits_[0];
1331 if (cached_has_bits & 0x00000007u) {
1332 // optional fixed64 magic_number = 1;
1333 if (cached_has_bits & 0x00000001u) {
1334 total_size += 1 + 8;
1335 }
1336
1337 // optional fixed64 real_to_elapsed_time_offset_nanos = 3;
1338 if (cached_has_bits & 0x00000002u) {
1339 total_size += 1 + 8;
1340 }
1341
1342 // optional uint32 version = 4;
1343 if (cached_has_bits & 0x00000004u) {
1344 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_version());
1345 }
1346
1347 }
1348 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1349 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
1350 }
1351 int cached_size = ::_pbi::ToCachedSize(total_size);
1352 SetCachedSize(cached_size);
1353 return total_size;
1354 }
1355
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)1356 void TransactionTraceFile::CheckTypeAndMergeFrom(
1357 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
1358 MergeFrom(*::_pbi::DownCast<const TransactionTraceFile*>(
1359 &from));
1360 }
1361
MergeFrom(const TransactionTraceFile & from)1362 void TransactionTraceFile::MergeFrom(const TransactionTraceFile& from) {
1363 TransactionTraceFile* const _this = this;
1364 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.TransactionTraceFile)
1365 GOOGLE_DCHECK_NE(&from, _this);
1366 ::uint32_t cached_has_bits = 0;
1367 (void) cached_has_bits;
1368
1369 _this->_impl_.entry_.MergeFrom(from._impl_.entry_);
1370 cached_has_bits = from._impl_._has_bits_[0];
1371 if (cached_has_bits & 0x00000007u) {
1372 if (cached_has_bits & 0x00000001u) {
1373 _this->_impl_.magic_number_ = from._impl_.magic_number_;
1374 }
1375 if (cached_has_bits & 0x00000002u) {
1376 _this->_impl_.real_to_elapsed_time_offset_nanos_ = from._impl_.real_to_elapsed_time_offset_nanos_;
1377 }
1378 if (cached_has_bits & 0x00000004u) {
1379 _this->_impl_.version_ = from._impl_.version_;
1380 }
1381 _this->_impl_._has_bits_[0] |= cached_has_bits;
1382 }
1383 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
1384 }
1385
CopyFrom(const TransactionTraceFile & from)1386 void TransactionTraceFile::CopyFrom(const TransactionTraceFile& from) {
1387 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.TransactionTraceFile)
1388 if (&from == this) return;
1389 Clear();
1390 MergeFrom(from);
1391 }
1392
IsInitialized() const1393 bool TransactionTraceFile::IsInitialized() const {
1394 return true;
1395 }
1396
InternalSwap(TransactionTraceFile * other)1397 void TransactionTraceFile::InternalSwap(TransactionTraceFile* other) {
1398 using std::swap;
1399 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
1400 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
1401 _impl_.entry_.InternalSwap(&other->_impl_.entry_);
1402 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
1403 PROTOBUF_FIELD_OFFSET(TransactionTraceFile, _impl_.version_)
1404 + sizeof(TransactionTraceFile::_impl_.version_) // NOLINT
1405 - PROTOBUF_FIELD_OFFSET(TransactionTraceFile, _impl_.magic_number_)>(
1406 reinterpret_cast<char*>(&_impl_.magic_number_),
1407 reinterpret_cast<char*>(&other->_impl_.magic_number_));
1408 }
1409
GetTypeName() const1410 std::string TransactionTraceFile::GetTypeName() const {
1411 return "perfetto.protos.TransactionTraceFile";
1412 }
1413
1414
1415 // ===================================================================
1416
1417 class TransactionTraceEntry::_Internal {
1418 public:
1419 using HasBits = decltype(std::declval<TransactionTraceEntry>()._impl_._has_bits_);
set_has_elapsed_realtime_nanos(HasBits * has_bits)1420 static void set_has_elapsed_realtime_nanos(HasBits* has_bits) {
1421 (*has_bits)[0] |= 1u;
1422 }
set_has_vsync_id(HasBits * has_bits)1423 static void set_has_vsync_id(HasBits* has_bits) {
1424 (*has_bits)[0] |= 2u;
1425 }
set_has_displays_changed(HasBits * has_bits)1426 static void set_has_displays_changed(HasBits* has_bits) {
1427 (*has_bits)[0] |= 4u;
1428 }
1429 };
1430
TransactionTraceEntry(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)1431 TransactionTraceEntry::TransactionTraceEntry(::PROTOBUF_NAMESPACE_ID::Arena* arena,
1432 bool is_message_owned)
1433 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
1434 SharedCtor(arena, is_message_owned);
1435 // @@protoc_insertion_point(arena_constructor:perfetto.protos.TransactionTraceEntry)
1436 }
TransactionTraceEntry(const TransactionTraceEntry & from)1437 TransactionTraceEntry::TransactionTraceEntry(const TransactionTraceEntry& from)
1438 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
1439 TransactionTraceEntry* const _this = this; (void)_this;
1440 new (&_impl_) Impl_{
1441 decltype(_impl_._has_bits_){from._impl_._has_bits_}
1442 , /*decltype(_impl_._cached_size_)*/{}
1443 , decltype(_impl_.transactions_){from._impl_.transactions_}
1444 , decltype(_impl_.added_layers_){from._impl_.added_layers_}
1445 , decltype(_impl_.destroyed_layers_){from._impl_.destroyed_layers_}
1446 , decltype(_impl_.added_displays_){from._impl_.added_displays_}
1447 , decltype(_impl_.removed_displays_){from._impl_.removed_displays_}
1448 , decltype(_impl_.destroyed_layer_handles_){from._impl_.destroyed_layer_handles_}
1449 , decltype(_impl_.displays_){from._impl_.displays_}
1450 , decltype(_impl_.elapsed_realtime_nanos_){}
1451 , decltype(_impl_.vsync_id_){}
1452 , decltype(_impl_.displays_changed_){}};
1453
1454 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
1455 ::memcpy(&_impl_.elapsed_realtime_nanos_, &from._impl_.elapsed_realtime_nanos_,
1456 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.displays_changed_) -
1457 reinterpret_cast<char*>(&_impl_.elapsed_realtime_nanos_)) + sizeof(_impl_.displays_changed_));
1458 // @@protoc_insertion_point(copy_constructor:perfetto.protos.TransactionTraceEntry)
1459 }
1460
SharedCtor(::_pb::Arena * arena,bool is_message_owned)1461 inline void TransactionTraceEntry::SharedCtor(
1462 ::_pb::Arena* arena, bool is_message_owned) {
1463 (void)arena;
1464 (void)is_message_owned;
1465 new (&_impl_) Impl_{
1466 decltype(_impl_._has_bits_){}
1467 , /*decltype(_impl_._cached_size_)*/{}
1468 , decltype(_impl_.transactions_){arena}
1469 , decltype(_impl_.added_layers_){arena}
1470 , decltype(_impl_.destroyed_layers_){arena}
1471 , decltype(_impl_.added_displays_){arena}
1472 , decltype(_impl_.removed_displays_){arena}
1473 , decltype(_impl_.destroyed_layer_handles_){arena}
1474 , decltype(_impl_.displays_){arena}
1475 , decltype(_impl_.elapsed_realtime_nanos_){::int64_t{0}}
1476 , decltype(_impl_.vsync_id_){::int64_t{0}}
1477 , decltype(_impl_.displays_changed_){false}
1478 };
1479 }
1480
~TransactionTraceEntry()1481 TransactionTraceEntry::~TransactionTraceEntry() {
1482 // @@protoc_insertion_point(destructor:perfetto.protos.TransactionTraceEntry)
1483 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
1484 (void)arena;
1485 return;
1486 }
1487 SharedDtor();
1488 }
1489
SharedDtor()1490 inline void TransactionTraceEntry::SharedDtor() {
1491 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
1492 _impl_.transactions_.~RepeatedPtrField();
1493 _impl_.added_layers_.~RepeatedPtrField();
1494 _impl_.destroyed_layers_.~RepeatedField();
1495 _impl_.added_displays_.~RepeatedPtrField();
1496 _impl_.removed_displays_.~RepeatedField();
1497 _impl_.destroyed_layer_handles_.~RepeatedField();
1498 _impl_.displays_.~RepeatedPtrField();
1499 }
1500
SetCachedSize(int size) const1501 void TransactionTraceEntry::SetCachedSize(int size) const {
1502 _impl_._cached_size_.Set(size);
1503 }
1504
Clear()1505 void TransactionTraceEntry::Clear() {
1506 // @@protoc_insertion_point(message_clear_start:perfetto.protos.TransactionTraceEntry)
1507 ::uint32_t cached_has_bits = 0;
1508 // Prevent compiler warnings about cached_has_bits being unused
1509 (void) cached_has_bits;
1510
1511 _impl_.transactions_.Clear();
1512 _impl_.added_layers_.Clear();
1513 _impl_.destroyed_layers_.Clear();
1514 _impl_.added_displays_.Clear();
1515 _impl_.removed_displays_.Clear();
1516 _impl_.destroyed_layer_handles_.Clear();
1517 _impl_.displays_.Clear();
1518 cached_has_bits = _impl_._has_bits_[0];
1519 if (cached_has_bits & 0x00000007u) {
1520 ::memset(&_impl_.elapsed_realtime_nanos_, 0, static_cast<size_t>(
1521 reinterpret_cast<char*>(&_impl_.displays_changed_) -
1522 reinterpret_cast<char*>(&_impl_.elapsed_realtime_nanos_)) + sizeof(_impl_.displays_changed_));
1523 }
1524 _impl_._has_bits_.Clear();
1525 _internal_metadata_.Clear<std::string>();
1526 }
1527
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)1528 const char* TransactionTraceEntry::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
1529 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
1530 _Internal::HasBits has_bits{};
1531 while (!ctx->Done(&ptr)) {
1532 ::uint32_t tag;
1533 ptr = ::_pbi::ReadTag(ptr, &tag);
1534 switch (tag >> 3) {
1535 // optional int64 elapsed_realtime_nanos = 1;
1536 case 1:
1537 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
1538 _Internal::set_has_elapsed_realtime_nanos(&has_bits);
1539 _impl_.elapsed_realtime_nanos_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1540 CHK_(ptr);
1541 } else {
1542 goto handle_unusual;
1543 }
1544 continue;
1545 // optional int64 vsync_id = 2;
1546 case 2:
1547 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
1548 _Internal::set_has_vsync_id(&has_bits);
1549 _impl_.vsync_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1550 CHK_(ptr);
1551 } else {
1552 goto handle_unusual;
1553 }
1554 continue;
1555 // repeated .perfetto.protos.TransactionState transactions = 3;
1556 case 3:
1557 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 26)) {
1558 ptr -= 1;
1559 do {
1560 ptr += 1;
1561 ptr = ctx->ParseMessage(_internal_add_transactions(), ptr);
1562 CHK_(ptr);
1563 if (!ctx->DataAvailable(ptr)) break;
1564 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<26>(ptr));
1565 } else {
1566 goto handle_unusual;
1567 }
1568 continue;
1569 // repeated .perfetto.protos.LayerCreationArgs added_layers = 4;
1570 case 4:
1571 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 34)) {
1572 ptr -= 1;
1573 do {
1574 ptr += 1;
1575 ptr = ctx->ParseMessage(_internal_add_added_layers(), ptr);
1576 CHK_(ptr);
1577 if (!ctx->DataAvailable(ptr)) break;
1578 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<34>(ptr));
1579 } else {
1580 goto handle_unusual;
1581 }
1582 continue;
1583 // repeated uint32 destroyed_layers = 5;
1584 case 5:
1585 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
1586 ptr -= 1;
1587 do {
1588 ptr += 1;
1589 _internal_add_destroyed_layers(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr));
1590 CHK_(ptr);
1591 if (!ctx->DataAvailable(ptr)) break;
1592 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<40>(ptr));
1593 } else if (static_cast<::uint8_t>(tag) == 42) {
1594 ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedUInt32Parser(_internal_mutable_destroyed_layers(), ptr, ctx);
1595 CHK_(ptr);
1596 } else {
1597 goto handle_unusual;
1598 }
1599 continue;
1600 // repeated .perfetto.protos.DisplayState added_displays = 6;
1601 case 6:
1602 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 50)) {
1603 ptr -= 1;
1604 do {
1605 ptr += 1;
1606 ptr = ctx->ParseMessage(_internal_add_added_displays(), ptr);
1607 CHK_(ptr);
1608 if (!ctx->DataAvailable(ptr)) break;
1609 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<50>(ptr));
1610 } else {
1611 goto handle_unusual;
1612 }
1613 continue;
1614 // repeated int32 removed_displays = 7;
1615 case 7:
1616 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
1617 ptr -= 1;
1618 do {
1619 ptr += 1;
1620 _internal_add_removed_displays(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr));
1621 CHK_(ptr);
1622 if (!ctx->DataAvailable(ptr)) break;
1623 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<56>(ptr));
1624 } else if (static_cast<::uint8_t>(tag) == 58) {
1625 ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedInt32Parser(_internal_mutable_removed_displays(), ptr, ctx);
1626 CHK_(ptr);
1627 } else {
1628 goto handle_unusual;
1629 }
1630 continue;
1631 // repeated uint32 destroyed_layer_handles = 8;
1632 case 8:
1633 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
1634 ptr -= 1;
1635 do {
1636 ptr += 1;
1637 _internal_add_destroyed_layer_handles(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr));
1638 CHK_(ptr);
1639 if (!ctx->DataAvailable(ptr)) break;
1640 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<64>(ptr));
1641 } else if (static_cast<::uint8_t>(tag) == 66) {
1642 ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedUInt32Parser(_internal_mutable_destroyed_layer_handles(), ptr, ctx);
1643 CHK_(ptr);
1644 } else {
1645 goto handle_unusual;
1646 }
1647 continue;
1648 // optional bool displays_changed = 9;
1649 case 9:
1650 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
1651 _Internal::set_has_displays_changed(&has_bits);
1652 _impl_.displays_changed_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
1653 CHK_(ptr);
1654 } else {
1655 goto handle_unusual;
1656 }
1657 continue;
1658 // repeated .perfetto.protos.DisplayInfo displays = 10;
1659 case 10:
1660 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 82)) {
1661 ptr -= 1;
1662 do {
1663 ptr += 1;
1664 ptr = ctx->ParseMessage(_internal_add_displays(), ptr);
1665 CHK_(ptr);
1666 if (!ctx->DataAvailable(ptr)) break;
1667 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<82>(ptr));
1668 } else {
1669 goto handle_unusual;
1670 }
1671 continue;
1672 default:
1673 goto handle_unusual;
1674 } // switch
1675 handle_unusual:
1676 if ((tag == 0) || ((tag & 7) == 4)) {
1677 CHK_(ptr);
1678 ctx->SetLastTag(tag);
1679 goto message_done;
1680 }
1681 ptr = UnknownFieldParse(
1682 tag,
1683 _internal_metadata_.mutable_unknown_fields<std::string>(),
1684 ptr, ctx);
1685 CHK_(ptr != nullptr);
1686 } // while
1687 message_done:
1688 _impl_._has_bits_.Or(has_bits);
1689 return ptr;
1690 failure:
1691 ptr = nullptr;
1692 goto message_done;
1693 #undef CHK_
1694 }
1695
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const1696 ::uint8_t* TransactionTraceEntry::_InternalSerialize(
1697 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
1698 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.TransactionTraceEntry)
1699 ::uint32_t cached_has_bits = 0;
1700 (void) cached_has_bits;
1701
1702 cached_has_bits = _impl_._has_bits_[0];
1703 // optional int64 elapsed_realtime_nanos = 1;
1704 if (cached_has_bits & 0x00000001u) {
1705 target = stream->EnsureSpace(target);
1706 target = ::_pbi::WireFormatLite::WriteInt64ToArray(1, this->_internal_elapsed_realtime_nanos(), target);
1707 }
1708
1709 // optional int64 vsync_id = 2;
1710 if (cached_has_bits & 0x00000002u) {
1711 target = stream->EnsureSpace(target);
1712 target = ::_pbi::WireFormatLite::WriteInt64ToArray(2, this->_internal_vsync_id(), target);
1713 }
1714
1715 // repeated .perfetto.protos.TransactionState transactions = 3;
1716 for (unsigned i = 0,
1717 n = static_cast<unsigned>(this->_internal_transactions_size()); i < n; i++) {
1718 const auto& repfield = this->_internal_transactions(i);
1719 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1720 InternalWriteMessage(3, repfield, repfield.GetCachedSize(), target, stream);
1721 }
1722
1723 // repeated .perfetto.protos.LayerCreationArgs added_layers = 4;
1724 for (unsigned i = 0,
1725 n = static_cast<unsigned>(this->_internal_added_layers_size()); i < n; i++) {
1726 const auto& repfield = this->_internal_added_layers(i);
1727 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1728 InternalWriteMessage(4, repfield, repfield.GetCachedSize(), target, stream);
1729 }
1730
1731 // repeated uint32 destroyed_layers = 5;
1732 for (int i = 0, n = this->_internal_destroyed_layers_size(); i < n; i++) {
1733 target = stream->EnsureSpace(target);
1734 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(5, this->_internal_destroyed_layers(i), target);
1735 }
1736
1737 // repeated .perfetto.protos.DisplayState added_displays = 6;
1738 for (unsigned i = 0,
1739 n = static_cast<unsigned>(this->_internal_added_displays_size()); i < n; i++) {
1740 const auto& repfield = this->_internal_added_displays(i);
1741 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1742 InternalWriteMessage(6, repfield, repfield.GetCachedSize(), target, stream);
1743 }
1744
1745 // repeated int32 removed_displays = 7;
1746 for (int i = 0, n = this->_internal_removed_displays_size(); i < n; i++) {
1747 target = stream->EnsureSpace(target);
1748 target = ::_pbi::WireFormatLite::WriteInt32ToArray(7, this->_internal_removed_displays(i), target);
1749 }
1750
1751 // repeated uint32 destroyed_layer_handles = 8;
1752 for (int i = 0, n = this->_internal_destroyed_layer_handles_size(); i < n; i++) {
1753 target = stream->EnsureSpace(target);
1754 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(8, this->_internal_destroyed_layer_handles(i), target);
1755 }
1756
1757 // optional bool displays_changed = 9;
1758 if (cached_has_bits & 0x00000004u) {
1759 target = stream->EnsureSpace(target);
1760 target = ::_pbi::WireFormatLite::WriteBoolToArray(9, this->_internal_displays_changed(), target);
1761 }
1762
1763 // repeated .perfetto.protos.DisplayInfo displays = 10;
1764 for (unsigned i = 0,
1765 n = static_cast<unsigned>(this->_internal_displays_size()); i < n; i++) {
1766 const auto& repfield = this->_internal_displays(i);
1767 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
1768 InternalWriteMessage(10, repfield, repfield.GetCachedSize(), target, stream);
1769 }
1770
1771 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1772 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
1773 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
1774 }
1775 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.TransactionTraceEntry)
1776 return target;
1777 }
1778
ByteSizeLong() const1779 size_t TransactionTraceEntry::ByteSizeLong() const {
1780 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.TransactionTraceEntry)
1781 size_t total_size = 0;
1782
1783 ::uint32_t cached_has_bits = 0;
1784 // Prevent compiler warnings about cached_has_bits being unused
1785 (void) cached_has_bits;
1786
1787 // repeated .perfetto.protos.TransactionState transactions = 3;
1788 total_size += 1UL * this->_internal_transactions_size();
1789 for (const auto& msg : this->_impl_.transactions_) {
1790 total_size +=
1791 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
1792 }
1793
1794 // repeated .perfetto.protos.LayerCreationArgs added_layers = 4;
1795 total_size += 1UL * this->_internal_added_layers_size();
1796 for (const auto& msg : this->_impl_.added_layers_) {
1797 total_size +=
1798 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
1799 }
1800
1801 // repeated uint32 destroyed_layers = 5;
1802 {
1803 size_t data_size = ::_pbi::WireFormatLite::
1804 UInt32Size(this->_impl_.destroyed_layers_);
1805 total_size += 1 *
1806 ::_pbi::FromIntSize(this->_internal_destroyed_layers_size());
1807 total_size += data_size;
1808 }
1809
1810 // repeated .perfetto.protos.DisplayState added_displays = 6;
1811 total_size += 1UL * this->_internal_added_displays_size();
1812 for (const auto& msg : this->_impl_.added_displays_) {
1813 total_size +=
1814 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
1815 }
1816
1817 // repeated int32 removed_displays = 7;
1818 {
1819 size_t data_size = ::_pbi::WireFormatLite::
1820 Int32Size(this->_impl_.removed_displays_);
1821 total_size += 1 *
1822 ::_pbi::FromIntSize(this->_internal_removed_displays_size());
1823 total_size += data_size;
1824 }
1825
1826 // repeated uint32 destroyed_layer_handles = 8;
1827 {
1828 size_t data_size = ::_pbi::WireFormatLite::
1829 UInt32Size(this->_impl_.destroyed_layer_handles_);
1830 total_size += 1 *
1831 ::_pbi::FromIntSize(this->_internal_destroyed_layer_handles_size());
1832 total_size += data_size;
1833 }
1834
1835 // repeated .perfetto.protos.DisplayInfo displays = 10;
1836 total_size += 1UL * this->_internal_displays_size();
1837 for (const auto& msg : this->_impl_.displays_) {
1838 total_size +=
1839 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
1840 }
1841
1842 cached_has_bits = _impl_._has_bits_[0];
1843 if (cached_has_bits & 0x00000007u) {
1844 // optional int64 elapsed_realtime_nanos = 1;
1845 if (cached_has_bits & 0x00000001u) {
1846 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_elapsed_realtime_nanos());
1847 }
1848
1849 // optional int64 vsync_id = 2;
1850 if (cached_has_bits & 0x00000002u) {
1851 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_vsync_id());
1852 }
1853
1854 // optional bool displays_changed = 9;
1855 if (cached_has_bits & 0x00000004u) {
1856 total_size += 1 + 1;
1857 }
1858
1859 }
1860 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
1861 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
1862 }
1863 int cached_size = ::_pbi::ToCachedSize(total_size);
1864 SetCachedSize(cached_size);
1865 return total_size;
1866 }
1867
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)1868 void TransactionTraceEntry::CheckTypeAndMergeFrom(
1869 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
1870 MergeFrom(*::_pbi::DownCast<const TransactionTraceEntry*>(
1871 &from));
1872 }
1873
MergeFrom(const TransactionTraceEntry & from)1874 void TransactionTraceEntry::MergeFrom(const TransactionTraceEntry& from) {
1875 TransactionTraceEntry* const _this = this;
1876 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.TransactionTraceEntry)
1877 GOOGLE_DCHECK_NE(&from, _this);
1878 ::uint32_t cached_has_bits = 0;
1879 (void) cached_has_bits;
1880
1881 _this->_impl_.transactions_.MergeFrom(from._impl_.transactions_);
1882 _this->_impl_.added_layers_.MergeFrom(from._impl_.added_layers_);
1883 _this->_impl_.destroyed_layers_.MergeFrom(from._impl_.destroyed_layers_);
1884 _this->_impl_.added_displays_.MergeFrom(from._impl_.added_displays_);
1885 _this->_impl_.removed_displays_.MergeFrom(from._impl_.removed_displays_);
1886 _this->_impl_.destroyed_layer_handles_.MergeFrom(from._impl_.destroyed_layer_handles_);
1887 _this->_impl_.displays_.MergeFrom(from._impl_.displays_);
1888 cached_has_bits = from._impl_._has_bits_[0];
1889 if (cached_has_bits & 0x00000007u) {
1890 if (cached_has_bits & 0x00000001u) {
1891 _this->_impl_.elapsed_realtime_nanos_ = from._impl_.elapsed_realtime_nanos_;
1892 }
1893 if (cached_has_bits & 0x00000002u) {
1894 _this->_impl_.vsync_id_ = from._impl_.vsync_id_;
1895 }
1896 if (cached_has_bits & 0x00000004u) {
1897 _this->_impl_.displays_changed_ = from._impl_.displays_changed_;
1898 }
1899 _this->_impl_._has_bits_[0] |= cached_has_bits;
1900 }
1901 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
1902 }
1903
CopyFrom(const TransactionTraceEntry & from)1904 void TransactionTraceEntry::CopyFrom(const TransactionTraceEntry& from) {
1905 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.TransactionTraceEntry)
1906 if (&from == this) return;
1907 Clear();
1908 MergeFrom(from);
1909 }
1910
IsInitialized() const1911 bool TransactionTraceEntry::IsInitialized() const {
1912 return true;
1913 }
1914
InternalSwap(TransactionTraceEntry * other)1915 void TransactionTraceEntry::InternalSwap(TransactionTraceEntry* other) {
1916 using std::swap;
1917 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
1918 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
1919 _impl_.transactions_.InternalSwap(&other->_impl_.transactions_);
1920 _impl_.added_layers_.InternalSwap(&other->_impl_.added_layers_);
1921 _impl_.destroyed_layers_.InternalSwap(&other->_impl_.destroyed_layers_);
1922 _impl_.added_displays_.InternalSwap(&other->_impl_.added_displays_);
1923 _impl_.removed_displays_.InternalSwap(&other->_impl_.removed_displays_);
1924 _impl_.destroyed_layer_handles_.InternalSwap(&other->_impl_.destroyed_layer_handles_);
1925 _impl_.displays_.InternalSwap(&other->_impl_.displays_);
1926 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
1927 PROTOBUF_FIELD_OFFSET(TransactionTraceEntry, _impl_.displays_changed_)
1928 + sizeof(TransactionTraceEntry::_impl_.displays_changed_) // NOLINT
1929 - PROTOBUF_FIELD_OFFSET(TransactionTraceEntry, _impl_.elapsed_realtime_nanos_)>(
1930 reinterpret_cast<char*>(&_impl_.elapsed_realtime_nanos_),
1931 reinterpret_cast<char*>(&other->_impl_.elapsed_realtime_nanos_));
1932 }
1933
GetTypeName() const1934 std::string TransactionTraceEntry::GetTypeName() const {
1935 return "perfetto.protos.TransactionTraceEntry";
1936 }
1937
1938
1939 // ===================================================================
1940
1941 class DisplayInfo::_Internal {
1942 public:
1943 using HasBits = decltype(std::declval<DisplayInfo>()._impl_._has_bits_);
set_has_layer_stack(HasBits * has_bits)1944 static void set_has_layer_stack(HasBits* has_bits) {
1945 (*has_bits)[0] |= 4u;
1946 }
set_has_display_id(HasBits * has_bits)1947 static void set_has_display_id(HasBits* has_bits) {
1948 (*has_bits)[0] |= 8u;
1949 }
set_has_logical_width(HasBits * has_bits)1950 static void set_has_logical_width(HasBits* has_bits) {
1951 (*has_bits)[0] |= 16u;
1952 }
set_has_logical_height(HasBits * has_bits)1953 static void set_has_logical_height(HasBits* has_bits) {
1954 (*has_bits)[0] |= 32u;
1955 }
1956 static const ::perfetto::protos::Transform& transform_inverse(const DisplayInfo* msg);
set_has_transform_inverse(HasBits * has_bits)1957 static void set_has_transform_inverse(HasBits* has_bits) {
1958 (*has_bits)[0] |= 1u;
1959 }
1960 static const ::perfetto::protos::Transform& transform(const DisplayInfo* msg);
set_has_transform(HasBits * has_bits)1961 static void set_has_transform(HasBits* has_bits) {
1962 (*has_bits)[0] |= 2u;
1963 }
set_has_receives_input(HasBits * has_bits)1964 static void set_has_receives_input(HasBits* has_bits) {
1965 (*has_bits)[0] |= 64u;
1966 }
set_has_is_secure(HasBits * has_bits)1967 static void set_has_is_secure(HasBits* has_bits) {
1968 (*has_bits)[0] |= 128u;
1969 }
set_has_is_primary(HasBits * has_bits)1970 static void set_has_is_primary(HasBits* has_bits) {
1971 (*has_bits)[0] |= 256u;
1972 }
set_has_is_virtual(HasBits * has_bits)1973 static void set_has_is_virtual(HasBits* has_bits) {
1974 (*has_bits)[0] |= 512u;
1975 }
set_has_rotation_flags(HasBits * has_bits)1976 static void set_has_rotation_flags(HasBits* has_bits) {
1977 (*has_bits)[0] |= 1024u;
1978 }
set_has_transform_hint(HasBits * has_bits)1979 static void set_has_transform_hint(HasBits* has_bits) {
1980 (*has_bits)[0] |= 2048u;
1981 }
1982 };
1983
1984 const ::perfetto::protos::Transform&
transform_inverse(const DisplayInfo * msg)1985 DisplayInfo::_Internal::transform_inverse(const DisplayInfo* msg) {
1986 return *msg->_impl_.transform_inverse_;
1987 }
1988 const ::perfetto::protos::Transform&
transform(const DisplayInfo * msg)1989 DisplayInfo::_Internal::transform(const DisplayInfo* msg) {
1990 return *msg->_impl_.transform_;
1991 }
DisplayInfo(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)1992 DisplayInfo::DisplayInfo(::PROTOBUF_NAMESPACE_ID::Arena* arena,
1993 bool is_message_owned)
1994 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
1995 SharedCtor(arena, is_message_owned);
1996 // @@protoc_insertion_point(arena_constructor:perfetto.protos.DisplayInfo)
1997 }
DisplayInfo(const DisplayInfo & from)1998 DisplayInfo::DisplayInfo(const DisplayInfo& from)
1999 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
2000 DisplayInfo* const _this = this; (void)_this;
2001 new (&_impl_) Impl_{
2002 decltype(_impl_._has_bits_){from._impl_._has_bits_}
2003 , /*decltype(_impl_._cached_size_)*/{}
2004 , decltype(_impl_.transform_inverse_){nullptr}
2005 , decltype(_impl_.transform_){nullptr}
2006 , decltype(_impl_.layer_stack_){}
2007 , decltype(_impl_.display_id_){}
2008 , decltype(_impl_.logical_width_){}
2009 , decltype(_impl_.logical_height_){}
2010 , decltype(_impl_.receives_input_){}
2011 , decltype(_impl_.is_secure_){}
2012 , decltype(_impl_.is_primary_){}
2013 , decltype(_impl_.is_virtual_){}
2014 , decltype(_impl_.rotation_flags_){}
2015 , decltype(_impl_.transform_hint_){}};
2016
2017 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
2018 if (from._internal_has_transform_inverse()) {
2019 _this->_impl_.transform_inverse_ = new ::perfetto::protos::Transform(*from._impl_.transform_inverse_);
2020 }
2021 if (from._internal_has_transform()) {
2022 _this->_impl_.transform_ = new ::perfetto::protos::Transform(*from._impl_.transform_);
2023 }
2024 ::memcpy(&_impl_.layer_stack_, &from._impl_.layer_stack_,
2025 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.transform_hint_) -
2026 reinterpret_cast<char*>(&_impl_.layer_stack_)) + sizeof(_impl_.transform_hint_));
2027 // @@protoc_insertion_point(copy_constructor:perfetto.protos.DisplayInfo)
2028 }
2029
SharedCtor(::_pb::Arena * arena,bool is_message_owned)2030 inline void DisplayInfo::SharedCtor(
2031 ::_pb::Arena* arena, bool is_message_owned) {
2032 (void)arena;
2033 (void)is_message_owned;
2034 new (&_impl_) Impl_{
2035 decltype(_impl_._has_bits_){}
2036 , /*decltype(_impl_._cached_size_)*/{}
2037 , decltype(_impl_.transform_inverse_){nullptr}
2038 , decltype(_impl_.transform_){nullptr}
2039 , decltype(_impl_.layer_stack_){0u}
2040 , decltype(_impl_.display_id_){0}
2041 , decltype(_impl_.logical_width_){0}
2042 , decltype(_impl_.logical_height_){0}
2043 , decltype(_impl_.receives_input_){false}
2044 , decltype(_impl_.is_secure_){false}
2045 , decltype(_impl_.is_primary_){false}
2046 , decltype(_impl_.is_virtual_){false}
2047 , decltype(_impl_.rotation_flags_){0}
2048 , decltype(_impl_.transform_hint_){0}
2049 };
2050 }
2051
~DisplayInfo()2052 DisplayInfo::~DisplayInfo() {
2053 // @@protoc_insertion_point(destructor:perfetto.protos.DisplayInfo)
2054 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
2055 (void)arena;
2056 return;
2057 }
2058 SharedDtor();
2059 }
2060
SharedDtor()2061 inline void DisplayInfo::SharedDtor() {
2062 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
2063 if (this != internal_default_instance()) delete _impl_.transform_inverse_;
2064 if (this != internal_default_instance()) delete _impl_.transform_;
2065 }
2066
SetCachedSize(int size) const2067 void DisplayInfo::SetCachedSize(int size) const {
2068 _impl_._cached_size_.Set(size);
2069 }
2070
Clear()2071 void DisplayInfo::Clear() {
2072 // @@protoc_insertion_point(message_clear_start:perfetto.protos.DisplayInfo)
2073 ::uint32_t cached_has_bits = 0;
2074 // Prevent compiler warnings about cached_has_bits being unused
2075 (void) cached_has_bits;
2076
2077 cached_has_bits = _impl_._has_bits_[0];
2078 if (cached_has_bits & 0x00000003u) {
2079 if (cached_has_bits & 0x00000001u) {
2080 GOOGLE_DCHECK(_impl_.transform_inverse_ != nullptr);
2081 _impl_.transform_inverse_->Clear();
2082 }
2083 if (cached_has_bits & 0x00000002u) {
2084 GOOGLE_DCHECK(_impl_.transform_ != nullptr);
2085 _impl_.transform_->Clear();
2086 }
2087 }
2088 if (cached_has_bits & 0x000000fcu) {
2089 ::memset(&_impl_.layer_stack_, 0, static_cast<size_t>(
2090 reinterpret_cast<char*>(&_impl_.is_secure_) -
2091 reinterpret_cast<char*>(&_impl_.layer_stack_)) + sizeof(_impl_.is_secure_));
2092 }
2093 if (cached_has_bits & 0x00000f00u) {
2094 ::memset(&_impl_.is_primary_, 0, static_cast<size_t>(
2095 reinterpret_cast<char*>(&_impl_.transform_hint_) -
2096 reinterpret_cast<char*>(&_impl_.is_primary_)) + sizeof(_impl_.transform_hint_));
2097 }
2098 _impl_._has_bits_.Clear();
2099 _internal_metadata_.Clear<std::string>();
2100 }
2101
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)2102 const char* DisplayInfo::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
2103 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
2104 _Internal::HasBits has_bits{};
2105 while (!ctx->Done(&ptr)) {
2106 ::uint32_t tag;
2107 ptr = ::_pbi::ReadTag(ptr, &tag);
2108 switch (tag >> 3) {
2109 // optional uint32 layer_stack = 1;
2110 case 1:
2111 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
2112 _Internal::set_has_layer_stack(&has_bits);
2113 _impl_.layer_stack_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2114 CHK_(ptr);
2115 } else {
2116 goto handle_unusual;
2117 }
2118 continue;
2119 // optional int32 display_id = 2;
2120 case 2:
2121 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
2122 _Internal::set_has_display_id(&has_bits);
2123 _impl_.display_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2124 CHK_(ptr);
2125 } else {
2126 goto handle_unusual;
2127 }
2128 continue;
2129 // optional int32 logical_width = 3;
2130 case 3:
2131 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
2132 _Internal::set_has_logical_width(&has_bits);
2133 _impl_.logical_width_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2134 CHK_(ptr);
2135 } else {
2136 goto handle_unusual;
2137 }
2138 continue;
2139 // optional int32 logical_height = 4;
2140 case 4:
2141 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
2142 _Internal::set_has_logical_height(&has_bits);
2143 _impl_.logical_height_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2144 CHK_(ptr);
2145 } else {
2146 goto handle_unusual;
2147 }
2148 continue;
2149 // optional .perfetto.protos.Transform transform_inverse = 5;
2150 case 5:
2151 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 42)) {
2152 ptr = ctx->ParseMessage(_internal_mutable_transform_inverse(), ptr);
2153 CHK_(ptr);
2154 } else {
2155 goto handle_unusual;
2156 }
2157 continue;
2158 // optional .perfetto.protos.Transform transform = 6;
2159 case 6:
2160 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 50)) {
2161 ptr = ctx->ParseMessage(_internal_mutable_transform(), ptr);
2162 CHK_(ptr);
2163 } else {
2164 goto handle_unusual;
2165 }
2166 continue;
2167 // optional bool receives_input = 7;
2168 case 7:
2169 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
2170 _Internal::set_has_receives_input(&has_bits);
2171 _impl_.receives_input_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2172 CHK_(ptr);
2173 } else {
2174 goto handle_unusual;
2175 }
2176 continue;
2177 // optional bool is_secure = 8;
2178 case 8:
2179 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
2180 _Internal::set_has_is_secure(&has_bits);
2181 _impl_.is_secure_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2182 CHK_(ptr);
2183 } else {
2184 goto handle_unusual;
2185 }
2186 continue;
2187 // optional bool is_primary = 9;
2188 case 9:
2189 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
2190 _Internal::set_has_is_primary(&has_bits);
2191 _impl_.is_primary_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2192 CHK_(ptr);
2193 } else {
2194 goto handle_unusual;
2195 }
2196 continue;
2197 // optional bool is_virtual = 10;
2198 case 10:
2199 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 80)) {
2200 _Internal::set_has_is_virtual(&has_bits);
2201 _impl_.is_virtual_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2202 CHK_(ptr);
2203 } else {
2204 goto handle_unusual;
2205 }
2206 continue;
2207 // optional int32 rotation_flags = 11;
2208 case 11:
2209 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 88)) {
2210 _Internal::set_has_rotation_flags(&has_bits);
2211 _impl_.rotation_flags_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2212 CHK_(ptr);
2213 } else {
2214 goto handle_unusual;
2215 }
2216 continue;
2217 // optional int32 transform_hint = 12;
2218 case 12:
2219 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 96)) {
2220 _Internal::set_has_transform_hint(&has_bits);
2221 _impl_.transform_hint_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2222 CHK_(ptr);
2223 } else {
2224 goto handle_unusual;
2225 }
2226 continue;
2227 default:
2228 goto handle_unusual;
2229 } // switch
2230 handle_unusual:
2231 if ((tag == 0) || ((tag & 7) == 4)) {
2232 CHK_(ptr);
2233 ctx->SetLastTag(tag);
2234 goto message_done;
2235 }
2236 ptr = UnknownFieldParse(
2237 tag,
2238 _internal_metadata_.mutable_unknown_fields<std::string>(),
2239 ptr, ctx);
2240 CHK_(ptr != nullptr);
2241 } // while
2242 message_done:
2243 _impl_._has_bits_.Or(has_bits);
2244 return ptr;
2245 failure:
2246 ptr = nullptr;
2247 goto message_done;
2248 #undef CHK_
2249 }
2250
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const2251 ::uint8_t* DisplayInfo::_InternalSerialize(
2252 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
2253 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.DisplayInfo)
2254 ::uint32_t cached_has_bits = 0;
2255 (void) cached_has_bits;
2256
2257 cached_has_bits = _impl_._has_bits_[0];
2258 // optional uint32 layer_stack = 1;
2259 if (cached_has_bits & 0x00000004u) {
2260 target = stream->EnsureSpace(target);
2261 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(1, this->_internal_layer_stack(), target);
2262 }
2263
2264 // optional int32 display_id = 2;
2265 if (cached_has_bits & 0x00000008u) {
2266 target = stream->EnsureSpace(target);
2267 target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_display_id(), target);
2268 }
2269
2270 // optional int32 logical_width = 3;
2271 if (cached_has_bits & 0x00000010u) {
2272 target = stream->EnsureSpace(target);
2273 target = ::_pbi::WireFormatLite::WriteInt32ToArray(3, this->_internal_logical_width(), target);
2274 }
2275
2276 // optional int32 logical_height = 4;
2277 if (cached_has_bits & 0x00000020u) {
2278 target = stream->EnsureSpace(target);
2279 target = ::_pbi::WireFormatLite::WriteInt32ToArray(4, this->_internal_logical_height(), target);
2280 }
2281
2282 // optional .perfetto.protos.Transform transform_inverse = 5;
2283 if (cached_has_bits & 0x00000001u) {
2284 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
2285 InternalWriteMessage(5, _Internal::transform_inverse(this),
2286 _Internal::transform_inverse(this).GetCachedSize(), target, stream);
2287 }
2288
2289 // optional .perfetto.protos.Transform transform = 6;
2290 if (cached_has_bits & 0x00000002u) {
2291 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
2292 InternalWriteMessage(6, _Internal::transform(this),
2293 _Internal::transform(this).GetCachedSize(), target, stream);
2294 }
2295
2296 // optional bool receives_input = 7;
2297 if (cached_has_bits & 0x00000040u) {
2298 target = stream->EnsureSpace(target);
2299 target = ::_pbi::WireFormatLite::WriteBoolToArray(7, this->_internal_receives_input(), target);
2300 }
2301
2302 // optional bool is_secure = 8;
2303 if (cached_has_bits & 0x00000080u) {
2304 target = stream->EnsureSpace(target);
2305 target = ::_pbi::WireFormatLite::WriteBoolToArray(8, this->_internal_is_secure(), target);
2306 }
2307
2308 // optional bool is_primary = 9;
2309 if (cached_has_bits & 0x00000100u) {
2310 target = stream->EnsureSpace(target);
2311 target = ::_pbi::WireFormatLite::WriteBoolToArray(9, this->_internal_is_primary(), target);
2312 }
2313
2314 // optional bool is_virtual = 10;
2315 if (cached_has_bits & 0x00000200u) {
2316 target = stream->EnsureSpace(target);
2317 target = ::_pbi::WireFormatLite::WriteBoolToArray(10, this->_internal_is_virtual(), target);
2318 }
2319
2320 // optional int32 rotation_flags = 11;
2321 if (cached_has_bits & 0x00000400u) {
2322 target = stream->EnsureSpace(target);
2323 target = ::_pbi::WireFormatLite::WriteInt32ToArray(11, this->_internal_rotation_flags(), target);
2324 }
2325
2326 // optional int32 transform_hint = 12;
2327 if (cached_has_bits & 0x00000800u) {
2328 target = stream->EnsureSpace(target);
2329 target = ::_pbi::WireFormatLite::WriteInt32ToArray(12, this->_internal_transform_hint(), target);
2330 }
2331
2332 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
2333 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
2334 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
2335 }
2336 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.DisplayInfo)
2337 return target;
2338 }
2339
ByteSizeLong() const2340 size_t DisplayInfo::ByteSizeLong() const {
2341 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.DisplayInfo)
2342 size_t total_size = 0;
2343
2344 ::uint32_t cached_has_bits = 0;
2345 // Prevent compiler warnings about cached_has_bits being unused
2346 (void) cached_has_bits;
2347
2348 cached_has_bits = _impl_._has_bits_[0];
2349 if (cached_has_bits & 0x000000ffu) {
2350 // optional .perfetto.protos.Transform transform_inverse = 5;
2351 if (cached_has_bits & 0x00000001u) {
2352 total_size += 1 +
2353 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
2354 *_impl_.transform_inverse_);
2355 }
2356
2357 // optional .perfetto.protos.Transform transform = 6;
2358 if (cached_has_bits & 0x00000002u) {
2359 total_size += 1 +
2360 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
2361 *_impl_.transform_);
2362 }
2363
2364 // optional uint32 layer_stack = 1;
2365 if (cached_has_bits & 0x00000004u) {
2366 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_layer_stack());
2367 }
2368
2369 // optional int32 display_id = 2;
2370 if (cached_has_bits & 0x00000008u) {
2371 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_display_id());
2372 }
2373
2374 // optional int32 logical_width = 3;
2375 if (cached_has_bits & 0x00000010u) {
2376 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_logical_width());
2377 }
2378
2379 // optional int32 logical_height = 4;
2380 if (cached_has_bits & 0x00000020u) {
2381 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_logical_height());
2382 }
2383
2384 // optional bool receives_input = 7;
2385 if (cached_has_bits & 0x00000040u) {
2386 total_size += 1 + 1;
2387 }
2388
2389 // optional bool is_secure = 8;
2390 if (cached_has_bits & 0x00000080u) {
2391 total_size += 1 + 1;
2392 }
2393
2394 }
2395 if (cached_has_bits & 0x00000f00u) {
2396 // optional bool is_primary = 9;
2397 if (cached_has_bits & 0x00000100u) {
2398 total_size += 1 + 1;
2399 }
2400
2401 // optional bool is_virtual = 10;
2402 if (cached_has_bits & 0x00000200u) {
2403 total_size += 1 + 1;
2404 }
2405
2406 // optional int32 rotation_flags = 11;
2407 if (cached_has_bits & 0x00000400u) {
2408 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_rotation_flags());
2409 }
2410
2411 // optional int32 transform_hint = 12;
2412 if (cached_has_bits & 0x00000800u) {
2413 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_transform_hint());
2414 }
2415
2416 }
2417 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
2418 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
2419 }
2420 int cached_size = ::_pbi::ToCachedSize(total_size);
2421 SetCachedSize(cached_size);
2422 return total_size;
2423 }
2424
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)2425 void DisplayInfo::CheckTypeAndMergeFrom(
2426 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
2427 MergeFrom(*::_pbi::DownCast<const DisplayInfo*>(
2428 &from));
2429 }
2430
MergeFrom(const DisplayInfo & from)2431 void DisplayInfo::MergeFrom(const DisplayInfo& from) {
2432 DisplayInfo* const _this = this;
2433 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.DisplayInfo)
2434 GOOGLE_DCHECK_NE(&from, _this);
2435 ::uint32_t cached_has_bits = 0;
2436 (void) cached_has_bits;
2437
2438 cached_has_bits = from._impl_._has_bits_[0];
2439 if (cached_has_bits & 0x000000ffu) {
2440 if (cached_has_bits & 0x00000001u) {
2441 _this->_internal_mutable_transform_inverse()->::perfetto::protos::Transform::MergeFrom(
2442 from._internal_transform_inverse());
2443 }
2444 if (cached_has_bits & 0x00000002u) {
2445 _this->_internal_mutable_transform()->::perfetto::protos::Transform::MergeFrom(
2446 from._internal_transform());
2447 }
2448 if (cached_has_bits & 0x00000004u) {
2449 _this->_impl_.layer_stack_ = from._impl_.layer_stack_;
2450 }
2451 if (cached_has_bits & 0x00000008u) {
2452 _this->_impl_.display_id_ = from._impl_.display_id_;
2453 }
2454 if (cached_has_bits & 0x00000010u) {
2455 _this->_impl_.logical_width_ = from._impl_.logical_width_;
2456 }
2457 if (cached_has_bits & 0x00000020u) {
2458 _this->_impl_.logical_height_ = from._impl_.logical_height_;
2459 }
2460 if (cached_has_bits & 0x00000040u) {
2461 _this->_impl_.receives_input_ = from._impl_.receives_input_;
2462 }
2463 if (cached_has_bits & 0x00000080u) {
2464 _this->_impl_.is_secure_ = from._impl_.is_secure_;
2465 }
2466 _this->_impl_._has_bits_[0] |= cached_has_bits;
2467 }
2468 if (cached_has_bits & 0x00000f00u) {
2469 if (cached_has_bits & 0x00000100u) {
2470 _this->_impl_.is_primary_ = from._impl_.is_primary_;
2471 }
2472 if (cached_has_bits & 0x00000200u) {
2473 _this->_impl_.is_virtual_ = from._impl_.is_virtual_;
2474 }
2475 if (cached_has_bits & 0x00000400u) {
2476 _this->_impl_.rotation_flags_ = from._impl_.rotation_flags_;
2477 }
2478 if (cached_has_bits & 0x00000800u) {
2479 _this->_impl_.transform_hint_ = from._impl_.transform_hint_;
2480 }
2481 _this->_impl_._has_bits_[0] |= cached_has_bits;
2482 }
2483 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
2484 }
2485
CopyFrom(const DisplayInfo & from)2486 void DisplayInfo::CopyFrom(const DisplayInfo& from) {
2487 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.DisplayInfo)
2488 if (&from == this) return;
2489 Clear();
2490 MergeFrom(from);
2491 }
2492
IsInitialized() const2493 bool DisplayInfo::IsInitialized() const {
2494 return true;
2495 }
2496
InternalSwap(DisplayInfo * other)2497 void DisplayInfo::InternalSwap(DisplayInfo* other) {
2498 using std::swap;
2499 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
2500 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
2501 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
2502 PROTOBUF_FIELD_OFFSET(DisplayInfo, _impl_.transform_hint_)
2503 + sizeof(DisplayInfo::_impl_.transform_hint_) // NOLINT
2504 - PROTOBUF_FIELD_OFFSET(DisplayInfo, _impl_.transform_inverse_)>(
2505 reinterpret_cast<char*>(&_impl_.transform_inverse_),
2506 reinterpret_cast<char*>(&other->_impl_.transform_inverse_));
2507 }
2508
GetTypeName() const2509 std::string DisplayInfo::GetTypeName() const {
2510 return "perfetto.protos.DisplayInfo";
2511 }
2512
2513
2514 // ===================================================================
2515
2516 class LayerCreationArgs::_Internal {
2517 public:
2518 using HasBits = decltype(std::declval<LayerCreationArgs>()._impl_._has_bits_);
set_has_layer_id(HasBits * has_bits)2519 static void set_has_layer_id(HasBits* has_bits) {
2520 (*has_bits)[0] |= 2u;
2521 }
set_has_name(HasBits * has_bits)2522 static void set_has_name(HasBits* has_bits) {
2523 (*has_bits)[0] |= 1u;
2524 }
set_has_flags(HasBits * has_bits)2525 static void set_has_flags(HasBits* has_bits) {
2526 (*has_bits)[0] |= 4u;
2527 }
set_has_parent_id(HasBits * has_bits)2528 static void set_has_parent_id(HasBits* has_bits) {
2529 (*has_bits)[0] |= 8u;
2530 }
set_has_mirror_from_id(HasBits * has_bits)2531 static void set_has_mirror_from_id(HasBits* has_bits) {
2532 (*has_bits)[0] |= 16u;
2533 }
set_has_add_to_root(HasBits * has_bits)2534 static void set_has_add_to_root(HasBits* has_bits) {
2535 (*has_bits)[0] |= 32u;
2536 }
set_has_layer_stack_to_mirror(HasBits * has_bits)2537 static void set_has_layer_stack_to_mirror(HasBits* has_bits) {
2538 (*has_bits)[0] |= 64u;
2539 }
2540 };
2541
LayerCreationArgs(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)2542 LayerCreationArgs::LayerCreationArgs(::PROTOBUF_NAMESPACE_ID::Arena* arena,
2543 bool is_message_owned)
2544 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
2545 SharedCtor(arena, is_message_owned);
2546 // @@protoc_insertion_point(arena_constructor:perfetto.protos.LayerCreationArgs)
2547 }
LayerCreationArgs(const LayerCreationArgs & from)2548 LayerCreationArgs::LayerCreationArgs(const LayerCreationArgs& from)
2549 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
2550 LayerCreationArgs* const _this = this; (void)_this;
2551 new (&_impl_) Impl_{
2552 decltype(_impl_._has_bits_){from._impl_._has_bits_}
2553 , /*decltype(_impl_._cached_size_)*/{}
2554 , decltype(_impl_.name_){}
2555 , decltype(_impl_.layer_id_){}
2556 , decltype(_impl_.flags_){}
2557 , decltype(_impl_.parent_id_){}
2558 , decltype(_impl_.mirror_from_id_){}
2559 , decltype(_impl_.add_to_root_){}
2560 , decltype(_impl_.layer_stack_to_mirror_){}};
2561
2562 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
2563 _impl_.name_.InitDefault();
2564 #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
2565 _impl_.name_.Set("", GetArenaForAllocation());
2566 #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
2567 if (from._internal_has_name()) {
2568 _this->_impl_.name_.Set(from._internal_name(),
2569 _this->GetArenaForAllocation());
2570 }
2571 ::memcpy(&_impl_.layer_id_, &from._impl_.layer_id_,
2572 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.layer_stack_to_mirror_) -
2573 reinterpret_cast<char*>(&_impl_.layer_id_)) + sizeof(_impl_.layer_stack_to_mirror_));
2574 // @@protoc_insertion_point(copy_constructor:perfetto.protos.LayerCreationArgs)
2575 }
2576
SharedCtor(::_pb::Arena * arena,bool is_message_owned)2577 inline void LayerCreationArgs::SharedCtor(
2578 ::_pb::Arena* arena, bool is_message_owned) {
2579 (void)arena;
2580 (void)is_message_owned;
2581 new (&_impl_) Impl_{
2582 decltype(_impl_._has_bits_){}
2583 , /*decltype(_impl_._cached_size_)*/{}
2584 , decltype(_impl_.name_){}
2585 , decltype(_impl_.layer_id_){0u}
2586 , decltype(_impl_.flags_){0u}
2587 , decltype(_impl_.parent_id_){0u}
2588 , decltype(_impl_.mirror_from_id_){0u}
2589 , decltype(_impl_.add_to_root_){false}
2590 , decltype(_impl_.layer_stack_to_mirror_){0u}
2591 };
2592 _impl_.name_.InitDefault();
2593 #ifdef PROTOBUF_FORCE_COPY_DEFAULT_STRING
2594 _impl_.name_.Set("", GetArenaForAllocation());
2595 #endif // PROTOBUF_FORCE_COPY_DEFAULT_STRING
2596 }
2597
~LayerCreationArgs()2598 LayerCreationArgs::~LayerCreationArgs() {
2599 // @@protoc_insertion_point(destructor:perfetto.protos.LayerCreationArgs)
2600 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
2601 (void)arena;
2602 return;
2603 }
2604 SharedDtor();
2605 }
2606
SharedDtor()2607 inline void LayerCreationArgs::SharedDtor() {
2608 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
2609 _impl_.name_.Destroy();
2610 }
2611
SetCachedSize(int size) const2612 void LayerCreationArgs::SetCachedSize(int size) const {
2613 _impl_._cached_size_.Set(size);
2614 }
2615
Clear()2616 void LayerCreationArgs::Clear() {
2617 // @@protoc_insertion_point(message_clear_start:perfetto.protos.LayerCreationArgs)
2618 ::uint32_t cached_has_bits = 0;
2619 // Prevent compiler warnings about cached_has_bits being unused
2620 (void) cached_has_bits;
2621
2622 cached_has_bits = _impl_._has_bits_[0];
2623 if (cached_has_bits & 0x00000001u) {
2624 _impl_.name_.ClearNonDefaultToEmpty();
2625 }
2626 if (cached_has_bits & 0x0000007eu) {
2627 ::memset(&_impl_.layer_id_, 0, static_cast<size_t>(
2628 reinterpret_cast<char*>(&_impl_.layer_stack_to_mirror_) -
2629 reinterpret_cast<char*>(&_impl_.layer_id_)) + sizeof(_impl_.layer_stack_to_mirror_));
2630 }
2631 _impl_._has_bits_.Clear();
2632 _internal_metadata_.Clear<std::string>();
2633 }
2634
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)2635 const char* LayerCreationArgs::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
2636 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
2637 _Internal::HasBits has_bits{};
2638 while (!ctx->Done(&ptr)) {
2639 ::uint32_t tag;
2640 ptr = ::_pbi::ReadTag(ptr, &tag);
2641 switch (tag >> 3) {
2642 // optional uint32 layer_id = 1;
2643 case 1:
2644 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
2645 _Internal::set_has_layer_id(&has_bits);
2646 _impl_.layer_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2647 CHK_(ptr);
2648 } else {
2649 goto handle_unusual;
2650 }
2651 continue;
2652 // optional string name = 2;
2653 case 2:
2654 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 18)) {
2655 auto str = _internal_mutable_name();
2656 ptr = ::_pbi::InlineGreedyStringParser(str, ptr, ctx);
2657 CHK_(ptr);
2658 } else {
2659 goto handle_unusual;
2660 }
2661 continue;
2662 // optional uint32 flags = 3;
2663 case 3:
2664 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
2665 _Internal::set_has_flags(&has_bits);
2666 _impl_.flags_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2667 CHK_(ptr);
2668 } else {
2669 goto handle_unusual;
2670 }
2671 continue;
2672 // optional uint32 parent_id = 4;
2673 case 4:
2674 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
2675 _Internal::set_has_parent_id(&has_bits);
2676 _impl_.parent_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2677 CHK_(ptr);
2678 } else {
2679 goto handle_unusual;
2680 }
2681 continue;
2682 // optional uint32 mirror_from_id = 5;
2683 case 5:
2684 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
2685 _Internal::set_has_mirror_from_id(&has_bits);
2686 _impl_.mirror_from_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2687 CHK_(ptr);
2688 } else {
2689 goto handle_unusual;
2690 }
2691 continue;
2692 // optional bool add_to_root = 6;
2693 case 6:
2694 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
2695 _Internal::set_has_add_to_root(&has_bits);
2696 _impl_.add_to_root_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
2697 CHK_(ptr);
2698 } else {
2699 goto handle_unusual;
2700 }
2701 continue;
2702 // optional uint32 layer_stack_to_mirror = 7;
2703 case 7:
2704 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
2705 _Internal::set_has_layer_stack_to_mirror(&has_bits);
2706 _impl_.layer_stack_to_mirror_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
2707 CHK_(ptr);
2708 } else {
2709 goto handle_unusual;
2710 }
2711 continue;
2712 default:
2713 goto handle_unusual;
2714 } // switch
2715 handle_unusual:
2716 if ((tag == 0) || ((tag & 7) == 4)) {
2717 CHK_(ptr);
2718 ctx->SetLastTag(tag);
2719 goto message_done;
2720 }
2721 ptr = UnknownFieldParse(
2722 tag,
2723 _internal_metadata_.mutable_unknown_fields<std::string>(),
2724 ptr, ctx);
2725 CHK_(ptr != nullptr);
2726 } // while
2727 message_done:
2728 _impl_._has_bits_.Or(has_bits);
2729 return ptr;
2730 failure:
2731 ptr = nullptr;
2732 goto message_done;
2733 #undef CHK_
2734 }
2735
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const2736 ::uint8_t* LayerCreationArgs::_InternalSerialize(
2737 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
2738 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.LayerCreationArgs)
2739 ::uint32_t cached_has_bits = 0;
2740 (void) cached_has_bits;
2741
2742 cached_has_bits = _impl_._has_bits_[0];
2743 // optional uint32 layer_id = 1;
2744 if (cached_has_bits & 0x00000002u) {
2745 target = stream->EnsureSpace(target);
2746 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(1, this->_internal_layer_id(), target);
2747 }
2748
2749 // optional string name = 2;
2750 if (cached_has_bits & 0x00000001u) {
2751 target = stream->WriteStringMaybeAliased(
2752 2, this->_internal_name(), target);
2753 }
2754
2755 // optional uint32 flags = 3;
2756 if (cached_has_bits & 0x00000004u) {
2757 target = stream->EnsureSpace(target);
2758 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(3, this->_internal_flags(), target);
2759 }
2760
2761 // optional uint32 parent_id = 4;
2762 if (cached_has_bits & 0x00000008u) {
2763 target = stream->EnsureSpace(target);
2764 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(4, this->_internal_parent_id(), target);
2765 }
2766
2767 // optional uint32 mirror_from_id = 5;
2768 if (cached_has_bits & 0x00000010u) {
2769 target = stream->EnsureSpace(target);
2770 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(5, this->_internal_mirror_from_id(), target);
2771 }
2772
2773 // optional bool add_to_root = 6;
2774 if (cached_has_bits & 0x00000020u) {
2775 target = stream->EnsureSpace(target);
2776 target = ::_pbi::WireFormatLite::WriteBoolToArray(6, this->_internal_add_to_root(), target);
2777 }
2778
2779 // optional uint32 layer_stack_to_mirror = 7;
2780 if (cached_has_bits & 0x00000040u) {
2781 target = stream->EnsureSpace(target);
2782 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(7, this->_internal_layer_stack_to_mirror(), target);
2783 }
2784
2785 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
2786 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
2787 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
2788 }
2789 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.LayerCreationArgs)
2790 return target;
2791 }
2792
ByteSizeLong() const2793 size_t LayerCreationArgs::ByteSizeLong() const {
2794 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.LayerCreationArgs)
2795 size_t total_size = 0;
2796
2797 ::uint32_t cached_has_bits = 0;
2798 // Prevent compiler warnings about cached_has_bits being unused
2799 (void) cached_has_bits;
2800
2801 cached_has_bits = _impl_._has_bits_[0];
2802 if (cached_has_bits & 0x0000007fu) {
2803 // optional string name = 2;
2804 if (cached_has_bits & 0x00000001u) {
2805 total_size += 1 +
2806 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::StringSize(
2807 this->_internal_name());
2808 }
2809
2810 // optional uint32 layer_id = 1;
2811 if (cached_has_bits & 0x00000002u) {
2812 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_layer_id());
2813 }
2814
2815 // optional uint32 flags = 3;
2816 if (cached_has_bits & 0x00000004u) {
2817 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_flags());
2818 }
2819
2820 // optional uint32 parent_id = 4;
2821 if (cached_has_bits & 0x00000008u) {
2822 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_parent_id());
2823 }
2824
2825 // optional uint32 mirror_from_id = 5;
2826 if (cached_has_bits & 0x00000010u) {
2827 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_mirror_from_id());
2828 }
2829
2830 // optional bool add_to_root = 6;
2831 if (cached_has_bits & 0x00000020u) {
2832 total_size += 1 + 1;
2833 }
2834
2835 // optional uint32 layer_stack_to_mirror = 7;
2836 if (cached_has_bits & 0x00000040u) {
2837 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_layer_stack_to_mirror());
2838 }
2839
2840 }
2841 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
2842 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
2843 }
2844 int cached_size = ::_pbi::ToCachedSize(total_size);
2845 SetCachedSize(cached_size);
2846 return total_size;
2847 }
2848
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)2849 void LayerCreationArgs::CheckTypeAndMergeFrom(
2850 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
2851 MergeFrom(*::_pbi::DownCast<const LayerCreationArgs*>(
2852 &from));
2853 }
2854
MergeFrom(const LayerCreationArgs & from)2855 void LayerCreationArgs::MergeFrom(const LayerCreationArgs& from) {
2856 LayerCreationArgs* const _this = this;
2857 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.LayerCreationArgs)
2858 GOOGLE_DCHECK_NE(&from, _this);
2859 ::uint32_t cached_has_bits = 0;
2860 (void) cached_has_bits;
2861
2862 cached_has_bits = from._impl_._has_bits_[0];
2863 if (cached_has_bits & 0x0000007fu) {
2864 if (cached_has_bits & 0x00000001u) {
2865 _this->_internal_set_name(from._internal_name());
2866 }
2867 if (cached_has_bits & 0x00000002u) {
2868 _this->_impl_.layer_id_ = from._impl_.layer_id_;
2869 }
2870 if (cached_has_bits & 0x00000004u) {
2871 _this->_impl_.flags_ = from._impl_.flags_;
2872 }
2873 if (cached_has_bits & 0x00000008u) {
2874 _this->_impl_.parent_id_ = from._impl_.parent_id_;
2875 }
2876 if (cached_has_bits & 0x00000010u) {
2877 _this->_impl_.mirror_from_id_ = from._impl_.mirror_from_id_;
2878 }
2879 if (cached_has_bits & 0x00000020u) {
2880 _this->_impl_.add_to_root_ = from._impl_.add_to_root_;
2881 }
2882 if (cached_has_bits & 0x00000040u) {
2883 _this->_impl_.layer_stack_to_mirror_ = from._impl_.layer_stack_to_mirror_;
2884 }
2885 _this->_impl_._has_bits_[0] |= cached_has_bits;
2886 }
2887 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
2888 }
2889
CopyFrom(const LayerCreationArgs & from)2890 void LayerCreationArgs::CopyFrom(const LayerCreationArgs& from) {
2891 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.LayerCreationArgs)
2892 if (&from == this) return;
2893 Clear();
2894 MergeFrom(from);
2895 }
2896
IsInitialized() const2897 bool LayerCreationArgs::IsInitialized() const {
2898 return true;
2899 }
2900
InternalSwap(LayerCreationArgs * other)2901 void LayerCreationArgs::InternalSwap(LayerCreationArgs* other) {
2902 using std::swap;
2903 auto* lhs_arena = GetArenaForAllocation();
2904 auto* rhs_arena = other->GetArenaForAllocation();
2905 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
2906 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
2907 ::PROTOBUF_NAMESPACE_ID::internal::ArenaStringPtr::InternalSwap(
2908 &_impl_.name_, lhs_arena,
2909 &other->_impl_.name_, rhs_arena
2910 );
2911 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
2912 PROTOBUF_FIELD_OFFSET(LayerCreationArgs, _impl_.layer_stack_to_mirror_)
2913 + sizeof(LayerCreationArgs::_impl_.layer_stack_to_mirror_) // NOLINT
2914 - PROTOBUF_FIELD_OFFSET(LayerCreationArgs, _impl_.layer_id_)>(
2915 reinterpret_cast<char*>(&_impl_.layer_id_),
2916 reinterpret_cast<char*>(&other->_impl_.layer_id_));
2917 }
2918
GetTypeName() const2919 std::string LayerCreationArgs::GetTypeName() const {
2920 return "perfetto.protos.LayerCreationArgs";
2921 }
2922
2923
2924 // ===================================================================
2925
2926 class Transform::_Internal {
2927 public:
2928 using HasBits = decltype(std::declval<Transform>()._impl_._has_bits_);
set_has_dsdx(HasBits * has_bits)2929 static void set_has_dsdx(HasBits* has_bits) {
2930 (*has_bits)[0] |= 1u;
2931 }
set_has_dtdx(HasBits * has_bits)2932 static void set_has_dtdx(HasBits* has_bits) {
2933 (*has_bits)[0] |= 2u;
2934 }
set_has_dtdy(HasBits * has_bits)2935 static void set_has_dtdy(HasBits* has_bits) {
2936 (*has_bits)[0] |= 4u;
2937 }
set_has_dsdy(HasBits * has_bits)2938 static void set_has_dsdy(HasBits* has_bits) {
2939 (*has_bits)[0] |= 8u;
2940 }
set_has_tx(HasBits * has_bits)2941 static void set_has_tx(HasBits* has_bits) {
2942 (*has_bits)[0] |= 16u;
2943 }
set_has_ty(HasBits * has_bits)2944 static void set_has_ty(HasBits* has_bits) {
2945 (*has_bits)[0] |= 32u;
2946 }
2947 };
2948
Transform(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)2949 Transform::Transform(::PROTOBUF_NAMESPACE_ID::Arena* arena,
2950 bool is_message_owned)
2951 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
2952 SharedCtor(arena, is_message_owned);
2953 // @@protoc_insertion_point(arena_constructor:perfetto.protos.Transform)
2954 }
Transform(const Transform & from)2955 Transform::Transform(const Transform& from)
2956 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
2957 Transform* const _this = this; (void)_this;
2958 new (&_impl_) Impl_{
2959 decltype(_impl_._has_bits_){from._impl_._has_bits_}
2960 , /*decltype(_impl_._cached_size_)*/{}
2961 , decltype(_impl_.dsdx_){}
2962 , decltype(_impl_.dtdx_){}
2963 , decltype(_impl_.dtdy_){}
2964 , decltype(_impl_.dsdy_){}
2965 , decltype(_impl_.tx_){}
2966 , decltype(_impl_.ty_){}};
2967
2968 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
2969 ::memcpy(&_impl_.dsdx_, &from._impl_.dsdx_,
2970 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.ty_) -
2971 reinterpret_cast<char*>(&_impl_.dsdx_)) + sizeof(_impl_.ty_));
2972 // @@protoc_insertion_point(copy_constructor:perfetto.protos.Transform)
2973 }
2974
SharedCtor(::_pb::Arena * arena,bool is_message_owned)2975 inline void Transform::SharedCtor(
2976 ::_pb::Arena* arena, bool is_message_owned) {
2977 (void)arena;
2978 (void)is_message_owned;
2979 new (&_impl_) Impl_{
2980 decltype(_impl_._has_bits_){}
2981 , /*decltype(_impl_._cached_size_)*/{}
2982 , decltype(_impl_.dsdx_){0}
2983 , decltype(_impl_.dtdx_){0}
2984 , decltype(_impl_.dtdy_){0}
2985 , decltype(_impl_.dsdy_){0}
2986 , decltype(_impl_.tx_){0}
2987 , decltype(_impl_.ty_){0}
2988 };
2989 }
2990
~Transform()2991 Transform::~Transform() {
2992 // @@protoc_insertion_point(destructor:perfetto.protos.Transform)
2993 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
2994 (void)arena;
2995 return;
2996 }
2997 SharedDtor();
2998 }
2999
SharedDtor()3000 inline void Transform::SharedDtor() {
3001 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
3002 }
3003
SetCachedSize(int size) const3004 void Transform::SetCachedSize(int size) const {
3005 _impl_._cached_size_.Set(size);
3006 }
3007
Clear()3008 void Transform::Clear() {
3009 // @@protoc_insertion_point(message_clear_start:perfetto.protos.Transform)
3010 ::uint32_t cached_has_bits = 0;
3011 // Prevent compiler warnings about cached_has_bits being unused
3012 (void) cached_has_bits;
3013
3014 cached_has_bits = _impl_._has_bits_[0];
3015 if (cached_has_bits & 0x0000003fu) {
3016 ::memset(&_impl_.dsdx_, 0, static_cast<size_t>(
3017 reinterpret_cast<char*>(&_impl_.ty_) -
3018 reinterpret_cast<char*>(&_impl_.dsdx_)) + sizeof(_impl_.ty_));
3019 }
3020 _impl_._has_bits_.Clear();
3021 _internal_metadata_.Clear<std::string>();
3022 }
3023
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)3024 const char* Transform::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
3025 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
3026 _Internal::HasBits has_bits{};
3027 while (!ctx->Done(&ptr)) {
3028 ::uint32_t tag;
3029 ptr = ::_pbi::ReadTag(ptr, &tag);
3030 switch (tag >> 3) {
3031 // optional float dsdx = 1;
3032 case 1:
3033 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 13)) {
3034 _Internal::set_has_dsdx(&has_bits);
3035 _impl_.dsdx_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3036 ptr += sizeof(float);
3037 } else {
3038 goto handle_unusual;
3039 }
3040 continue;
3041 // optional float dtdx = 2;
3042 case 2:
3043 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 21)) {
3044 _Internal::set_has_dtdx(&has_bits);
3045 _impl_.dtdx_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3046 ptr += sizeof(float);
3047 } else {
3048 goto handle_unusual;
3049 }
3050 continue;
3051 // optional float dtdy = 3;
3052 case 3:
3053 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 29)) {
3054 _Internal::set_has_dtdy(&has_bits);
3055 _impl_.dtdy_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3056 ptr += sizeof(float);
3057 } else {
3058 goto handle_unusual;
3059 }
3060 continue;
3061 // optional float dsdy = 4;
3062 case 4:
3063 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 37)) {
3064 _Internal::set_has_dsdy(&has_bits);
3065 _impl_.dsdy_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3066 ptr += sizeof(float);
3067 } else {
3068 goto handle_unusual;
3069 }
3070 continue;
3071 // optional float tx = 5;
3072 case 5:
3073 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 45)) {
3074 _Internal::set_has_tx(&has_bits);
3075 _impl_.tx_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3076 ptr += sizeof(float);
3077 } else {
3078 goto handle_unusual;
3079 }
3080 continue;
3081 // optional float ty = 6;
3082 case 6:
3083 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 53)) {
3084 _Internal::set_has_ty(&has_bits);
3085 _impl_.ty_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3086 ptr += sizeof(float);
3087 } else {
3088 goto handle_unusual;
3089 }
3090 continue;
3091 default:
3092 goto handle_unusual;
3093 } // switch
3094 handle_unusual:
3095 if ((tag == 0) || ((tag & 7) == 4)) {
3096 CHK_(ptr);
3097 ctx->SetLastTag(tag);
3098 goto message_done;
3099 }
3100 ptr = UnknownFieldParse(
3101 tag,
3102 _internal_metadata_.mutable_unknown_fields<std::string>(),
3103 ptr, ctx);
3104 CHK_(ptr != nullptr);
3105 } // while
3106 message_done:
3107 _impl_._has_bits_.Or(has_bits);
3108 return ptr;
3109 failure:
3110 ptr = nullptr;
3111 goto message_done;
3112 #undef CHK_
3113 }
3114
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const3115 ::uint8_t* Transform::_InternalSerialize(
3116 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
3117 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.Transform)
3118 ::uint32_t cached_has_bits = 0;
3119 (void) cached_has_bits;
3120
3121 cached_has_bits = _impl_._has_bits_[0];
3122 // optional float dsdx = 1;
3123 if (cached_has_bits & 0x00000001u) {
3124 target = stream->EnsureSpace(target);
3125 target = ::_pbi::WireFormatLite::WriteFloatToArray(1, this->_internal_dsdx(), target);
3126 }
3127
3128 // optional float dtdx = 2;
3129 if (cached_has_bits & 0x00000002u) {
3130 target = stream->EnsureSpace(target);
3131 target = ::_pbi::WireFormatLite::WriteFloatToArray(2, this->_internal_dtdx(), target);
3132 }
3133
3134 // optional float dtdy = 3;
3135 if (cached_has_bits & 0x00000004u) {
3136 target = stream->EnsureSpace(target);
3137 target = ::_pbi::WireFormatLite::WriteFloatToArray(3, this->_internal_dtdy(), target);
3138 }
3139
3140 // optional float dsdy = 4;
3141 if (cached_has_bits & 0x00000008u) {
3142 target = stream->EnsureSpace(target);
3143 target = ::_pbi::WireFormatLite::WriteFloatToArray(4, this->_internal_dsdy(), target);
3144 }
3145
3146 // optional float tx = 5;
3147 if (cached_has_bits & 0x00000010u) {
3148 target = stream->EnsureSpace(target);
3149 target = ::_pbi::WireFormatLite::WriteFloatToArray(5, this->_internal_tx(), target);
3150 }
3151
3152 // optional float ty = 6;
3153 if (cached_has_bits & 0x00000020u) {
3154 target = stream->EnsureSpace(target);
3155 target = ::_pbi::WireFormatLite::WriteFloatToArray(6, this->_internal_ty(), target);
3156 }
3157
3158 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3159 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
3160 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
3161 }
3162 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.Transform)
3163 return target;
3164 }
3165
ByteSizeLong() const3166 size_t Transform::ByteSizeLong() const {
3167 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.Transform)
3168 size_t total_size = 0;
3169
3170 ::uint32_t cached_has_bits = 0;
3171 // Prevent compiler warnings about cached_has_bits being unused
3172 (void) cached_has_bits;
3173
3174 cached_has_bits = _impl_._has_bits_[0];
3175 if (cached_has_bits & 0x0000003fu) {
3176 // optional float dsdx = 1;
3177 if (cached_has_bits & 0x00000001u) {
3178 total_size += 1 + 4;
3179 }
3180
3181 // optional float dtdx = 2;
3182 if (cached_has_bits & 0x00000002u) {
3183 total_size += 1 + 4;
3184 }
3185
3186 // optional float dtdy = 3;
3187 if (cached_has_bits & 0x00000004u) {
3188 total_size += 1 + 4;
3189 }
3190
3191 // optional float dsdy = 4;
3192 if (cached_has_bits & 0x00000008u) {
3193 total_size += 1 + 4;
3194 }
3195
3196 // optional float tx = 5;
3197 if (cached_has_bits & 0x00000010u) {
3198 total_size += 1 + 4;
3199 }
3200
3201 // optional float ty = 6;
3202 if (cached_has_bits & 0x00000020u) {
3203 total_size += 1 + 4;
3204 }
3205
3206 }
3207 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3208 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
3209 }
3210 int cached_size = ::_pbi::ToCachedSize(total_size);
3211 SetCachedSize(cached_size);
3212 return total_size;
3213 }
3214
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)3215 void Transform::CheckTypeAndMergeFrom(
3216 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
3217 MergeFrom(*::_pbi::DownCast<const Transform*>(
3218 &from));
3219 }
3220
MergeFrom(const Transform & from)3221 void Transform::MergeFrom(const Transform& from) {
3222 Transform* const _this = this;
3223 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.Transform)
3224 GOOGLE_DCHECK_NE(&from, _this);
3225 ::uint32_t cached_has_bits = 0;
3226 (void) cached_has_bits;
3227
3228 cached_has_bits = from._impl_._has_bits_[0];
3229 if (cached_has_bits & 0x0000003fu) {
3230 if (cached_has_bits & 0x00000001u) {
3231 _this->_impl_.dsdx_ = from._impl_.dsdx_;
3232 }
3233 if (cached_has_bits & 0x00000002u) {
3234 _this->_impl_.dtdx_ = from._impl_.dtdx_;
3235 }
3236 if (cached_has_bits & 0x00000004u) {
3237 _this->_impl_.dtdy_ = from._impl_.dtdy_;
3238 }
3239 if (cached_has_bits & 0x00000008u) {
3240 _this->_impl_.dsdy_ = from._impl_.dsdy_;
3241 }
3242 if (cached_has_bits & 0x00000010u) {
3243 _this->_impl_.tx_ = from._impl_.tx_;
3244 }
3245 if (cached_has_bits & 0x00000020u) {
3246 _this->_impl_.ty_ = from._impl_.ty_;
3247 }
3248 _this->_impl_._has_bits_[0] |= cached_has_bits;
3249 }
3250 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
3251 }
3252
CopyFrom(const Transform & from)3253 void Transform::CopyFrom(const Transform& from) {
3254 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.Transform)
3255 if (&from == this) return;
3256 Clear();
3257 MergeFrom(from);
3258 }
3259
IsInitialized() const3260 bool Transform::IsInitialized() const {
3261 return true;
3262 }
3263
InternalSwap(Transform * other)3264 void Transform::InternalSwap(Transform* other) {
3265 using std::swap;
3266 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
3267 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
3268 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
3269 PROTOBUF_FIELD_OFFSET(Transform, _impl_.ty_)
3270 + sizeof(Transform::_impl_.ty_) // NOLINT
3271 - PROTOBUF_FIELD_OFFSET(Transform, _impl_.dsdx_)>(
3272 reinterpret_cast<char*>(&_impl_.dsdx_),
3273 reinterpret_cast<char*>(&other->_impl_.dsdx_));
3274 }
3275
GetTypeName() const3276 std::string Transform::GetTypeName() const {
3277 return "perfetto.protos.Transform";
3278 }
3279
3280
3281 // ===================================================================
3282
3283 class TransactionState::_Internal {
3284 public:
3285 using HasBits = decltype(std::declval<TransactionState>()._impl_._has_bits_);
set_has_pid(HasBits * has_bits)3286 static void set_has_pid(HasBits* has_bits) {
3287 (*has_bits)[0] |= 1u;
3288 }
set_has_uid(HasBits * has_bits)3289 static void set_has_uid(HasBits* has_bits) {
3290 (*has_bits)[0] |= 2u;
3291 }
set_has_vsync_id(HasBits * has_bits)3292 static void set_has_vsync_id(HasBits* has_bits) {
3293 (*has_bits)[0] |= 4u;
3294 }
set_has_input_event_id(HasBits * has_bits)3295 static void set_has_input_event_id(HasBits* has_bits) {
3296 (*has_bits)[0] |= 32u;
3297 }
set_has_post_time(HasBits * has_bits)3298 static void set_has_post_time(HasBits* has_bits) {
3299 (*has_bits)[0] |= 8u;
3300 }
set_has_transaction_id(HasBits * has_bits)3301 static void set_has_transaction_id(HasBits* has_bits) {
3302 (*has_bits)[0] |= 16u;
3303 }
3304 };
3305
TransactionState(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)3306 TransactionState::TransactionState(::PROTOBUF_NAMESPACE_ID::Arena* arena,
3307 bool is_message_owned)
3308 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
3309 SharedCtor(arena, is_message_owned);
3310 // @@protoc_insertion_point(arena_constructor:perfetto.protos.TransactionState)
3311 }
TransactionState(const TransactionState & from)3312 TransactionState::TransactionState(const TransactionState& from)
3313 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
3314 TransactionState* const _this = this; (void)_this;
3315 new (&_impl_) Impl_{
3316 decltype(_impl_._has_bits_){from._impl_._has_bits_}
3317 , /*decltype(_impl_._cached_size_)*/{}
3318 , decltype(_impl_.layer_changes_){from._impl_.layer_changes_}
3319 , decltype(_impl_.display_changes_){from._impl_.display_changes_}
3320 , decltype(_impl_.merged_transaction_ids_){from._impl_.merged_transaction_ids_}
3321 , decltype(_impl_.pid_){}
3322 , decltype(_impl_.uid_){}
3323 , decltype(_impl_.vsync_id_){}
3324 , decltype(_impl_.post_time_){}
3325 , decltype(_impl_.transaction_id_){}
3326 , decltype(_impl_.input_event_id_){}};
3327
3328 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
3329 ::memcpy(&_impl_.pid_, &from._impl_.pid_,
3330 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.input_event_id_) -
3331 reinterpret_cast<char*>(&_impl_.pid_)) + sizeof(_impl_.input_event_id_));
3332 // @@protoc_insertion_point(copy_constructor:perfetto.protos.TransactionState)
3333 }
3334
SharedCtor(::_pb::Arena * arena,bool is_message_owned)3335 inline void TransactionState::SharedCtor(
3336 ::_pb::Arena* arena, bool is_message_owned) {
3337 (void)arena;
3338 (void)is_message_owned;
3339 new (&_impl_) Impl_{
3340 decltype(_impl_._has_bits_){}
3341 , /*decltype(_impl_._cached_size_)*/{}
3342 , decltype(_impl_.layer_changes_){arena}
3343 , decltype(_impl_.display_changes_){arena}
3344 , decltype(_impl_.merged_transaction_ids_){arena}
3345 , decltype(_impl_.pid_){0}
3346 , decltype(_impl_.uid_){0}
3347 , decltype(_impl_.vsync_id_){::int64_t{0}}
3348 , decltype(_impl_.post_time_){::int64_t{0}}
3349 , decltype(_impl_.transaction_id_){::uint64_t{0u}}
3350 , decltype(_impl_.input_event_id_){0}
3351 };
3352 }
3353
~TransactionState()3354 TransactionState::~TransactionState() {
3355 // @@protoc_insertion_point(destructor:perfetto.protos.TransactionState)
3356 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
3357 (void)arena;
3358 return;
3359 }
3360 SharedDtor();
3361 }
3362
SharedDtor()3363 inline void TransactionState::SharedDtor() {
3364 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
3365 _impl_.layer_changes_.~RepeatedPtrField();
3366 _impl_.display_changes_.~RepeatedPtrField();
3367 _impl_.merged_transaction_ids_.~RepeatedField();
3368 }
3369
SetCachedSize(int size) const3370 void TransactionState::SetCachedSize(int size) const {
3371 _impl_._cached_size_.Set(size);
3372 }
3373
Clear()3374 void TransactionState::Clear() {
3375 // @@protoc_insertion_point(message_clear_start:perfetto.protos.TransactionState)
3376 ::uint32_t cached_has_bits = 0;
3377 // Prevent compiler warnings about cached_has_bits being unused
3378 (void) cached_has_bits;
3379
3380 _impl_.layer_changes_.Clear();
3381 _impl_.display_changes_.Clear();
3382 _impl_.merged_transaction_ids_.Clear();
3383 cached_has_bits = _impl_._has_bits_[0];
3384 if (cached_has_bits & 0x0000003fu) {
3385 ::memset(&_impl_.pid_, 0, static_cast<size_t>(
3386 reinterpret_cast<char*>(&_impl_.input_event_id_) -
3387 reinterpret_cast<char*>(&_impl_.pid_)) + sizeof(_impl_.input_event_id_));
3388 }
3389 _impl_._has_bits_.Clear();
3390 _internal_metadata_.Clear<std::string>();
3391 }
3392
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)3393 const char* TransactionState::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
3394 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
3395 _Internal::HasBits has_bits{};
3396 while (!ctx->Done(&ptr)) {
3397 ::uint32_t tag;
3398 ptr = ::_pbi::ReadTag(ptr, &tag);
3399 switch (tag >> 3) {
3400 // optional int32 pid = 1;
3401 case 1:
3402 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
3403 _Internal::set_has_pid(&has_bits);
3404 _impl_.pid_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
3405 CHK_(ptr);
3406 } else {
3407 goto handle_unusual;
3408 }
3409 continue;
3410 // optional int32 uid = 2;
3411 case 2:
3412 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
3413 _Internal::set_has_uid(&has_bits);
3414 _impl_.uid_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
3415 CHK_(ptr);
3416 } else {
3417 goto handle_unusual;
3418 }
3419 continue;
3420 // optional int64 vsync_id = 3;
3421 case 3:
3422 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
3423 _Internal::set_has_vsync_id(&has_bits);
3424 _impl_.vsync_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
3425 CHK_(ptr);
3426 } else {
3427 goto handle_unusual;
3428 }
3429 continue;
3430 // optional int32 input_event_id = 4;
3431 case 4:
3432 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
3433 _Internal::set_has_input_event_id(&has_bits);
3434 _impl_.input_event_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
3435 CHK_(ptr);
3436 } else {
3437 goto handle_unusual;
3438 }
3439 continue;
3440 // optional int64 post_time = 5;
3441 case 5:
3442 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
3443 _Internal::set_has_post_time(&has_bits);
3444 _impl_.post_time_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
3445 CHK_(ptr);
3446 } else {
3447 goto handle_unusual;
3448 }
3449 continue;
3450 // optional uint64 transaction_id = 6;
3451 case 6:
3452 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
3453 _Internal::set_has_transaction_id(&has_bits);
3454 _impl_.transaction_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
3455 CHK_(ptr);
3456 } else {
3457 goto handle_unusual;
3458 }
3459 continue;
3460 // repeated .perfetto.protos.LayerState layer_changes = 7;
3461 case 7:
3462 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 58)) {
3463 ptr -= 1;
3464 do {
3465 ptr += 1;
3466 ptr = ctx->ParseMessage(_internal_add_layer_changes(), ptr);
3467 CHK_(ptr);
3468 if (!ctx->DataAvailable(ptr)) break;
3469 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<58>(ptr));
3470 } else {
3471 goto handle_unusual;
3472 }
3473 continue;
3474 // repeated .perfetto.protos.DisplayState display_changes = 8;
3475 case 8:
3476 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 66)) {
3477 ptr -= 1;
3478 do {
3479 ptr += 1;
3480 ptr = ctx->ParseMessage(_internal_add_display_changes(), ptr);
3481 CHK_(ptr);
3482 if (!ctx->DataAvailable(ptr)) break;
3483 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<66>(ptr));
3484 } else {
3485 goto handle_unusual;
3486 }
3487 continue;
3488 // repeated uint64 merged_transaction_ids = 9;
3489 case 9:
3490 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
3491 ptr -= 1;
3492 do {
3493 ptr += 1;
3494 _internal_add_merged_transaction_ids(::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr));
3495 CHK_(ptr);
3496 if (!ctx->DataAvailable(ptr)) break;
3497 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<72>(ptr));
3498 } else if (static_cast<::uint8_t>(tag) == 74) {
3499 ptr = ::PROTOBUF_NAMESPACE_ID::internal::PackedUInt64Parser(_internal_mutable_merged_transaction_ids(), ptr, ctx);
3500 CHK_(ptr);
3501 } else {
3502 goto handle_unusual;
3503 }
3504 continue;
3505 default:
3506 goto handle_unusual;
3507 } // switch
3508 handle_unusual:
3509 if ((tag == 0) || ((tag & 7) == 4)) {
3510 CHK_(ptr);
3511 ctx->SetLastTag(tag);
3512 goto message_done;
3513 }
3514 ptr = UnknownFieldParse(
3515 tag,
3516 _internal_metadata_.mutable_unknown_fields<std::string>(),
3517 ptr, ctx);
3518 CHK_(ptr != nullptr);
3519 } // while
3520 message_done:
3521 _impl_._has_bits_.Or(has_bits);
3522 return ptr;
3523 failure:
3524 ptr = nullptr;
3525 goto message_done;
3526 #undef CHK_
3527 }
3528
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const3529 ::uint8_t* TransactionState::_InternalSerialize(
3530 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
3531 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.TransactionState)
3532 ::uint32_t cached_has_bits = 0;
3533 (void) cached_has_bits;
3534
3535 cached_has_bits = _impl_._has_bits_[0];
3536 // optional int32 pid = 1;
3537 if (cached_has_bits & 0x00000001u) {
3538 target = stream->EnsureSpace(target);
3539 target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_pid(), target);
3540 }
3541
3542 // optional int32 uid = 2;
3543 if (cached_has_bits & 0x00000002u) {
3544 target = stream->EnsureSpace(target);
3545 target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_uid(), target);
3546 }
3547
3548 // optional int64 vsync_id = 3;
3549 if (cached_has_bits & 0x00000004u) {
3550 target = stream->EnsureSpace(target);
3551 target = ::_pbi::WireFormatLite::WriteInt64ToArray(3, this->_internal_vsync_id(), target);
3552 }
3553
3554 // optional int32 input_event_id = 4;
3555 if (cached_has_bits & 0x00000020u) {
3556 target = stream->EnsureSpace(target);
3557 target = ::_pbi::WireFormatLite::WriteInt32ToArray(4, this->_internal_input_event_id(), target);
3558 }
3559
3560 // optional int64 post_time = 5;
3561 if (cached_has_bits & 0x00000008u) {
3562 target = stream->EnsureSpace(target);
3563 target = ::_pbi::WireFormatLite::WriteInt64ToArray(5, this->_internal_post_time(), target);
3564 }
3565
3566 // optional uint64 transaction_id = 6;
3567 if (cached_has_bits & 0x00000010u) {
3568 target = stream->EnsureSpace(target);
3569 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(6, this->_internal_transaction_id(), target);
3570 }
3571
3572 // repeated .perfetto.protos.LayerState layer_changes = 7;
3573 for (unsigned i = 0,
3574 n = static_cast<unsigned>(this->_internal_layer_changes_size()); i < n; i++) {
3575 const auto& repfield = this->_internal_layer_changes(i);
3576 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
3577 InternalWriteMessage(7, repfield, repfield.GetCachedSize(), target, stream);
3578 }
3579
3580 // repeated .perfetto.protos.DisplayState display_changes = 8;
3581 for (unsigned i = 0,
3582 n = static_cast<unsigned>(this->_internal_display_changes_size()); i < n; i++) {
3583 const auto& repfield = this->_internal_display_changes(i);
3584 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
3585 InternalWriteMessage(8, repfield, repfield.GetCachedSize(), target, stream);
3586 }
3587
3588 // repeated uint64 merged_transaction_ids = 9;
3589 for (int i = 0, n = this->_internal_merged_transaction_ids_size(); i < n; i++) {
3590 target = stream->EnsureSpace(target);
3591 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(9, this->_internal_merged_transaction_ids(i), target);
3592 }
3593
3594 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3595 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
3596 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
3597 }
3598 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.TransactionState)
3599 return target;
3600 }
3601
ByteSizeLong() const3602 size_t TransactionState::ByteSizeLong() const {
3603 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.TransactionState)
3604 size_t total_size = 0;
3605
3606 ::uint32_t cached_has_bits = 0;
3607 // Prevent compiler warnings about cached_has_bits being unused
3608 (void) cached_has_bits;
3609
3610 // repeated .perfetto.protos.LayerState layer_changes = 7;
3611 total_size += 1UL * this->_internal_layer_changes_size();
3612 for (const auto& msg : this->_impl_.layer_changes_) {
3613 total_size +=
3614 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
3615 }
3616
3617 // repeated .perfetto.protos.DisplayState display_changes = 8;
3618 total_size += 1UL * this->_internal_display_changes_size();
3619 for (const auto& msg : this->_impl_.display_changes_) {
3620 total_size +=
3621 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
3622 }
3623
3624 // repeated uint64 merged_transaction_ids = 9;
3625 {
3626 size_t data_size = ::_pbi::WireFormatLite::
3627 UInt64Size(this->_impl_.merged_transaction_ids_);
3628 total_size += 1 *
3629 ::_pbi::FromIntSize(this->_internal_merged_transaction_ids_size());
3630 total_size += data_size;
3631 }
3632
3633 cached_has_bits = _impl_._has_bits_[0];
3634 if (cached_has_bits & 0x0000003fu) {
3635 // optional int32 pid = 1;
3636 if (cached_has_bits & 0x00000001u) {
3637 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_pid());
3638 }
3639
3640 // optional int32 uid = 2;
3641 if (cached_has_bits & 0x00000002u) {
3642 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_uid());
3643 }
3644
3645 // optional int64 vsync_id = 3;
3646 if (cached_has_bits & 0x00000004u) {
3647 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_vsync_id());
3648 }
3649
3650 // optional int64 post_time = 5;
3651 if (cached_has_bits & 0x00000008u) {
3652 total_size += ::_pbi::WireFormatLite::Int64SizePlusOne(this->_internal_post_time());
3653 }
3654
3655 // optional uint64 transaction_id = 6;
3656 if (cached_has_bits & 0x00000010u) {
3657 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_transaction_id());
3658 }
3659
3660 // optional int32 input_event_id = 4;
3661 if (cached_has_bits & 0x00000020u) {
3662 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_input_event_id());
3663 }
3664
3665 }
3666 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3667 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
3668 }
3669 int cached_size = ::_pbi::ToCachedSize(total_size);
3670 SetCachedSize(cached_size);
3671 return total_size;
3672 }
3673
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)3674 void TransactionState::CheckTypeAndMergeFrom(
3675 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
3676 MergeFrom(*::_pbi::DownCast<const TransactionState*>(
3677 &from));
3678 }
3679
MergeFrom(const TransactionState & from)3680 void TransactionState::MergeFrom(const TransactionState& from) {
3681 TransactionState* const _this = this;
3682 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.TransactionState)
3683 GOOGLE_DCHECK_NE(&from, _this);
3684 ::uint32_t cached_has_bits = 0;
3685 (void) cached_has_bits;
3686
3687 _this->_impl_.layer_changes_.MergeFrom(from._impl_.layer_changes_);
3688 _this->_impl_.display_changes_.MergeFrom(from._impl_.display_changes_);
3689 _this->_impl_.merged_transaction_ids_.MergeFrom(from._impl_.merged_transaction_ids_);
3690 cached_has_bits = from._impl_._has_bits_[0];
3691 if (cached_has_bits & 0x0000003fu) {
3692 if (cached_has_bits & 0x00000001u) {
3693 _this->_impl_.pid_ = from._impl_.pid_;
3694 }
3695 if (cached_has_bits & 0x00000002u) {
3696 _this->_impl_.uid_ = from._impl_.uid_;
3697 }
3698 if (cached_has_bits & 0x00000004u) {
3699 _this->_impl_.vsync_id_ = from._impl_.vsync_id_;
3700 }
3701 if (cached_has_bits & 0x00000008u) {
3702 _this->_impl_.post_time_ = from._impl_.post_time_;
3703 }
3704 if (cached_has_bits & 0x00000010u) {
3705 _this->_impl_.transaction_id_ = from._impl_.transaction_id_;
3706 }
3707 if (cached_has_bits & 0x00000020u) {
3708 _this->_impl_.input_event_id_ = from._impl_.input_event_id_;
3709 }
3710 _this->_impl_._has_bits_[0] |= cached_has_bits;
3711 }
3712 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
3713 }
3714
CopyFrom(const TransactionState & from)3715 void TransactionState::CopyFrom(const TransactionState& from) {
3716 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.TransactionState)
3717 if (&from == this) return;
3718 Clear();
3719 MergeFrom(from);
3720 }
3721
IsInitialized() const3722 bool TransactionState::IsInitialized() const {
3723 return true;
3724 }
3725
InternalSwap(TransactionState * other)3726 void TransactionState::InternalSwap(TransactionState* other) {
3727 using std::swap;
3728 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
3729 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
3730 _impl_.layer_changes_.InternalSwap(&other->_impl_.layer_changes_);
3731 _impl_.display_changes_.InternalSwap(&other->_impl_.display_changes_);
3732 _impl_.merged_transaction_ids_.InternalSwap(&other->_impl_.merged_transaction_ids_);
3733 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
3734 PROTOBUF_FIELD_OFFSET(TransactionState, _impl_.input_event_id_)
3735 + sizeof(TransactionState::_impl_.input_event_id_) // NOLINT
3736 - PROTOBUF_FIELD_OFFSET(TransactionState, _impl_.pid_)>(
3737 reinterpret_cast<char*>(&_impl_.pid_),
3738 reinterpret_cast<char*>(&other->_impl_.pid_));
3739 }
3740
GetTypeName() const3741 std::string TransactionState::GetTypeName() const {
3742 return "perfetto.protos.TransactionState";
3743 }
3744
3745
3746 // ===================================================================
3747
3748 class LayerState_Matrix22::_Internal {
3749 public:
3750 using HasBits = decltype(std::declval<LayerState_Matrix22>()._impl_._has_bits_);
set_has_dsdx(HasBits * has_bits)3751 static void set_has_dsdx(HasBits* has_bits) {
3752 (*has_bits)[0] |= 1u;
3753 }
set_has_dtdx(HasBits * has_bits)3754 static void set_has_dtdx(HasBits* has_bits) {
3755 (*has_bits)[0] |= 2u;
3756 }
set_has_dtdy(HasBits * has_bits)3757 static void set_has_dtdy(HasBits* has_bits) {
3758 (*has_bits)[0] |= 4u;
3759 }
set_has_dsdy(HasBits * has_bits)3760 static void set_has_dsdy(HasBits* has_bits) {
3761 (*has_bits)[0] |= 8u;
3762 }
3763 };
3764
LayerState_Matrix22(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)3765 LayerState_Matrix22::LayerState_Matrix22(::PROTOBUF_NAMESPACE_ID::Arena* arena,
3766 bool is_message_owned)
3767 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
3768 SharedCtor(arena, is_message_owned);
3769 // @@protoc_insertion_point(arena_constructor:perfetto.protos.LayerState.Matrix22)
3770 }
LayerState_Matrix22(const LayerState_Matrix22 & from)3771 LayerState_Matrix22::LayerState_Matrix22(const LayerState_Matrix22& from)
3772 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
3773 LayerState_Matrix22* const _this = this; (void)_this;
3774 new (&_impl_) Impl_{
3775 decltype(_impl_._has_bits_){from._impl_._has_bits_}
3776 , /*decltype(_impl_._cached_size_)*/{}
3777 , decltype(_impl_.dsdx_){}
3778 , decltype(_impl_.dtdx_){}
3779 , decltype(_impl_.dtdy_){}
3780 , decltype(_impl_.dsdy_){}};
3781
3782 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
3783 ::memcpy(&_impl_.dsdx_, &from._impl_.dsdx_,
3784 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.dsdy_) -
3785 reinterpret_cast<char*>(&_impl_.dsdx_)) + sizeof(_impl_.dsdy_));
3786 // @@protoc_insertion_point(copy_constructor:perfetto.protos.LayerState.Matrix22)
3787 }
3788
SharedCtor(::_pb::Arena * arena,bool is_message_owned)3789 inline void LayerState_Matrix22::SharedCtor(
3790 ::_pb::Arena* arena, bool is_message_owned) {
3791 (void)arena;
3792 (void)is_message_owned;
3793 new (&_impl_) Impl_{
3794 decltype(_impl_._has_bits_){}
3795 , /*decltype(_impl_._cached_size_)*/{}
3796 , decltype(_impl_.dsdx_){0}
3797 , decltype(_impl_.dtdx_){0}
3798 , decltype(_impl_.dtdy_){0}
3799 , decltype(_impl_.dsdy_){0}
3800 };
3801 }
3802
~LayerState_Matrix22()3803 LayerState_Matrix22::~LayerState_Matrix22() {
3804 // @@protoc_insertion_point(destructor:perfetto.protos.LayerState.Matrix22)
3805 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
3806 (void)arena;
3807 return;
3808 }
3809 SharedDtor();
3810 }
3811
SharedDtor()3812 inline void LayerState_Matrix22::SharedDtor() {
3813 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
3814 }
3815
SetCachedSize(int size) const3816 void LayerState_Matrix22::SetCachedSize(int size) const {
3817 _impl_._cached_size_.Set(size);
3818 }
3819
Clear()3820 void LayerState_Matrix22::Clear() {
3821 // @@protoc_insertion_point(message_clear_start:perfetto.protos.LayerState.Matrix22)
3822 ::uint32_t cached_has_bits = 0;
3823 // Prevent compiler warnings about cached_has_bits being unused
3824 (void) cached_has_bits;
3825
3826 cached_has_bits = _impl_._has_bits_[0];
3827 if (cached_has_bits & 0x0000000fu) {
3828 ::memset(&_impl_.dsdx_, 0, static_cast<size_t>(
3829 reinterpret_cast<char*>(&_impl_.dsdy_) -
3830 reinterpret_cast<char*>(&_impl_.dsdx_)) + sizeof(_impl_.dsdy_));
3831 }
3832 _impl_._has_bits_.Clear();
3833 _internal_metadata_.Clear<std::string>();
3834 }
3835
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)3836 const char* LayerState_Matrix22::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
3837 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
3838 _Internal::HasBits has_bits{};
3839 while (!ctx->Done(&ptr)) {
3840 ::uint32_t tag;
3841 ptr = ::_pbi::ReadTag(ptr, &tag);
3842 switch (tag >> 3) {
3843 // optional float dsdx = 1;
3844 case 1:
3845 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 13)) {
3846 _Internal::set_has_dsdx(&has_bits);
3847 _impl_.dsdx_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3848 ptr += sizeof(float);
3849 } else {
3850 goto handle_unusual;
3851 }
3852 continue;
3853 // optional float dtdx = 2;
3854 case 2:
3855 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 21)) {
3856 _Internal::set_has_dtdx(&has_bits);
3857 _impl_.dtdx_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3858 ptr += sizeof(float);
3859 } else {
3860 goto handle_unusual;
3861 }
3862 continue;
3863 // optional float dtdy = 3;
3864 case 3:
3865 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 29)) {
3866 _Internal::set_has_dtdy(&has_bits);
3867 _impl_.dtdy_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3868 ptr += sizeof(float);
3869 } else {
3870 goto handle_unusual;
3871 }
3872 continue;
3873 // optional float dsdy = 4;
3874 case 4:
3875 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 37)) {
3876 _Internal::set_has_dsdy(&has_bits);
3877 _impl_.dsdy_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
3878 ptr += sizeof(float);
3879 } else {
3880 goto handle_unusual;
3881 }
3882 continue;
3883 default:
3884 goto handle_unusual;
3885 } // switch
3886 handle_unusual:
3887 if ((tag == 0) || ((tag & 7) == 4)) {
3888 CHK_(ptr);
3889 ctx->SetLastTag(tag);
3890 goto message_done;
3891 }
3892 ptr = UnknownFieldParse(
3893 tag,
3894 _internal_metadata_.mutable_unknown_fields<std::string>(),
3895 ptr, ctx);
3896 CHK_(ptr != nullptr);
3897 } // while
3898 message_done:
3899 _impl_._has_bits_.Or(has_bits);
3900 return ptr;
3901 failure:
3902 ptr = nullptr;
3903 goto message_done;
3904 #undef CHK_
3905 }
3906
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const3907 ::uint8_t* LayerState_Matrix22::_InternalSerialize(
3908 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
3909 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.LayerState.Matrix22)
3910 ::uint32_t cached_has_bits = 0;
3911 (void) cached_has_bits;
3912
3913 cached_has_bits = _impl_._has_bits_[0];
3914 // optional float dsdx = 1;
3915 if (cached_has_bits & 0x00000001u) {
3916 target = stream->EnsureSpace(target);
3917 target = ::_pbi::WireFormatLite::WriteFloatToArray(1, this->_internal_dsdx(), target);
3918 }
3919
3920 // optional float dtdx = 2;
3921 if (cached_has_bits & 0x00000002u) {
3922 target = stream->EnsureSpace(target);
3923 target = ::_pbi::WireFormatLite::WriteFloatToArray(2, this->_internal_dtdx(), target);
3924 }
3925
3926 // optional float dtdy = 3;
3927 if (cached_has_bits & 0x00000004u) {
3928 target = stream->EnsureSpace(target);
3929 target = ::_pbi::WireFormatLite::WriteFloatToArray(3, this->_internal_dtdy(), target);
3930 }
3931
3932 // optional float dsdy = 4;
3933 if (cached_has_bits & 0x00000008u) {
3934 target = stream->EnsureSpace(target);
3935 target = ::_pbi::WireFormatLite::WriteFloatToArray(4, this->_internal_dsdy(), target);
3936 }
3937
3938 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3939 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
3940 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
3941 }
3942 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.LayerState.Matrix22)
3943 return target;
3944 }
3945
ByteSizeLong() const3946 size_t LayerState_Matrix22::ByteSizeLong() const {
3947 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.LayerState.Matrix22)
3948 size_t total_size = 0;
3949
3950 ::uint32_t cached_has_bits = 0;
3951 // Prevent compiler warnings about cached_has_bits being unused
3952 (void) cached_has_bits;
3953
3954 cached_has_bits = _impl_._has_bits_[0];
3955 if (cached_has_bits & 0x0000000fu) {
3956 // optional float dsdx = 1;
3957 if (cached_has_bits & 0x00000001u) {
3958 total_size += 1 + 4;
3959 }
3960
3961 // optional float dtdx = 2;
3962 if (cached_has_bits & 0x00000002u) {
3963 total_size += 1 + 4;
3964 }
3965
3966 // optional float dtdy = 3;
3967 if (cached_has_bits & 0x00000004u) {
3968 total_size += 1 + 4;
3969 }
3970
3971 // optional float dsdy = 4;
3972 if (cached_has_bits & 0x00000008u) {
3973 total_size += 1 + 4;
3974 }
3975
3976 }
3977 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
3978 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
3979 }
3980 int cached_size = ::_pbi::ToCachedSize(total_size);
3981 SetCachedSize(cached_size);
3982 return total_size;
3983 }
3984
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)3985 void LayerState_Matrix22::CheckTypeAndMergeFrom(
3986 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
3987 MergeFrom(*::_pbi::DownCast<const LayerState_Matrix22*>(
3988 &from));
3989 }
3990
MergeFrom(const LayerState_Matrix22 & from)3991 void LayerState_Matrix22::MergeFrom(const LayerState_Matrix22& from) {
3992 LayerState_Matrix22* const _this = this;
3993 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.LayerState.Matrix22)
3994 GOOGLE_DCHECK_NE(&from, _this);
3995 ::uint32_t cached_has_bits = 0;
3996 (void) cached_has_bits;
3997
3998 cached_has_bits = from._impl_._has_bits_[0];
3999 if (cached_has_bits & 0x0000000fu) {
4000 if (cached_has_bits & 0x00000001u) {
4001 _this->_impl_.dsdx_ = from._impl_.dsdx_;
4002 }
4003 if (cached_has_bits & 0x00000002u) {
4004 _this->_impl_.dtdx_ = from._impl_.dtdx_;
4005 }
4006 if (cached_has_bits & 0x00000004u) {
4007 _this->_impl_.dtdy_ = from._impl_.dtdy_;
4008 }
4009 if (cached_has_bits & 0x00000008u) {
4010 _this->_impl_.dsdy_ = from._impl_.dsdy_;
4011 }
4012 _this->_impl_._has_bits_[0] |= cached_has_bits;
4013 }
4014 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4015 }
4016
CopyFrom(const LayerState_Matrix22 & from)4017 void LayerState_Matrix22::CopyFrom(const LayerState_Matrix22& from) {
4018 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.LayerState.Matrix22)
4019 if (&from == this) return;
4020 Clear();
4021 MergeFrom(from);
4022 }
4023
IsInitialized() const4024 bool LayerState_Matrix22::IsInitialized() const {
4025 return true;
4026 }
4027
InternalSwap(LayerState_Matrix22 * other)4028 void LayerState_Matrix22::InternalSwap(LayerState_Matrix22* other) {
4029 using std::swap;
4030 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
4031 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
4032 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
4033 PROTOBUF_FIELD_OFFSET(LayerState_Matrix22, _impl_.dsdy_)
4034 + sizeof(LayerState_Matrix22::_impl_.dsdy_) // NOLINT
4035 - PROTOBUF_FIELD_OFFSET(LayerState_Matrix22, _impl_.dsdx_)>(
4036 reinterpret_cast<char*>(&_impl_.dsdx_),
4037 reinterpret_cast<char*>(&other->_impl_.dsdx_));
4038 }
4039
GetTypeName() const4040 std::string LayerState_Matrix22::GetTypeName() const {
4041 return "perfetto.protos.LayerState.Matrix22";
4042 }
4043
4044
4045 // ===================================================================
4046
4047 class LayerState_Color3::_Internal {
4048 public:
4049 using HasBits = decltype(std::declval<LayerState_Color3>()._impl_._has_bits_);
set_has_r(HasBits * has_bits)4050 static void set_has_r(HasBits* has_bits) {
4051 (*has_bits)[0] |= 1u;
4052 }
set_has_g(HasBits * has_bits)4053 static void set_has_g(HasBits* has_bits) {
4054 (*has_bits)[0] |= 2u;
4055 }
set_has_b(HasBits * has_bits)4056 static void set_has_b(HasBits* has_bits) {
4057 (*has_bits)[0] |= 4u;
4058 }
4059 };
4060
LayerState_Color3(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)4061 LayerState_Color3::LayerState_Color3(::PROTOBUF_NAMESPACE_ID::Arena* arena,
4062 bool is_message_owned)
4063 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
4064 SharedCtor(arena, is_message_owned);
4065 // @@protoc_insertion_point(arena_constructor:perfetto.protos.LayerState.Color3)
4066 }
LayerState_Color3(const LayerState_Color3 & from)4067 LayerState_Color3::LayerState_Color3(const LayerState_Color3& from)
4068 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
4069 LayerState_Color3* const _this = this; (void)_this;
4070 new (&_impl_) Impl_{
4071 decltype(_impl_._has_bits_){from._impl_._has_bits_}
4072 , /*decltype(_impl_._cached_size_)*/{}
4073 , decltype(_impl_.r_){}
4074 , decltype(_impl_.g_){}
4075 , decltype(_impl_.b_){}};
4076
4077 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4078 ::memcpy(&_impl_.r_, &from._impl_.r_,
4079 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.b_) -
4080 reinterpret_cast<char*>(&_impl_.r_)) + sizeof(_impl_.b_));
4081 // @@protoc_insertion_point(copy_constructor:perfetto.protos.LayerState.Color3)
4082 }
4083
SharedCtor(::_pb::Arena * arena,bool is_message_owned)4084 inline void LayerState_Color3::SharedCtor(
4085 ::_pb::Arena* arena, bool is_message_owned) {
4086 (void)arena;
4087 (void)is_message_owned;
4088 new (&_impl_) Impl_{
4089 decltype(_impl_._has_bits_){}
4090 , /*decltype(_impl_._cached_size_)*/{}
4091 , decltype(_impl_.r_){0}
4092 , decltype(_impl_.g_){0}
4093 , decltype(_impl_.b_){0}
4094 };
4095 }
4096
~LayerState_Color3()4097 LayerState_Color3::~LayerState_Color3() {
4098 // @@protoc_insertion_point(destructor:perfetto.protos.LayerState.Color3)
4099 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
4100 (void)arena;
4101 return;
4102 }
4103 SharedDtor();
4104 }
4105
SharedDtor()4106 inline void LayerState_Color3::SharedDtor() {
4107 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
4108 }
4109
SetCachedSize(int size) const4110 void LayerState_Color3::SetCachedSize(int size) const {
4111 _impl_._cached_size_.Set(size);
4112 }
4113
Clear()4114 void LayerState_Color3::Clear() {
4115 // @@protoc_insertion_point(message_clear_start:perfetto.protos.LayerState.Color3)
4116 ::uint32_t cached_has_bits = 0;
4117 // Prevent compiler warnings about cached_has_bits being unused
4118 (void) cached_has_bits;
4119
4120 cached_has_bits = _impl_._has_bits_[0];
4121 if (cached_has_bits & 0x00000007u) {
4122 ::memset(&_impl_.r_, 0, static_cast<size_t>(
4123 reinterpret_cast<char*>(&_impl_.b_) -
4124 reinterpret_cast<char*>(&_impl_.r_)) + sizeof(_impl_.b_));
4125 }
4126 _impl_._has_bits_.Clear();
4127 _internal_metadata_.Clear<std::string>();
4128 }
4129
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)4130 const char* LayerState_Color3::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
4131 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
4132 _Internal::HasBits has_bits{};
4133 while (!ctx->Done(&ptr)) {
4134 ::uint32_t tag;
4135 ptr = ::_pbi::ReadTag(ptr, &tag);
4136 switch (tag >> 3) {
4137 // optional float r = 1;
4138 case 1:
4139 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 13)) {
4140 _Internal::set_has_r(&has_bits);
4141 _impl_.r_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
4142 ptr += sizeof(float);
4143 } else {
4144 goto handle_unusual;
4145 }
4146 continue;
4147 // optional float g = 2;
4148 case 2:
4149 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 21)) {
4150 _Internal::set_has_g(&has_bits);
4151 _impl_.g_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
4152 ptr += sizeof(float);
4153 } else {
4154 goto handle_unusual;
4155 }
4156 continue;
4157 // optional float b = 3;
4158 case 3:
4159 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 29)) {
4160 _Internal::set_has_b(&has_bits);
4161 _impl_.b_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
4162 ptr += sizeof(float);
4163 } else {
4164 goto handle_unusual;
4165 }
4166 continue;
4167 default:
4168 goto handle_unusual;
4169 } // switch
4170 handle_unusual:
4171 if ((tag == 0) || ((tag & 7) == 4)) {
4172 CHK_(ptr);
4173 ctx->SetLastTag(tag);
4174 goto message_done;
4175 }
4176 ptr = UnknownFieldParse(
4177 tag,
4178 _internal_metadata_.mutable_unknown_fields<std::string>(),
4179 ptr, ctx);
4180 CHK_(ptr != nullptr);
4181 } // while
4182 message_done:
4183 _impl_._has_bits_.Or(has_bits);
4184 return ptr;
4185 failure:
4186 ptr = nullptr;
4187 goto message_done;
4188 #undef CHK_
4189 }
4190
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const4191 ::uint8_t* LayerState_Color3::_InternalSerialize(
4192 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
4193 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.LayerState.Color3)
4194 ::uint32_t cached_has_bits = 0;
4195 (void) cached_has_bits;
4196
4197 cached_has_bits = _impl_._has_bits_[0];
4198 // optional float r = 1;
4199 if (cached_has_bits & 0x00000001u) {
4200 target = stream->EnsureSpace(target);
4201 target = ::_pbi::WireFormatLite::WriteFloatToArray(1, this->_internal_r(), target);
4202 }
4203
4204 // optional float g = 2;
4205 if (cached_has_bits & 0x00000002u) {
4206 target = stream->EnsureSpace(target);
4207 target = ::_pbi::WireFormatLite::WriteFloatToArray(2, this->_internal_g(), target);
4208 }
4209
4210 // optional float b = 3;
4211 if (cached_has_bits & 0x00000004u) {
4212 target = stream->EnsureSpace(target);
4213 target = ::_pbi::WireFormatLite::WriteFloatToArray(3, this->_internal_b(), target);
4214 }
4215
4216 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
4217 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
4218 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
4219 }
4220 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.LayerState.Color3)
4221 return target;
4222 }
4223
ByteSizeLong() const4224 size_t LayerState_Color3::ByteSizeLong() const {
4225 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.LayerState.Color3)
4226 size_t total_size = 0;
4227
4228 ::uint32_t cached_has_bits = 0;
4229 // Prevent compiler warnings about cached_has_bits being unused
4230 (void) cached_has_bits;
4231
4232 cached_has_bits = _impl_._has_bits_[0];
4233 if (cached_has_bits & 0x00000007u) {
4234 // optional float r = 1;
4235 if (cached_has_bits & 0x00000001u) {
4236 total_size += 1 + 4;
4237 }
4238
4239 // optional float g = 2;
4240 if (cached_has_bits & 0x00000002u) {
4241 total_size += 1 + 4;
4242 }
4243
4244 // optional float b = 3;
4245 if (cached_has_bits & 0x00000004u) {
4246 total_size += 1 + 4;
4247 }
4248
4249 }
4250 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
4251 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
4252 }
4253 int cached_size = ::_pbi::ToCachedSize(total_size);
4254 SetCachedSize(cached_size);
4255 return total_size;
4256 }
4257
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)4258 void LayerState_Color3::CheckTypeAndMergeFrom(
4259 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
4260 MergeFrom(*::_pbi::DownCast<const LayerState_Color3*>(
4261 &from));
4262 }
4263
MergeFrom(const LayerState_Color3 & from)4264 void LayerState_Color3::MergeFrom(const LayerState_Color3& from) {
4265 LayerState_Color3* const _this = this;
4266 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.LayerState.Color3)
4267 GOOGLE_DCHECK_NE(&from, _this);
4268 ::uint32_t cached_has_bits = 0;
4269 (void) cached_has_bits;
4270
4271 cached_has_bits = from._impl_._has_bits_[0];
4272 if (cached_has_bits & 0x00000007u) {
4273 if (cached_has_bits & 0x00000001u) {
4274 _this->_impl_.r_ = from._impl_.r_;
4275 }
4276 if (cached_has_bits & 0x00000002u) {
4277 _this->_impl_.g_ = from._impl_.g_;
4278 }
4279 if (cached_has_bits & 0x00000004u) {
4280 _this->_impl_.b_ = from._impl_.b_;
4281 }
4282 _this->_impl_._has_bits_[0] |= cached_has_bits;
4283 }
4284 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4285 }
4286
CopyFrom(const LayerState_Color3 & from)4287 void LayerState_Color3::CopyFrom(const LayerState_Color3& from) {
4288 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.LayerState.Color3)
4289 if (&from == this) return;
4290 Clear();
4291 MergeFrom(from);
4292 }
4293
IsInitialized() const4294 bool LayerState_Color3::IsInitialized() const {
4295 return true;
4296 }
4297
InternalSwap(LayerState_Color3 * other)4298 void LayerState_Color3::InternalSwap(LayerState_Color3* other) {
4299 using std::swap;
4300 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
4301 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
4302 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
4303 PROTOBUF_FIELD_OFFSET(LayerState_Color3, _impl_.b_)
4304 + sizeof(LayerState_Color3::_impl_.b_) // NOLINT
4305 - PROTOBUF_FIELD_OFFSET(LayerState_Color3, _impl_.r_)>(
4306 reinterpret_cast<char*>(&_impl_.r_),
4307 reinterpret_cast<char*>(&other->_impl_.r_));
4308 }
4309
GetTypeName() const4310 std::string LayerState_Color3::GetTypeName() const {
4311 return "perfetto.protos.LayerState.Color3";
4312 }
4313
4314
4315 // ===================================================================
4316
4317 class LayerState_BufferData::_Internal {
4318 public:
4319 using HasBits = decltype(std::declval<LayerState_BufferData>()._impl_._has_bits_);
set_has_buffer_id(HasBits * has_bits)4320 static void set_has_buffer_id(HasBits* has_bits) {
4321 (*has_bits)[0] |= 1u;
4322 }
set_has_width(HasBits * has_bits)4323 static void set_has_width(HasBits* has_bits) {
4324 (*has_bits)[0] |= 2u;
4325 }
set_has_height(HasBits * has_bits)4326 static void set_has_height(HasBits* has_bits) {
4327 (*has_bits)[0] |= 4u;
4328 }
set_has_frame_number(HasBits * has_bits)4329 static void set_has_frame_number(HasBits* has_bits) {
4330 (*has_bits)[0] |= 8u;
4331 }
set_has_flags(HasBits * has_bits)4332 static void set_has_flags(HasBits* has_bits) {
4333 (*has_bits)[0] |= 32u;
4334 }
set_has_cached_buffer_id(HasBits * has_bits)4335 static void set_has_cached_buffer_id(HasBits* has_bits) {
4336 (*has_bits)[0] |= 16u;
4337 }
set_has_pixel_format(HasBits * has_bits)4338 static void set_has_pixel_format(HasBits* has_bits) {
4339 (*has_bits)[0] |= 64u;
4340 }
set_has_usage(HasBits * has_bits)4341 static void set_has_usage(HasBits* has_bits) {
4342 (*has_bits)[0] |= 128u;
4343 }
4344 };
4345
LayerState_BufferData(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)4346 LayerState_BufferData::LayerState_BufferData(::PROTOBUF_NAMESPACE_ID::Arena* arena,
4347 bool is_message_owned)
4348 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
4349 SharedCtor(arena, is_message_owned);
4350 // @@protoc_insertion_point(arena_constructor:perfetto.protos.LayerState.BufferData)
4351 }
LayerState_BufferData(const LayerState_BufferData & from)4352 LayerState_BufferData::LayerState_BufferData(const LayerState_BufferData& from)
4353 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
4354 LayerState_BufferData* const _this = this; (void)_this;
4355 new (&_impl_) Impl_{
4356 decltype(_impl_._has_bits_){from._impl_._has_bits_}
4357 , /*decltype(_impl_._cached_size_)*/{}
4358 , decltype(_impl_.buffer_id_){}
4359 , decltype(_impl_.width_){}
4360 , decltype(_impl_.height_){}
4361 , decltype(_impl_.frame_number_){}
4362 , decltype(_impl_.cached_buffer_id_){}
4363 , decltype(_impl_.flags_){}
4364 , decltype(_impl_.pixel_format_){}
4365 , decltype(_impl_.usage_){}};
4366
4367 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4368 ::memcpy(&_impl_.buffer_id_, &from._impl_.buffer_id_,
4369 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.usage_) -
4370 reinterpret_cast<char*>(&_impl_.buffer_id_)) + sizeof(_impl_.usage_));
4371 // @@protoc_insertion_point(copy_constructor:perfetto.protos.LayerState.BufferData)
4372 }
4373
SharedCtor(::_pb::Arena * arena,bool is_message_owned)4374 inline void LayerState_BufferData::SharedCtor(
4375 ::_pb::Arena* arena, bool is_message_owned) {
4376 (void)arena;
4377 (void)is_message_owned;
4378 new (&_impl_) Impl_{
4379 decltype(_impl_._has_bits_){}
4380 , /*decltype(_impl_._cached_size_)*/{}
4381 , decltype(_impl_.buffer_id_){::uint64_t{0u}}
4382 , decltype(_impl_.width_){0u}
4383 , decltype(_impl_.height_){0u}
4384 , decltype(_impl_.frame_number_){::uint64_t{0u}}
4385 , decltype(_impl_.cached_buffer_id_){::uint64_t{0u}}
4386 , decltype(_impl_.flags_){0u}
4387 , decltype(_impl_.pixel_format_){0}
4388 , decltype(_impl_.usage_){::uint64_t{0u}}
4389 };
4390 }
4391
~LayerState_BufferData()4392 LayerState_BufferData::~LayerState_BufferData() {
4393 // @@protoc_insertion_point(destructor:perfetto.protos.LayerState.BufferData)
4394 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
4395 (void)arena;
4396 return;
4397 }
4398 SharedDtor();
4399 }
4400
SharedDtor()4401 inline void LayerState_BufferData::SharedDtor() {
4402 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
4403 }
4404
SetCachedSize(int size) const4405 void LayerState_BufferData::SetCachedSize(int size) const {
4406 _impl_._cached_size_.Set(size);
4407 }
4408
Clear()4409 void LayerState_BufferData::Clear() {
4410 // @@protoc_insertion_point(message_clear_start:perfetto.protos.LayerState.BufferData)
4411 ::uint32_t cached_has_bits = 0;
4412 // Prevent compiler warnings about cached_has_bits being unused
4413 (void) cached_has_bits;
4414
4415 cached_has_bits = _impl_._has_bits_[0];
4416 if (cached_has_bits & 0x000000ffu) {
4417 ::memset(&_impl_.buffer_id_, 0, static_cast<size_t>(
4418 reinterpret_cast<char*>(&_impl_.usage_) -
4419 reinterpret_cast<char*>(&_impl_.buffer_id_)) + sizeof(_impl_.usage_));
4420 }
4421 _impl_._has_bits_.Clear();
4422 _internal_metadata_.Clear<std::string>();
4423 }
4424
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)4425 const char* LayerState_BufferData::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
4426 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
4427 _Internal::HasBits has_bits{};
4428 while (!ctx->Done(&ptr)) {
4429 ::uint32_t tag;
4430 ptr = ::_pbi::ReadTag(ptr, &tag);
4431 switch (tag >> 3) {
4432 // optional uint64 buffer_id = 1;
4433 case 1:
4434 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
4435 _Internal::set_has_buffer_id(&has_bits);
4436 _impl_.buffer_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4437 CHK_(ptr);
4438 } else {
4439 goto handle_unusual;
4440 }
4441 continue;
4442 // optional uint32 width = 2;
4443 case 2:
4444 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
4445 _Internal::set_has_width(&has_bits);
4446 _impl_.width_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
4447 CHK_(ptr);
4448 } else {
4449 goto handle_unusual;
4450 }
4451 continue;
4452 // optional uint32 height = 3;
4453 case 3:
4454 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
4455 _Internal::set_has_height(&has_bits);
4456 _impl_.height_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
4457 CHK_(ptr);
4458 } else {
4459 goto handle_unusual;
4460 }
4461 continue;
4462 // optional uint64 frame_number = 4;
4463 case 4:
4464 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
4465 _Internal::set_has_frame_number(&has_bits);
4466 _impl_.frame_number_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4467 CHK_(ptr);
4468 } else {
4469 goto handle_unusual;
4470 }
4471 continue;
4472 // optional uint32 flags = 5;
4473 case 5:
4474 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
4475 _Internal::set_has_flags(&has_bits);
4476 _impl_.flags_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
4477 CHK_(ptr);
4478 } else {
4479 goto handle_unusual;
4480 }
4481 continue;
4482 // optional uint64 cached_buffer_id = 6;
4483 case 6:
4484 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
4485 _Internal::set_has_cached_buffer_id(&has_bits);
4486 _impl_.cached_buffer_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4487 CHK_(ptr);
4488 } else {
4489 goto handle_unusual;
4490 }
4491 continue;
4492 // optional .perfetto.protos.LayerState.BufferData.PixelFormat pixel_format = 7;
4493 case 7:
4494 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
4495 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4496 CHK_(ptr);
4497 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::LayerState_BufferData_PixelFormat_IsValid(val))) {
4498 _internal_set_pixel_format(static_cast<::perfetto::protos::LayerState_BufferData_PixelFormat>(val));
4499 } else {
4500 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(7, val, mutable_unknown_fields());
4501 }
4502 } else {
4503 goto handle_unusual;
4504 }
4505 continue;
4506 // optional uint64 usage = 8;
4507 case 8:
4508 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
4509 _Internal::set_has_usage(&has_bits);
4510 _impl_.usage_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4511 CHK_(ptr);
4512 } else {
4513 goto handle_unusual;
4514 }
4515 continue;
4516 default:
4517 goto handle_unusual;
4518 } // switch
4519 handle_unusual:
4520 if ((tag == 0) || ((tag & 7) == 4)) {
4521 CHK_(ptr);
4522 ctx->SetLastTag(tag);
4523 goto message_done;
4524 }
4525 ptr = UnknownFieldParse(
4526 tag,
4527 _internal_metadata_.mutable_unknown_fields<std::string>(),
4528 ptr, ctx);
4529 CHK_(ptr != nullptr);
4530 } // while
4531 message_done:
4532 _impl_._has_bits_.Or(has_bits);
4533 return ptr;
4534 failure:
4535 ptr = nullptr;
4536 goto message_done;
4537 #undef CHK_
4538 }
4539
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const4540 ::uint8_t* LayerState_BufferData::_InternalSerialize(
4541 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
4542 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.LayerState.BufferData)
4543 ::uint32_t cached_has_bits = 0;
4544 (void) cached_has_bits;
4545
4546 cached_has_bits = _impl_._has_bits_[0];
4547 // optional uint64 buffer_id = 1;
4548 if (cached_has_bits & 0x00000001u) {
4549 target = stream->EnsureSpace(target);
4550 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(1, this->_internal_buffer_id(), target);
4551 }
4552
4553 // optional uint32 width = 2;
4554 if (cached_has_bits & 0x00000002u) {
4555 target = stream->EnsureSpace(target);
4556 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(2, this->_internal_width(), target);
4557 }
4558
4559 // optional uint32 height = 3;
4560 if (cached_has_bits & 0x00000004u) {
4561 target = stream->EnsureSpace(target);
4562 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(3, this->_internal_height(), target);
4563 }
4564
4565 // optional uint64 frame_number = 4;
4566 if (cached_has_bits & 0x00000008u) {
4567 target = stream->EnsureSpace(target);
4568 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(4, this->_internal_frame_number(), target);
4569 }
4570
4571 // optional uint32 flags = 5;
4572 if (cached_has_bits & 0x00000020u) {
4573 target = stream->EnsureSpace(target);
4574 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(5, this->_internal_flags(), target);
4575 }
4576
4577 // optional uint64 cached_buffer_id = 6;
4578 if (cached_has_bits & 0x00000010u) {
4579 target = stream->EnsureSpace(target);
4580 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(6, this->_internal_cached_buffer_id(), target);
4581 }
4582
4583 // optional .perfetto.protos.LayerState.BufferData.PixelFormat pixel_format = 7;
4584 if (cached_has_bits & 0x00000040u) {
4585 target = stream->EnsureSpace(target);
4586 target = ::_pbi::WireFormatLite::WriteEnumToArray(
4587 7, this->_internal_pixel_format(), target);
4588 }
4589
4590 // optional uint64 usage = 8;
4591 if (cached_has_bits & 0x00000080u) {
4592 target = stream->EnsureSpace(target);
4593 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(8, this->_internal_usage(), target);
4594 }
4595
4596 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
4597 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
4598 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
4599 }
4600 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.LayerState.BufferData)
4601 return target;
4602 }
4603
ByteSizeLong() const4604 size_t LayerState_BufferData::ByteSizeLong() const {
4605 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.LayerState.BufferData)
4606 size_t total_size = 0;
4607
4608 ::uint32_t cached_has_bits = 0;
4609 // Prevent compiler warnings about cached_has_bits being unused
4610 (void) cached_has_bits;
4611
4612 cached_has_bits = _impl_._has_bits_[0];
4613 if (cached_has_bits & 0x000000ffu) {
4614 // optional uint64 buffer_id = 1;
4615 if (cached_has_bits & 0x00000001u) {
4616 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_buffer_id());
4617 }
4618
4619 // optional uint32 width = 2;
4620 if (cached_has_bits & 0x00000002u) {
4621 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_width());
4622 }
4623
4624 // optional uint32 height = 3;
4625 if (cached_has_bits & 0x00000004u) {
4626 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_height());
4627 }
4628
4629 // optional uint64 frame_number = 4;
4630 if (cached_has_bits & 0x00000008u) {
4631 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_frame_number());
4632 }
4633
4634 // optional uint64 cached_buffer_id = 6;
4635 if (cached_has_bits & 0x00000010u) {
4636 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_cached_buffer_id());
4637 }
4638
4639 // optional uint32 flags = 5;
4640 if (cached_has_bits & 0x00000020u) {
4641 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_flags());
4642 }
4643
4644 // optional .perfetto.protos.LayerState.BufferData.PixelFormat pixel_format = 7;
4645 if (cached_has_bits & 0x00000040u) {
4646 total_size += 1 +
4647 ::_pbi::WireFormatLite::EnumSize(this->_internal_pixel_format());
4648 }
4649
4650 // optional uint64 usage = 8;
4651 if (cached_has_bits & 0x00000080u) {
4652 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_usage());
4653 }
4654
4655 }
4656 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
4657 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
4658 }
4659 int cached_size = ::_pbi::ToCachedSize(total_size);
4660 SetCachedSize(cached_size);
4661 return total_size;
4662 }
4663
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)4664 void LayerState_BufferData::CheckTypeAndMergeFrom(
4665 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
4666 MergeFrom(*::_pbi::DownCast<const LayerState_BufferData*>(
4667 &from));
4668 }
4669
MergeFrom(const LayerState_BufferData & from)4670 void LayerState_BufferData::MergeFrom(const LayerState_BufferData& from) {
4671 LayerState_BufferData* const _this = this;
4672 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.LayerState.BufferData)
4673 GOOGLE_DCHECK_NE(&from, _this);
4674 ::uint32_t cached_has_bits = 0;
4675 (void) cached_has_bits;
4676
4677 cached_has_bits = from._impl_._has_bits_[0];
4678 if (cached_has_bits & 0x000000ffu) {
4679 if (cached_has_bits & 0x00000001u) {
4680 _this->_impl_.buffer_id_ = from._impl_.buffer_id_;
4681 }
4682 if (cached_has_bits & 0x00000002u) {
4683 _this->_impl_.width_ = from._impl_.width_;
4684 }
4685 if (cached_has_bits & 0x00000004u) {
4686 _this->_impl_.height_ = from._impl_.height_;
4687 }
4688 if (cached_has_bits & 0x00000008u) {
4689 _this->_impl_.frame_number_ = from._impl_.frame_number_;
4690 }
4691 if (cached_has_bits & 0x00000010u) {
4692 _this->_impl_.cached_buffer_id_ = from._impl_.cached_buffer_id_;
4693 }
4694 if (cached_has_bits & 0x00000020u) {
4695 _this->_impl_.flags_ = from._impl_.flags_;
4696 }
4697 if (cached_has_bits & 0x00000040u) {
4698 _this->_impl_.pixel_format_ = from._impl_.pixel_format_;
4699 }
4700 if (cached_has_bits & 0x00000080u) {
4701 _this->_impl_.usage_ = from._impl_.usage_;
4702 }
4703 _this->_impl_._has_bits_[0] |= cached_has_bits;
4704 }
4705 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4706 }
4707
CopyFrom(const LayerState_BufferData & from)4708 void LayerState_BufferData::CopyFrom(const LayerState_BufferData& from) {
4709 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.LayerState.BufferData)
4710 if (&from == this) return;
4711 Clear();
4712 MergeFrom(from);
4713 }
4714
IsInitialized() const4715 bool LayerState_BufferData::IsInitialized() const {
4716 return true;
4717 }
4718
InternalSwap(LayerState_BufferData * other)4719 void LayerState_BufferData::InternalSwap(LayerState_BufferData* other) {
4720 using std::swap;
4721 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
4722 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
4723 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
4724 PROTOBUF_FIELD_OFFSET(LayerState_BufferData, _impl_.usage_)
4725 + sizeof(LayerState_BufferData::_impl_.usage_) // NOLINT
4726 - PROTOBUF_FIELD_OFFSET(LayerState_BufferData, _impl_.buffer_id_)>(
4727 reinterpret_cast<char*>(&_impl_.buffer_id_),
4728 reinterpret_cast<char*>(&other->_impl_.buffer_id_));
4729 }
4730
GetTypeName() const4731 std::string LayerState_BufferData::GetTypeName() const {
4732 return "perfetto.protos.LayerState.BufferData";
4733 }
4734
4735
4736 // ===================================================================
4737
4738 class LayerState_WindowInfo::_Internal {
4739 public:
4740 using HasBits = decltype(std::declval<LayerState_WindowInfo>()._impl_._has_bits_);
set_has_layout_params_flags(HasBits * has_bits)4741 static void set_has_layout_params_flags(HasBits* has_bits) {
4742 (*has_bits)[0] |= 8u;
4743 }
set_has_layout_params_type(HasBits * has_bits)4744 static void set_has_layout_params_type(HasBits* has_bits) {
4745 (*has_bits)[0] |= 16u;
4746 }
4747 static const ::perfetto::protos::RegionProto& touchable_region(const LayerState_WindowInfo* msg);
set_has_touchable_region(HasBits * has_bits)4748 static void set_has_touchable_region(HasBits* has_bits) {
4749 (*has_bits)[0] |= 1u;
4750 }
set_has_surface_inset(HasBits * has_bits)4751 static void set_has_surface_inset(HasBits* has_bits) {
4752 (*has_bits)[0] |= 32u;
4753 }
set_has_focusable(HasBits * has_bits)4754 static void set_has_focusable(HasBits* has_bits) {
4755 (*has_bits)[0] |= 64u;
4756 }
set_has_has_wallpaper(HasBits * has_bits)4757 static void set_has_has_wallpaper(HasBits* has_bits) {
4758 (*has_bits)[0] |= 128u;
4759 }
set_has_global_scale_factor(HasBits * has_bits)4760 static void set_has_global_scale_factor(HasBits* has_bits) {
4761 (*has_bits)[0] |= 512u;
4762 }
set_has_crop_layer_id(HasBits * has_bits)4763 static void set_has_crop_layer_id(HasBits* has_bits) {
4764 (*has_bits)[0] |= 1024u;
4765 }
set_has_replace_touchable_region_with_crop(HasBits * has_bits)4766 static void set_has_replace_touchable_region_with_crop(HasBits* has_bits) {
4767 (*has_bits)[0] |= 256u;
4768 }
4769 static const ::perfetto::protos::RectProto& touchable_region_crop(const LayerState_WindowInfo* msg);
set_has_touchable_region_crop(HasBits * has_bits)4770 static void set_has_touchable_region_crop(HasBits* has_bits) {
4771 (*has_bits)[0] |= 2u;
4772 }
4773 static const ::perfetto::protos::Transform& transform(const LayerState_WindowInfo* msg);
set_has_transform(HasBits * has_bits)4774 static void set_has_transform(HasBits* has_bits) {
4775 (*has_bits)[0] |= 4u;
4776 }
set_has_input_config(HasBits * has_bits)4777 static void set_has_input_config(HasBits* has_bits) {
4778 (*has_bits)[0] |= 2048u;
4779 }
4780 };
4781
4782 const ::perfetto::protos::RegionProto&
touchable_region(const LayerState_WindowInfo * msg)4783 LayerState_WindowInfo::_Internal::touchable_region(const LayerState_WindowInfo* msg) {
4784 return *msg->_impl_.touchable_region_;
4785 }
4786 const ::perfetto::protos::RectProto&
touchable_region_crop(const LayerState_WindowInfo * msg)4787 LayerState_WindowInfo::_Internal::touchable_region_crop(const LayerState_WindowInfo* msg) {
4788 return *msg->_impl_.touchable_region_crop_;
4789 }
4790 const ::perfetto::protos::Transform&
transform(const LayerState_WindowInfo * msg)4791 LayerState_WindowInfo::_Internal::transform(const LayerState_WindowInfo* msg) {
4792 return *msg->_impl_.transform_;
4793 }
clear_touchable_region()4794 void LayerState_WindowInfo::clear_touchable_region() {
4795 if (_impl_.touchable_region_ != nullptr) _impl_.touchable_region_->Clear();
4796 _impl_._has_bits_[0] &= ~0x00000001u;
4797 }
clear_touchable_region_crop()4798 void LayerState_WindowInfo::clear_touchable_region_crop() {
4799 if (_impl_.touchable_region_crop_ != nullptr) _impl_.touchable_region_crop_->Clear();
4800 _impl_._has_bits_[0] &= ~0x00000002u;
4801 }
LayerState_WindowInfo(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)4802 LayerState_WindowInfo::LayerState_WindowInfo(::PROTOBUF_NAMESPACE_ID::Arena* arena,
4803 bool is_message_owned)
4804 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
4805 SharedCtor(arena, is_message_owned);
4806 // @@protoc_insertion_point(arena_constructor:perfetto.protos.LayerState.WindowInfo)
4807 }
LayerState_WindowInfo(const LayerState_WindowInfo & from)4808 LayerState_WindowInfo::LayerState_WindowInfo(const LayerState_WindowInfo& from)
4809 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
4810 LayerState_WindowInfo* const _this = this; (void)_this;
4811 new (&_impl_) Impl_{
4812 decltype(_impl_._has_bits_){from._impl_._has_bits_}
4813 , /*decltype(_impl_._cached_size_)*/{}
4814 , decltype(_impl_.touchable_region_){nullptr}
4815 , decltype(_impl_.touchable_region_crop_){nullptr}
4816 , decltype(_impl_.transform_){nullptr}
4817 , decltype(_impl_.layout_params_flags_){}
4818 , decltype(_impl_.layout_params_type_){}
4819 , decltype(_impl_.surface_inset_){}
4820 , decltype(_impl_.focusable_){}
4821 , decltype(_impl_.has_wallpaper_){}
4822 , decltype(_impl_.replace_touchable_region_with_crop_){}
4823 , decltype(_impl_.global_scale_factor_){}
4824 , decltype(_impl_.crop_layer_id_){}
4825 , decltype(_impl_.input_config_){}};
4826
4827 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
4828 if (from._internal_has_touchable_region()) {
4829 _this->_impl_.touchable_region_ = new ::perfetto::protos::RegionProto(*from._impl_.touchable_region_);
4830 }
4831 if (from._internal_has_touchable_region_crop()) {
4832 _this->_impl_.touchable_region_crop_ = new ::perfetto::protos::RectProto(*from._impl_.touchable_region_crop_);
4833 }
4834 if (from._internal_has_transform()) {
4835 _this->_impl_.transform_ = new ::perfetto::protos::Transform(*from._impl_.transform_);
4836 }
4837 ::memcpy(&_impl_.layout_params_flags_, &from._impl_.layout_params_flags_,
4838 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.input_config_) -
4839 reinterpret_cast<char*>(&_impl_.layout_params_flags_)) + sizeof(_impl_.input_config_));
4840 // @@protoc_insertion_point(copy_constructor:perfetto.protos.LayerState.WindowInfo)
4841 }
4842
SharedCtor(::_pb::Arena * arena,bool is_message_owned)4843 inline void LayerState_WindowInfo::SharedCtor(
4844 ::_pb::Arena* arena, bool is_message_owned) {
4845 (void)arena;
4846 (void)is_message_owned;
4847 new (&_impl_) Impl_{
4848 decltype(_impl_._has_bits_){}
4849 , /*decltype(_impl_._cached_size_)*/{}
4850 , decltype(_impl_.touchable_region_){nullptr}
4851 , decltype(_impl_.touchable_region_crop_){nullptr}
4852 , decltype(_impl_.transform_){nullptr}
4853 , decltype(_impl_.layout_params_flags_){0u}
4854 , decltype(_impl_.layout_params_type_){0}
4855 , decltype(_impl_.surface_inset_){0}
4856 , decltype(_impl_.focusable_){false}
4857 , decltype(_impl_.has_wallpaper_){false}
4858 , decltype(_impl_.replace_touchable_region_with_crop_){false}
4859 , decltype(_impl_.global_scale_factor_){0}
4860 , decltype(_impl_.crop_layer_id_){0u}
4861 , decltype(_impl_.input_config_){0u}
4862 };
4863 }
4864
~LayerState_WindowInfo()4865 LayerState_WindowInfo::~LayerState_WindowInfo() {
4866 // @@protoc_insertion_point(destructor:perfetto.protos.LayerState.WindowInfo)
4867 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
4868 (void)arena;
4869 return;
4870 }
4871 SharedDtor();
4872 }
4873
SharedDtor()4874 inline void LayerState_WindowInfo::SharedDtor() {
4875 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
4876 if (this != internal_default_instance()) delete _impl_.touchable_region_;
4877 if (this != internal_default_instance()) delete _impl_.touchable_region_crop_;
4878 if (this != internal_default_instance()) delete _impl_.transform_;
4879 }
4880
SetCachedSize(int size) const4881 void LayerState_WindowInfo::SetCachedSize(int size) const {
4882 _impl_._cached_size_.Set(size);
4883 }
4884
Clear()4885 void LayerState_WindowInfo::Clear() {
4886 // @@protoc_insertion_point(message_clear_start:perfetto.protos.LayerState.WindowInfo)
4887 ::uint32_t cached_has_bits = 0;
4888 // Prevent compiler warnings about cached_has_bits being unused
4889 (void) cached_has_bits;
4890
4891 cached_has_bits = _impl_._has_bits_[0];
4892 if (cached_has_bits & 0x00000007u) {
4893 if (cached_has_bits & 0x00000001u) {
4894 GOOGLE_DCHECK(_impl_.touchable_region_ != nullptr);
4895 _impl_.touchable_region_->Clear();
4896 }
4897 if (cached_has_bits & 0x00000002u) {
4898 GOOGLE_DCHECK(_impl_.touchable_region_crop_ != nullptr);
4899 _impl_.touchable_region_crop_->Clear();
4900 }
4901 if (cached_has_bits & 0x00000004u) {
4902 GOOGLE_DCHECK(_impl_.transform_ != nullptr);
4903 _impl_.transform_->Clear();
4904 }
4905 }
4906 if (cached_has_bits & 0x000000f8u) {
4907 ::memset(&_impl_.layout_params_flags_, 0, static_cast<size_t>(
4908 reinterpret_cast<char*>(&_impl_.has_wallpaper_) -
4909 reinterpret_cast<char*>(&_impl_.layout_params_flags_)) + sizeof(_impl_.has_wallpaper_));
4910 }
4911 if (cached_has_bits & 0x00000f00u) {
4912 ::memset(&_impl_.replace_touchable_region_with_crop_, 0, static_cast<size_t>(
4913 reinterpret_cast<char*>(&_impl_.input_config_) -
4914 reinterpret_cast<char*>(&_impl_.replace_touchable_region_with_crop_)) + sizeof(_impl_.input_config_));
4915 }
4916 _impl_._has_bits_.Clear();
4917 _internal_metadata_.Clear<std::string>();
4918 }
4919
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)4920 const char* LayerState_WindowInfo::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
4921 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
4922 _Internal::HasBits has_bits{};
4923 while (!ctx->Done(&ptr)) {
4924 ::uint32_t tag;
4925 ptr = ::_pbi::ReadTag(ptr, &tag);
4926 switch (tag >> 3) {
4927 // optional uint32 layout_params_flags = 1;
4928 case 1:
4929 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
4930 _Internal::set_has_layout_params_flags(&has_bits);
4931 _impl_.layout_params_flags_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
4932 CHK_(ptr);
4933 } else {
4934 goto handle_unusual;
4935 }
4936 continue;
4937 // optional int32 layout_params_type = 2;
4938 case 2:
4939 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
4940 _Internal::set_has_layout_params_type(&has_bits);
4941 _impl_.layout_params_type_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
4942 CHK_(ptr);
4943 } else {
4944 goto handle_unusual;
4945 }
4946 continue;
4947 // optional .perfetto.protos.RegionProto touchable_region = 3;
4948 case 3:
4949 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 26)) {
4950 ptr = ctx->ParseMessage(_internal_mutable_touchable_region(), ptr);
4951 CHK_(ptr);
4952 } else {
4953 goto handle_unusual;
4954 }
4955 continue;
4956 // optional int32 surface_inset = 4;
4957 case 4:
4958 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
4959 _Internal::set_has_surface_inset(&has_bits);
4960 _impl_.surface_inset_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
4961 CHK_(ptr);
4962 } else {
4963 goto handle_unusual;
4964 }
4965 continue;
4966 // optional bool focusable = 5;
4967 case 5:
4968 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
4969 _Internal::set_has_focusable(&has_bits);
4970 _impl_.focusable_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4971 CHK_(ptr);
4972 } else {
4973 goto handle_unusual;
4974 }
4975 continue;
4976 // optional bool has_wallpaper = 6;
4977 case 6:
4978 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
4979 _Internal::set_has_has_wallpaper(&has_bits);
4980 _impl_.has_wallpaper_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
4981 CHK_(ptr);
4982 } else {
4983 goto handle_unusual;
4984 }
4985 continue;
4986 // optional float global_scale_factor = 7;
4987 case 7:
4988 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 61)) {
4989 _Internal::set_has_global_scale_factor(&has_bits);
4990 _impl_.global_scale_factor_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
4991 ptr += sizeof(float);
4992 } else {
4993 goto handle_unusual;
4994 }
4995 continue;
4996 // optional uint32 crop_layer_id = 8;
4997 case 8:
4998 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
4999 _Internal::set_has_crop_layer_id(&has_bits);
5000 _impl_.crop_layer_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5001 CHK_(ptr);
5002 } else {
5003 goto handle_unusual;
5004 }
5005 continue;
5006 // optional bool replace_touchable_region_with_crop = 9;
5007 case 9:
5008 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
5009 _Internal::set_has_replace_touchable_region_with_crop(&has_bits);
5010 _impl_.replace_touchable_region_with_crop_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
5011 CHK_(ptr);
5012 } else {
5013 goto handle_unusual;
5014 }
5015 continue;
5016 // optional .perfetto.protos.RectProto touchable_region_crop = 10;
5017 case 10:
5018 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 82)) {
5019 ptr = ctx->ParseMessage(_internal_mutable_touchable_region_crop(), ptr);
5020 CHK_(ptr);
5021 } else {
5022 goto handle_unusual;
5023 }
5024 continue;
5025 // optional .perfetto.protos.Transform transform = 11;
5026 case 11:
5027 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 90)) {
5028 ptr = ctx->ParseMessage(_internal_mutable_transform(), ptr);
5029 CHK_(ptr);
5030 } else {
5031 goto handle_unusual;
5032 }
5033 continue;
5034 // optional uint32 input_config = 12;
5035 case 12:
5036 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 96)) {
5037 _Internal::set_has_input_config(&has_bits);
5038 _impl_.input_config_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5039 CHK_(ptr);
5040 } else {
5041 goto handle_unusual;
5042 }
5043 continue;
5044 default:
5045 goto handle_unusual;
5046 } // switch
5047 handle_unusual:
5048 if ((tag == 0) || ((tag & 7) == 4)) {
5049 CHK_(ptr);
5050 ctx->SetLastTag(tag);
5051 goto message_done;
5052 }
5053 ptr = UnknownFieldParse(
5054 tag,
5055 _internal_metadata_.mutable_unknown_fields<std::string>(),
5056 ptr, ctx);
5057 CHK_(ptr != nullptr);
5058 } // while
5059 message_done:
5060 _impl_._has_bits_.Or(has_bits);
5061 return ptr;
5062 failure:
5063 ptr = nullptr;
5064 goto message_done;
5065 #undef CHK_
5066 }
5067
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const5068 ::uint8_t* LayerState_WindowInfo::_InternalSerialize(
5069 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
5070 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.LayerState.WindowInfo)
5071 ::uint32_t cached_has_bits = 0;
5072 (void) cached_has_bits;
5073
5074 cached_has_bits = _impl_._has_bits_[0];
5075 // optional uint32 layout_params_flags = 1;
5076 if (cached_has_bits & 0x00000008u) {
5077 target = stream->EnsureSpace(target);
5078 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(1, this->_internal_layout_params_flags(), target);
5079 }
5080
5081 // optional int32 layout_params_type = 2;
5082 if (cached_has_bits & 0x00000010u) {
5083 target = stream->EnsureSpace(target);
5084 target = ::_pbi::WireFormatLite::WriteInt32ToArray(2, this->_internal_layout_params_type(), target);
5085 }
5086
5087 // optional .perfetto.protos.RegionProto touchable_region = 3;
5088 if (cached_has_bits & 0x00000001u) {
5089 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
5090 InternalWriteMessage(3, _Internal::touchable_region(this),
5091 _Internal::touchable_region(this).GetCachedSize(), target, stream);
5092 }
5093
5094 // optional int32 surface_inset = 4;
5095 if (cached_has_bits & 0x00000020u) {
5096 target = stream->EnsureSpace(target);
5097 target = ::_pbi::WireFormatLite::WriteInt32ToArray(4, this->_internal_surface_inset(), target);
5098 }
5099
5100 // optional bool focusable = 5;
5101 if (cached_has_bits & 0x00000040u) {
5102 target = stream->EnsureSpace(target);
5103 target = ::_pbi::WireFormatLite::WriteBoolToArray(5, this->_internal_focusable(), target);
5104 }
5105
5106 // optional bool has_wallpaper = 6;
5107 if (cached_has_bits & 0x00000080u) {
5108 target = stream->EnsureSpace(target);
5109 target = ::_pbi::WireFormatLite::WriteBoolToArray(6, this->_internal_has_wallpaper(), target);
5110 }
5111
5112 // optional float global_scale_factor = 7;
5113 if (cached_has_bits & 0x00000200u) {
5114 target = stream->EnsureSpace(target);
5115 target = ::_pbi::WireFormatLite::WriteFloatToArray(7, this->_internal_global_scale_factor(), target);
5116 }
5117
5118 // optional uint32 crop_layer_id = 8;
5119 if (cached_has_bits & 0x00000400u) {
5120 target = stream->EnsureSpace(target);
5121 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(8, this->_internal_crop_layer_id(), target);
5122 }
5123
5124 // optional bool replace_touchable_region_with_crop = 9;
5125 if (cached_has_bits & 0x00000100u) {
5126 target = stream->EnsureSpace(target);
5127 target = ::_pbi::WireFormatLite::WriteBoolToArray(9, this->_internal_replace_touchable_region_with_crop(), target);
5128 }
5129
5130 // optional .perfetto.protos.RectProto touchable_region_crop = 10;
5131 if (cached_has_bits & 0x00000002u) {
5132 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
5133 InternalWriteMessage(10, _Internal::touchable_region_crop(this),
5134 _Internal::touchable_region_crop(this).GetCachedSize(), target, stream);
5135 }
5136
5137 // optional .perfetto.protos.Transform transform = 11;
5138 if (cached_has_bits & 0x00000004u) {
5139 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
5140 InternalWriteMessage(11, _Internal::transform(this),
5141 _Internal::transform(this).GetCachedSize(), target, stream);
5142 }
5143
5144 // optional uint32 input_config = 12;
5145 if (cached_has_bits & 0x00000800u) {
5146 target = stream->EnsureSpace(target);
5147 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(12, this->_internal_input_config(), target);
5148 }
5149
5150 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
5151 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
5152 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
5153 }
5154 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.LayerState.WindowInfo)
5155 return target;
5156 }
5157
ByteSizeLong() const5158 size_t LayerState_WindowInfo::ByteSizeLong() const {
5159 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.LayerState.WindowInfo)
5160 size_t total_size = 0;
5161
5162 ::uint32_t cached_has_bits = 0;
5163 // Prevent compiler warnings about cached_has_bits being unused
5164 (void) cached_has_bits;
5165
5166 cached_has_bits = _impl_._has_bits_[0];
5167 if (cached_has_bits & 0x000000ffu) {
5168 // optional .perfetto.protos.RegionProto touchable_region = 3;
5169 if (cached_has_bits & 0x00000001u) {
5170 total_size += 1 +
5171 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
5172 *_impl_.touchable_region_);
5173 }
5174
5175 // optional .perfetto.protos.RectProto touchable_region_crop = 10;
5176 if (cached_has_bits & 0x00000002u) {
5177 total_size += 1 +
5178 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
5179 *_impl_.touchable_region_crop_);
5180 }
5181
5182 // optional .perfetto.protos.Transform transform = 11;
5183 if (cached_has_bits & 0x00000004u) {
5184 total_size += 1 +
5185 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
5186 *_impl_.transform_);
5187 }
5188
5189 // optional uint32 layout_params_flags = 1;
5190 if (cached_has_bits & 0x00000008u) {
5191 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_layout_params_flags());
5192 }
5193
5194 // optional int32 layout_params_type = 2;
5195 if (cached_has_bits & 0x00000010u) {
5196 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_layout_params_type());
5197 }
5198
5199 // optional int32 surface_inset = 4;
5200 if (cached_has_bits & 0x00000020u) {
5201 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_surface_inset());
5202 }
5203
5204 // optional bool focusable = 5;
5205 if (cached_has_bits & 0x00000040u) {
5206 total_size += 1 + 1;
5207 }
5208
5209 // optional bool has_wallpaper = 6;
5210 if (cached_has_bits & 0x00000080u) {
5211 total_size += 1 + 1;
5212 }
5213
5214 }
5215 if (cached_has_bits & 0x00000f00u) {
5216 // optional bool replace_touchable_region_with_crop = 9;
5217 if (cached_has_bits & 0x00000100u) {
5218 total_size += 1 + 1;
5219 }
5220
5221 // optional float global_scale_factor = 7;
5222 if (cached_has_bits & 0x00000200u) {
5223 total_size += 1 + 4;
5224 }
5225
5226 // optional uint32 crop_layer_id = 8;
5227 if (cached_has_bits & 0x00000400u) {
5228 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_crop_layer_id());
5229 }
5230
5231 // optional uint32 input_config = 12;
5232 if (cached_has_bits & 0x00000800u) {
5233 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_input_config());
5234 }
5235
5236 }
5237 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
5238 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
5239 }
5240 int cached_size = ::_pbi::ToCachedSize(total_size);
5241 SetCachedSize(cached_size);
5242 return total_size;
5243 }
5244
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)5245 void LayerState_WindowInfo::CheckTypeAndMergeFrom(
5246 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
5247 MergeFrom(*::_pbi::DownCast<const LayerState_WindowInfo*>(
5248 &from));
5249 }
5250
MergeFrom(const LayerState_WindowInfo & from)5251 void LayerState_WindowInfo::MergeFrom(const LayerState_WindowInfo& from) {
5252 LayerState_WindowInfo* const _this = this;
5253 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.LayerState.WindowInfo)
5254 GOOGLE_DCHECK_NE(&from, _this);
5255 ::uint32_t cached_has_bits = 0;
5256 (void) cached_has_bits;
5257
5258 cached_has_bits = from._impl_._has_bits_[0];
5259 if (cached_has_bits & 0x000000ffu) {
5260 if (cached_has_bits & 0x00000001u) {
5261 _this->_internal_mutable_touchable_region()->::perfetto::protos::RegionProto::MergeFrom(
5262 from._internal_touchable_region());
5263 }
5264 if (cached_has_bits & 0x00000002u) {
5265 _this->_internal_mutable_touchable_region_crop()->::perfetto::protos::RectProto::MergeFrom(
5266 from._internal_touchable_region_crop());
5267 }
5268 if (cached_has_bits & 0x00000004u) {
5269 _this->_internal_mutable_transform()->::perfetto::protos::Transform::MergeFrom(
5270 from._internal_transform());
5271 }
5272 if (cached_has_bits & 0x00000008u) {
5273 _this->_impl_.layout_params_flags_ = from._impl_.layout_params_flags_;
5274 }
5275 if (cached_has_bits & 0x00000010u) {
5276 _this->_impl_.layout_params_type_ = from._impl_.layout_params_type_;
5277 }
5278 if (cached_has_bits & 0x00000020u) {
5279 _this->_impl_.surface_inset_ = from._impl_.surface_inset_;
5280 }
5281 if (cached_has_bits & 0x00000040u) {
5282 _this->_impl_.focusable_ = from._impl_.focusable_;
5283 }
5284 if (cached_has_bits & 0x00000080u) {
5285 _this->_impl_.has_wallpaper_ = from._impl_.has_wallpaper_;
5286 }
5287 _this->_impl_._has_bits_[0] |= cached_has_bits;
5288 }
5289 if (cached_has_bits & 0x00000f00u) {
5290 if (cached_has_bits & 0x00000100u) {
5291 _this->_impl_.replace_touchable_region_with_crop_ = from._impl_.replace_touchable_region_with_crop_;
5292 }
5293 if (cached_has_bits & 0x00000200u) {
5294 _this->_impl_.global_scale_factor_ = from._impl_.global_scale_factor_;
5295 }
5296 if (cached_has_bits & 0x00000400u) {
5297 _this->_impl_.crop_layer_id_ = from._impl_.crop_layer_id_;
5298 }
5299 if (cached_has_bits & 0x00000800u) {
5300 _this->_impl_.input_config_ = from._impl_.input_config_;
5301 }
5302 _this->_impl_._has_bits_[0] |= cached_has_bits;
5303 }
5304 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
5305 }
5306
CopyFrom(const LayerState_WindowInfo & from)5307 void LayerState_WindowInfo::CopyFrom(const LayerState_WindowInfo& from) {
5308 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.LayerState.WindowInfo)
5309 if (&from == this) return;
5310 Clear();
5311 MergeFrom(from);
5312 }
5313
IsInitialized() const5314 bool LayerState_WindowInfo::IsInitialized() const {
5315 return true;
5316 }
5317
InternalSwap(LayerState_WindowInfo * other)5318 void LayerState_WindowInfo::InternalSwap(LayerState_WindowInfo* other) {
5319 using std::swap;
5320 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
5321 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
5322 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
5323 PROTOBUF_FIELD_OFFSET(LayerState_WindowInfo, _impl_.input_config_)
5324 + sizeof(LayerState_WindowInfo::_impl_.input_config_) // NOLINT
5325 - PROTOBUF_FIELD_OFFSET(LayerState_WindowInfo, _impl_.touchable_region_)>(
5326 reinterpret_cast<char*>(&_impl_.touchable_region_),
5327 reinterpret_cast<char*>(&other->_impl_.touchable_region_));
5328 }
5329
GetTypeName() const5330 std::string LayerState_WindowInfo::GetTypeName() const {
5331 return "perfetto.protos.LayerState.WindowInfo";
5332 }
5333
5334
5335 // ===================================================================
5336
5337 class LayerState::_Internal {
5338 public:
5339 using HasBits = decltype(std::declval<LayerState>()._impl_._has_bits_);
set_has_layer_id(HasBits * has_bits)5340 static void set_has_layer_id(HasBits* has_bits) {
5341 (*has_bits)[0] |= 1024u;
5342 }
set_has_what(HasBits * has_bits)5343 static void set_has_what(HasBits* has_bits) {
5344 (*has_bits)[0] |= 512u;
5345 }
set_has_x(HasBits * has_bits)5346 static void set_has_x(HasBits* has_bits) {
5347 (*has_bits)[0] |= 2048u;
5348 }
set_has_y(HasBits * has_bits)5349 static void set_has_y(HasBits* has_bits) {
5350 (*has_bits)[0] |= 4096u;
5351 }
set_has_z(HasBits * has_bits)5352 static void set_has_z(HasBits* has_bits) {
5353 (*has_bits)[0] |= 8192u;
5354 }
set_has_w(HasBits * has_bits)5355 static void set_has_w(HasBits* has_bits) {
5356 (*has_bits)[0] |= 16384u;
5357 }
set_has_h(HasBits * has_bits)5358 static void set_has_h(HasBits* has_bits) {
5359 (*has_bits)[0] |= 32768u;
5360 }
set_has_layer_stack(HasBits * has_bits)5361 static void set_has_layer_stack(HasBits* has_bits) {
5362 (*has_bits)[0] |= 65536u;
5363 }
set_has_flags(HasBits * has_bits)5364 static void set_has_flags(HasBits* has_bits) {
5365 (*has_bits)[0] |= 131072u;
5366 }
set_has_mask(HasBits * has_bits)5367 static void set_has_mask(HasBits* has_bits) {
5368 (*has_bits)[0] |= 262144u;
5369 }
5370 static const ::perfetto::protos::LayerState_Matrix22& matrix(const LayerState* msg);
set_has_matrix(HasBits * has_bits)5371 static void set_has_matrix(HasBits* has_bits) {
5372 (*has_bits)[0] |= 1u;
5373 }
set_has_corner_radius(HasBits * has_bits)5374 static void set_has_corner_radius(HasBits* has_bits) {
5375 (*has_bits)[0] |= 524288u;
5376 }
set_has_background_blur_radius(HasBits * has_bits)5377 static void set_has_background_blur_radius(HasBits* has_bits) {
5378 (*has_bits)[0] |= 1048576u;
5379 }
set_has_parent_id(HasBits * has_bits)5380 static void set_has_parent_id(HasBits* has_bits) {
5381 (*has_bits)[0] |= 2097152u;
5382 }
set_has_relative_parent_id(HasBits * has_bits)5383 static void set_has_relative_parent_id(HasBits* has_bits) {
5384 (*has_bits)[0] |= 4194304u;
5385 }
set_has_alpha(HasBits * has_bits)5386 static void set_has_alpha(HasBits* has_bits) {
5387 (*has_bits)[0] |= 8388608u;
5388 }
5389 static const ::perfetto::protos::LayerState_Color3& color(const LayerState* msg);
set_has_color(HasBits * has_bits)5390 static void set_has_color(HasBits* has_bits) {
5391 (*has_bits)[0] |= 2u;
5392 }
5393 static const ::perfetto::protos::RegionProto& transparent_region(const LayerState* msg);
set_has_transparent_region(HasBits * has_bits)5394 static void set_has_transparent_region(HasBits* has_bits) {
5395 (*has_bits)[0] |= 4u;
5396 }
set_has_transform(HasBits * has_bits)5397 static void set_has_transform(HasBits* has_bits) {
5398 (*has_bits)[0] |= 16777216u;
5399 }
set_has_transform_to_display_inverse(HasBits * has_bits)5400 static void set_has_transform_to_display_inverse(HasBits* has_bits) {
5401 (*has_bits)[0] |= 134217728u;
5402 }
5403 static const ::perfetto::protos::RectProto& crop(const LayerState* msg);
set_has_crop(HasBits * has_bits)5404 static void set_has_crop(HasBits* has_bits) {
5405 (*has_bits)[0] |= 8u;
5406 }
5407 static const ::perfetto::protos::LayerState_BufferData& buffer_data(const LayerState* msg);
set_has_buffer_data(HasBits * has_bits)5408 static void set_has_buffer_data(HasBits* has_bits) {
5409 (*has_bits)[0] |= 16u;
5410 }
set_has_api(HasBits * has_bits)5411 static void set_has_api(HasBits* has_bits) {
5412 (*has_bits)[0] |= 33554432u;
5413 }
set_has_has_sideband_stream(HasBits * has_bits)5414 static void set_has_has_sideband_stream(HasBits* has_bits) {
5415 (*has_bits)[0] |= 268435456u;
5416 }
5417 static const ::perfetto::protos::ColorTransformProto& color_transform(const LayerState* msg);
set_has_color_transform(HasBits * has_bits)5418 static void set_has_color_transform(HasBits* has_bits) {
5419 (*has_bits)[0] |= 32u;
5420 }
5421 static const ::perfetto::protos::LayerState_WindowInfo& window_info_handle(const LayerState* msg);
set_has_window_info_handle(HasBits * has_bits)5422 static void set_has_window_info_handle(HasBits* has_bits) {
5423 (*has_bits)[0] |= 64u;
5424 }
set_has_bg_color_alpha(HasBits * has_bits)5425 static void set_has_bg_color_alpha(HasBits* has_bits) {
5426 (*has_bits)[0] |= 67108864u;
5427 }
set_has_bg_color_dataspace(HasBits * has_bits)5428 static void set_has_bg_color_dataspace(HasBits* has_bits) {
5429 (*has_bits)[0] |= 2147483648u;
5430 }
set_has_color_space_agnostic(HasBits * has_bits)5431 static void set_has_color_space_agnostic(HasBits* has_bits) {
5432 (*has_bits)[0] |= 536870912u;
5433 }
set_has_shadow_radius(HasBits * has_bits)5434 static void set_has_shadow_radius(HasBits* has_bits) {
5435 (*has_bits)[1] |= 1u;
5436 }
set_has_frame_rate_selection_priority(HasBits * has_bits)5437 static void set_has_frame_rate_selection_priority(HasBits* has_bits) {
5438 (*has_bits)[1] |= 2u;
5439 }
set_has_frame_rate(HasBits * has_bits)5440 static void set_has_frame_rate(HasBits* has_bits) {
5441 (*has_bits)[1] |= 4u;
5442 }
set_has_frame_rate_compatibility(HasBits * has_bits)5443 static void set_has_frame_rate_compatibility(HasBits* has_bits) {
5444 (*has_bits)[1] |= 8u;
5445 }
set_has_change_frame_rate_strategy(HasBits * has_bits)5446 static void set_has_change_frame_rate_strategy(HasBits* has_bits) {
5447 (*has_bits)[1] |= 16u;
5448 }
set_has_fixed_transform_hint(HasBits * has_bits)5449 static void set_has_fixed_transform_hint(HasBits* has_bits) {
5450 (*has_bits)[1] |= 64u;
5451 }
set_has_frame_number(HasBits * has_bits)5452 static void set_has_frame_number(HasBits* has_bits) {
5453 (*has_bits)[1] |= 32u;
5454 }
set_has_auto_refresh(HasBits * has_bits)5455 static void set_has_auto_refresh(HasBits* has_bits) {
5456 (*has_bits)[0] |= 1073741824u;
5457 }
set_has_is_trusted_overlay(HasBits * has_bits)5458 static void set_has_is_trusted_overlay(HasBits* has_bits) {
5459 (*has_bits)[1] |= 128u;
5460 }
5461 static const ::perfetto::protos::RectProto& buffer_crop(const LayerState* msg);
set_has_buffer_crop(HasBits * has_bits)5462 static void set_has_buffer_crop(HasBits* has_bits) {
5463 (*has_bits)[0] |= 128u;
5464 }
5465 static const ::perfetto::protos::RectProto& destination_frame(const LayerState* msg);
set_has_destination_frame(HasBits * has_bits)5466 static void set_has_destination_frame(HasBits* has_bits) {
5467 (*has_bits)[0] |= 256u;
5468 }
set_has_drop_input_mode(HasBits * has_bits)5469 static void set_has_drop_input_mode(HasBits* has_bits) {
5470 (*has_bits)[1] |= 256u;
5471 }
set_has_trusted_overlay(HasBits * has_bits)5472 static void set_has_trusted_overlay(HasBits* has_bits) {
5473 (*has_bits)[1] |= 512u;
5474 }
5475 };
5476
5477 const ::perfetto::protos::LayerState_Matrix22&
matrix(const LayerState * msg)5478 LayerState::_Internal::matrix(const LayerState* msg) {
5479 return *msg->_impl_.matrix_;
5480 }
5481 const ::perfetto::protos::LayerState_Color3&
color(const LayerState * msg)5482 LayerState::_Internal::color(const LayerState* msg) {
5483 return *msg->_impl_.color_;
5484 }
5485 const ::perfetto::protos::RegionProto&
transparent_region(const LayerState * msg)5486 LayerState::_Internal::transparent_region(const LayerState* msg) {
5487 return *msg->_impl_.transparent_region_;
5488 }
5489 const ::perfetto::protos::RectProto&
crop(const LayerState * msg)5490 LayerState::_Internal::crop(const LayerState* msg) {
5491 return *msg->_impl_.crop_;
5492 }
5493 const ::perfetto::protos::LayerState_BufferData&
buffer_data(const LayerState * msg)5494 LayerState::_Internal::buffer_data(const LayerState* msg) {
5495 return *msg->_impl_.buffer_data_;
5496 }
5497 const ::perfetto::protos::ColorTransformProto&
color_transform(const LayerState * msg)5498 LayerState::_Internal::color_transform(const LayerState* msg) {
5499 return *msg->_impl_.color_transform_;
5500 }
5501 const ::perfetto::protos::LayerState_WindowInfo&
window_info_handle(const LayerState * msg)5502 LayerState::_Internal::window_info_handle(const LayerState* msg) {
5503 return *msg->_impl_.window_info_handle_;
5504 }
5505 const ::perfetto::protos::RectProto&
buffer_crop(const LayerState * msg)5506 LayerState::_Internal::buffer_crop(const LayerState* msg) {
5507 return *msg->_impl_.buffer_crop_;
5508 }
5509 const ::perfetto::protos::RectProto&
destination_frame(const LayerState * msg)5510 LayerState::_Internal::destination_frame(const LayerState* msg) {
5511 return *msg->_impl_.destination_frame_;
5512 }
clear_transparent_region()5513 void LayerState::clear_transparent_region() {
5514 if (_impl_.transparent_region_ != nullptr) _impl_.transparent_region_->Clear();
5515 _impl_._has_bits_[0] &= ~0x00000004u;
5516 }
clear_crop()5517 void LayerState::clear_crop() {
5518 if (_impl_.crop_ != nullptr) _impl_.crop_->Clear();
5519 _impl_._has_bits_[0] &= ~0x00000008u;
5520 }
clear_color_transform()5521 void LayerState::clear_color_transform() {
5522 if (_impl_.color_transform_ != nullptr) _impl_.color_transform_->Clear();
5523 _impl_._has_bits_[0] &= ~0x00000020u;
5524 }
clear_blur_regions()5525 void LayerState::clear_blur_regions() {
5526 _impl_.blur_regions_.Clear();
5527 }
clear_buffer_crop()5528 void LayerState::clear_buffer_crop() {
5529 if (_impl_.buffer_crop_ != nullptr) _impl_.buffer_crop_->Clear();
5530 _impl_._has_bits_[0] &= ~0x00000080u;
5531 }
clear_destination_frame()5532 void LayerState::clear_destination_frame() {
5533 if (_impl_.destination_frame_ != nullptr) _impl_.destination_frame_->Clear();
5534 _impl_._has_bits_[0] &= ~0x00000100u;
5535 }
LayerState(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)5536 LayerState::LayerState(::PROTOBUF_NAMESPACE_ID::Arena* arena,
5537 bool is_message_owned)
5538 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
5539 SharedCtor(arena, is_message_owned);
5540 // @@protoc_insertion_point(arena_constructor:perfetto.protos.LayerState)
5541 }
LayerState(const LayerState & from)5542 LayerState::LayerState(const LayerState& from)
5543 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
5544 LayerState* const _this = this; (void)_this;
5545 new (&_impl_) Impl_{
5546 decltype(_impl_._has_bits_){from._impl_._has_bits_}
5547 , /*decltype(_impl_._cached_size_)*/{}
5548 , decltype(_impl_.blur_regions_){from._impl_.blur_regions_}
5549 , decltype(_impl_.matrix_){nullptr}
5550 , decltype(_impl_.color_){nullptr}
5551 , decltype(_impl_.transparent_region_){nullptr}
5552 , decltype(_impl_.crop_){nullptr}
5553 , decltype(_impl_.buffer_data_){nullptr}
5554 , decltype(_impl_.color_transform_){nullptr}
5555 , decltype(_impl_.window_info_handle_){nullptr}
5556 , decltype(_impl_.buffer_crop_){nullptr}
5557 , decltype(_impl_.destination_frame_){nullptr}
5558 , decltype(_impl_.what_){}
5559 , decltype(_impl_.layer_id_){}
5560 , decltype(_impl_.x_){}
5561 , decltype(_impl_.y_){}
5562 , decltype(_impl_.z_){}
5563 , decltype(_impl_.w_){}
5564 , decltype(_impl_.h_){}
5565 , decltype(_impl_.layer_stack_){}
5566 , decltype(_impl_.flags_){}
5567 , decltype(_impl_.mask_){}
5568 , decltype(_impl_.corner_radius_){}
5569 , decltype(_impl_.background_blur_radius_){}
5570 , decltype(_impl_.parent_id_){}
5571 , decltype(_impl_.relative_parent_id_){}
5572 , decltype(_impl_.alpha_){}
5573 , decltype(_impl_.transform_){}
5574 , decltype(_impl_.api_){}
5575 , decltype(_impl_.bg_color_alpha_){}
5576 , decltype(_impl_.transform_to_display_inverse_){}
5577 , decltype(_impl_.has_sideband_stream_){}
5578 , decltype(_impl_.color_space_agnostic_){}
5579 , decltype(_impl_.auto_refresh_){}
5580 , decltype(_impl_.bg_color_dataspace_){}
5581 , decltype(_impl_.shadow_radius_){}
5582 , decltype(_impl_.frame_rate_selection_priority_){}
5583 , decltype(_impl_.frame_rate_){}
5584 , decltype(_impl_.frame_rate_compatibility_){}
5585 , decltype(_impl_.change_frame_rate_strategy_){}
5586 , decltype(_impl_.frame_number_){}
5587 , decltype(_impl_.fixed_transform_hint_){}
5588 , decltype(_impl_.is_trusted_overlay_){}
5589 , decltype(_impl_.drop_input_mode_){}
5590 , decltype(_impl_.trusted_overlay_){}};
5591
5592 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
5593 if (from._internal_has_matrix()) {
5594 _this->_impl_.matrix_ = new ::perfetto::protos::LayerState_Matrix22(*from._impl_.matrix_);
5595 }
5596 if (from._internal_has_color()) {
5597 _this->_impl_.color_ = new ::perfetto::protos::LayerState_Color3(*from._impl_.color_);
5598 }
5599 if (from._internal_has_transparent_region()) {
5600 _this->_impl_.transparent_region_ = new ::perfetto::protos::RegionProto(*from._impl_.transparent_region_);
5601 }
5602 if (from._internal_has_crop()) {
5603 _this->_impl_.crop_ = new ::perfetto::protos::RectProto(*from._impl_.crop_);
5604 }
5605 if (from._internal_has_buffer_data()) {
5606 _this->_impl_.buffer_data_ = new ::perfetto::protos::LayerState_BufferData(*from._impl_.buffer_data_);
5607 }
5608 if (from._internal_has_color_transform()) {
5609 _this->_impl_.color_transform_ = new ::perfetto::protos::ColorTransformProto(*from._impl_.color_transform_);
5610 }
5611 if (from._internal_has_window_info_handle()) {
5612 _this->_impl_.window_info_handle_ = new ::perfetto::protos::LayerState_WindowInfo(*from._impl_.window_info_handle_);
5613 }
5614 if (from._internal_has_buffer_crop()) {
5615 _this->_impl_.buffer_crop_ = new ::perfetto::protos::RectProto(*from._impl_.buffer_crop_);
5616 }
5617 if (from._internal_has_destination_frame()) {
5618 _this->_impl_.destination_frame_ = new ::perfetto::protos::RectProto(*from._impl_.destination_frame_);
5619 }
5620 ::memcpy(&_impl_.what_, &from._impl_.what_,
5621 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.trusted_overlay_) -
5622 reinterpret_cast<char*>(&_impl_.what_)) + sizeof(_impl_.trusted_overlay_));
5623 // @@protoc_insertion_point(copy_constructor:perfetto.protos.LayerState)
5624 }
5625
SharedCtor(::_pb::Arena * arena,bool is_message_owned)5626 inline void LayerState::SharedCtor(
5627 ::_pb::Arena* arena, bool is_message_owned) {
5628 (void)arena;
5629 (void)is_message_owned;
5630 new (&_impl_) Impl_{
5631 decltype(_impl_._has_bits_){}
5632 , /*decltype(_impl_._cached_size_)*/{}
5633 , decltype(_impl_.blur_regions_){arena}
5634 , decltype(_impl_.matrix_){nullptr}
5635 , decltype(_impl_.color_){nullptr}
5636 , decltype(_impl_.transparent_region_){nullptr}
5637 , decltype(_impl_.crop_){nullptr}
5638 , decltype(_impl_.buffer_data_){nullptr}
5639 , decltype(_impl_.color_transform_){nullptr}
5640 , decltype(_impl_.window_info_handle_){nullptr}
5641 , decltype(_impl_.buffer_crop_){nullptr}
5642 , decltype(_impl_.destination_frame_){nullptr}
5643 , decltype(_impl_.what_){::uint64_t{0u}}
5644 , decltype(_impl_.layer_id_){0u}
5645 , decltype(_impl_.x_){0}
5646 , decltype(_impl_.y_){0}
5647 , decltype(_impl_.z_){0}
5648 , decltype(_impl_.w_){0u}
5649 , decltype(_impl_.h_){0u}
5650 , decltype(_impl_.layer_stack_){0u}
5651 , decltype(_impl_.flags_){0u}
5652 , decltype(_impl_.mask_){0u}
5653 , decltype(_impl_.corner_radius_){0}
5654 , decltype(_impl_.background_blur_radius_){0u}
5655 , decltype(_impl_.parent_id_){0u}
5656 , decltype(_impl_.relative_parent_id_){0u}
5657 , decltype(_impl_.alpha_){0}
5658 , decltype(_impl_.transform_){0u}
5659 , decltype(_impl_.api_){0}
5660 , decltype(_impl_.bg_color_alpha_){0}
5661 , decltype(_impl_.transform_to_display_inverse_){false}
5662 , decltype(_impl_.has_sideband_stream_){false}
5663 , decltype(_impl_.color_space_agnostic_){false}
5664 , decltype(_impl_.auto_refresh_){false}
5665 , decltype(_impl_.bg_color_dataspace_){0}
5666 , decltype(_impl_.shadow_radius_){0}
5667 , decltype(_impl_.frame_rate_selection_priority_){0}
5668 , decltype(_impl_.frame_rate_){0}
5669 , decltype(_impl_.frame_rate_compatibility_){0}
5670 , decltype(_impl_.change_frame_rate_strategy_){0}
5671 , decltype(_impl_.frame_number_){::uint64_t{0u}}
5672 , decltype(_impl_.fixed_transform_hint_){0u}
5673 , decltype(_impl_.is_trusted_overlay_){false}
5674 , decltype(_impl_.drop_input_mode_){0}
5675 , decltype(_impl_.trusted_overlay_){0}
5676 };
5677 }
5678
~LayerState()5679 LayerState::~LayerState() {
5680 // @@protoc_insertion_point(destructor:perfetto.protos.LayerState)
5681 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
5682 (void)arena;
5683 return;
5684 }
5685 SharedDtor();
5686 }
5687
SharedDtor()5688 inline void LayerState::SharedDtor() {
5689 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
5690 _impl_.blur_regions_.~RepeatedPtrField();
5691 if (this != internal_default_instance()) delete _impl_.matrix_;
5692 if (this != internal_default_instance()) delete _impl_.color_;
5693 if (this != internal_default_instance()) delete _impl_.transparent_region_;
5694 if (this != internal_default_instance()) delete _impl_.crop_;
5695 if (this != internal_default_instance()) delete _impl_.buffer_data_;
5696 if (this != internal_default_instance()) delete _impl_.color_transform_;
5697 if (this != internal_default_instance()) delete _impl_.window_info_handle_;
5698 if (this != internal_default_instance()) delete _impl_.buffer_crop_;
5699 if (this != internal_default_instance()) delete _impl_.destination_frame_;
5700 }
5701
SetCachedSize(int size) const5702 void LayerState::SetCachedSize(int size) const {
5703 _impl_._cached_size_.Set(size);
5704 }
5705
Clear()5706 void LayerState::Clear() {
5707 // @@protoc_insertion_point(message_clear_start:perfetto.protos.LayerState)
5708 ::uint32_t cached_has_bits = 0;
5709 // Prevent compiler warnings about cached_has_bits being unused
5710 (void) cached_has_bits;
5711
5712 _impl_.blur_regions_.Clear();
5713 cached_has_bits = _impl_._has_bits_[0];
5714 if (cached_has_bits & 0x000000ffu) {
5715 if (cached_has_bits & 0x00000001u) {
5716 GOOGLE_DCHECK(_impl_.matrix_ != nullptr);
5717 _impl_.matrix_->Clear();
5718 }
5719 if (cached_has_bits & 0x00000002u) {
5720 GOOGLE_DCHECK(_impl_.color_ != nullptr);
5721 _impl_.color_->Clear();
5722 }
5723 if (cached_has_bits & 0x00000004u) {
5724 GOOGLE_DCHECK(_impl_.transparent_region_ != nullptr);
5725 _impl_.transparent_region_->Clear();
5726 }
5727 if (cached_has_bits & 0x00000008u) {
5728 GOOGLE_DCHECK(_impl_.crop_ != nullptr);
5729 _impl_.crop_->Clear();
5730 }
5731 if (cached_has_bits & 0x00000010u) {
5732 GOOGLE_DCHECK(_impl_.buffer_data_ != nullptr);
5733 _impl_.buffer_data_->Clear();
5734 }
5735 if (cached_has_bits & 0x00000020u) {
5736 GOOGLE_DCHECK(_impl_.color_transform_ != nullptr);
5737 _impl_.color_transform_->Clear();
5738 }
5739 if (cached_has_bits & 0x00000040u) {
5740 GOOGLE_DCHECK(_impl_.window_info_handle_ != nullptr);
5741 _impl_.window_info_handle_->Clear();
5742 }
5743 if (cached_has_bits & 0x00000080u) {
5744 GOOGLE_DCHECK(_impl_.buffer_crop_ != nullptr);
5745 _impl_.buffer_crop_->Clear();
5746 }
5747 }
5748 if (cached_has_bits & 0x00000100u) {
5749 GOOGLE_DCHECK(_impl_.destination_frame_ != nullptr);
5750 _impl_.destination_frame_->Clear();
5751 }
5752 if (cached_has_bits & 0x0000fe00u) {
5753 ::memset(&_impl_.what_, 0, static_cast<size_t>(
5754 reinterpret_cast<char*>(&_impl_.h_) -
5755 reinterpret_cast<char*>(&_impl_.what_)) + sizeof(_impl_.h_));
5756 }
5757 if (cached_has_bits & 0x00ff0000u) {
5758 ::memset(&_impl_.layer_stack_, 0, static_cast<size_t>(
5759 reinterpret_cast<char*>(&_impl_.alpha_) -
5760 reinterpret_cast<char*>(&_impl_.layer_stack_)) + sizeof(_impl_.alpha_));
5761 }
5762 if (cached_has_bits & 0xff000000u) {
5763 ::memset(&_impl_.transform_, 0, static_cast<size_t>(
5764 reinterpret_cast<char*>(&_impl_.bg_color_dataspace_) -
5765 reinterpret_cast<char*>(&_impl_.transform_)) + sizeof(_impl_.bg_color_dataspace_));
5766 }
5767 cached_has_bits = _impl_._has_bits_[1];
5768 if (cached_has_bits & 0x000000ffu) {
5769 ::memset(&_impl_.shadow_radius_, 0, static_cast<size_t>(
5770 reinterpret_cast<char*>(&_impl_.is_trusted_overlay_) -
5771 reinterpret_cast<char*>(&_impl_.shadow_radius_)) + sizeof(_impl_.is_trusted_overlay_));
5772 }
5773 if (cached_has_bits & 0x00000300u) {
5774 ::memset(&_impl_.drop_input_mode_, 0, static_cast<size_t>(
5775 reinterpret_cast<char*>(&_impl_.trusted_overlay_) -
5776 reinterpret_cast<char*>(&_impl_.drop_input_mode_)) + sizeof(_impl_.trusted_overlay_));
5777 }
5778 _impl_._has_bits_.Clear();
5779 _internal_metadata_.Clear<std::string>();
5780 }
5781
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)5782 const char* LayerState::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
5783 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
5784 while (!ctx->Done(&ptr)) {
5785 ::uint32_t tag;
5786 ptr = ::_pbi::ReadTag(ptr, &tag);
5787 switch (tag >> 3) {
5788 // optional uint32 layer_id = 1;
5789 case 1:
5790 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
5791 _Internal::set_has_layer_id(&_impl_._has_bits_);
5792 _impl_.layer_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5793 CHK_(ptr);
5794 } else {
5795 goto handle_unusual;
5796 }
5797 continue;
5798 // optional uint64 what = 2;
5799 case 2:
5800 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
5801 _Internal::set_has_what(&_impl_._has_bits_);
5802 _impl_.what_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
5803 CHK_(ptr);
5804 } else {
5805 goto handle_unusual;
5806 }
5807 continue;
5808 // optional float x = 3;
5809 case 3:
5810 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 29)) {
5811 _Internal::set_has_x(&_impl_._has_bits_);
5812 _impl_.x_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
5813 ptr += sizeof(float);
5814 } else {
5815 goto handle_unusual;
5816 }
5817 continue;
5818 // optional float y = 4;
5819 case 4:
5820 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 37)) {
5821 _Internal::set_has_y(&_impl_._has_bits_);
5822 _impl_.y_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
5823 ptr += sizeof(float);
5824 } else {
5825 goto handle_unusual;
5826 }
5827 continue;
5828 // optional int32 z = 5;
5829 case 5:
5830 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
5831 _Internal::set_has_z(&_impl_._has_bits_);
5832 _impl_.z_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5833 CHK_(ptr);
5834 } else {
5835 goto handle_unusual;
5836 }
5837 continue;
5838 // optional uint32 w = 6;
5839 case 6:
5840 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
5841 _Internal::set_has_w(&_impl_._has_bits_);
5842 _impl_.w_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5843 CHK_(ptr);
5844 } else {
5845 goto handle_unusual;
5846 }
5847 continue;
5848 // optional uint32 h = 7;
5849 case 7:
5850 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
5851 _Internal::set_has_h(&_impl_._has_bits_);
5852 _impl_.h_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5853 CHK_(ptr);
5854 } else {
5855 goto handle_unusual;
5856 }
5857 continue;
5858 // optional uint32 layer_stack = 8;
5859 case 8:
5860 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
5861 _Internal::set_has_layer_stack(&_impl_._has_bits_);
5862 _impl_.layer_stack_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5863 CHK_(ptr);
5864 } else {
5865 goto handle_unusual;
5866 }
5867 continue;
5868 // optional uint32 flags = 9;
5869 case 9:
5870 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
5871 _Internal::set_has_flags(&_impl_._has_bits_);
5872 _impl_.flags_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5873 CHK_(ptr);
5874 } else {
5875 goto handle_unusual;
5876 }
5877 continue;
5878 // optional uint32 mask = 10;
5879 case 10:
5880 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 80)) {
5881 _Internal::set_has_mask(&_impl_._has_bits_);
5882 _impl_.mask_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5883 CHK_(ptr);
5884 } else {
5885 goto handle_unusual;
5886 }
5887 continue;
5888 // optional .perfetto.protos.LayerState.Matrix22 matrix = 11;
5889 case 11:
5890 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 90)) {
5891 ptr = ctx->ParseMessage(_internal_mutable_matrix(), ptr);
5892 CHK_(ptr);
5893 } else {
5894 goto handle_unusual;
5895 }
5896 continue;
5897 // optional float corner_radius = 12;
5898 case 12:
5899 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 101)) {
5900 _Internal::set_has_corner_radius(&_impl_._has_bits_);
5901 _impl_.corner_radius_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
5902 ptr += sizeof(float);
5903 } else {
5904 goto handle_unusual;
5905 }
5906 continue;
5907 // optional uint32 background_blur_radius = 13;
5908 case 13:
5909 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 104)) {
5910 _Internal::set_has_background_blur_radius(&_impl_._has_bits_);
5911 _impl_.background_blur_radius_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5912 CHK_(ptr);
5913 } else {
5914 goto handle_unusual;
5915 }
5916 continue;
5917 // optional uint32 parent_id = 14;
5918 case 14:
5919 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 112)) {
5920 _Internal::set_has_parent_id(&_impl_._has_bits_);
5921 _impl_.parent_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5922 CHK_(ptr);
5923 } else {
5924 goto handle_unusual;
5925 }
5926 continue;
5927 // optional uint32 relative_parent_id = 15;
5928 case 15:
5929 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 120)) {
5930 _Internal::set_has_relative_parent_id(&_impl_._has_bits_);
5931 _impl_.relative_parent_id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5932 CHK_(ptr);
5933 } else {
5934 goto handle_unusual;
5935 }
5936 continue;
5937 // optional float alpha = 16;
5938 case 16:
5939 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 133)) {
5940 _Internal::set_has_alpha(&_impl_._has_bits_);
5941 _impl_.alpha_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
5942 ptr += sizeof(float);
5943 } else {
5944 goto handle_unusual;
5945 }
5946 continue;
5947 // optional .perfetto.protos.LayerState.Color3 color = 17;
5948 case 17:
5949 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 138)) {
5950 ptr = ctx->ParseMessage(_internal_mutable_color(), ptr);
5951 CHK_(ptr);
5952 } else {
5953 goto handle_unusual;
5954 }
5955 continue;
5956 // optional .perfetto.protos.RegionProto transparent_region = 18;
5957 case 18:
5958 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 146)) {
5959 ptr = ctx->ParseMessage(_internal_mutable_transparent_region(), ptr);
5960 CHK_(ptr);
5961 } else {
5962 goto handle_unusual;
5963 }
5964 continue;
5965 // optional uint32 transform = 19;
5966 case 19:
5967 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 152)) {
5968 _Internal::set_has_transform(&_impl_._has_bits_);
5969 _impl_.transform_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
5970 CHK_(ptr);
5971 } else {
5972 goto handle_unusual;
5973 }
5974 continue;
5975 // optional bool transform_to_display_inverse = 20;
5976 case 20:
5977 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 160)) {
5978 _Internal::set_has_transform_to_display_inverse(&_impl_._has_bits_);
5979 _impl_.transform_to_display_inverse_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
5980 CHK_(ptr);
5981 } else {
5982 goto handle_unusual;
5983 }
5984 continue;
5985 // optional .perfetto.protos.RectProto crop = 21;
5986 case 21:
5987 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 170)) {
5988 ptr = ctx->ParseMessage(_internal_mutable_crop(), ptr);
5989 CHK_(ptr);
5990 } else {
5991 goto handle_unusual;
5992 }
5993 continue;
5994 // optional .perfetto.protos.LayerState.BufferData buffer_data = 22;
5995 case 22:
5996 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 178)) {
5997 ptr = ctx->ParseMessage(_internal_mutable_buffer_data(), ptr);
5998 CHK_(ptr);
5999 } else {
6000 goto handle_unusual;
6001 }
6002 continue;
6003 // optional int32 api = 23;
6004 case 23:
6005 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 184)) {
6006 _Internal::set_has_api(&_impl_._has_bits_);
6007 _impl_.api_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
6008 CHK_(ptr);
6009 } else {
6010 goto handle_unusual;
6011 }
6012 continue;
6013 // optional bool has_sideband_stream = 24;
6014 case 24:
6015 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 192)) {
6016 _Internal::set_has_has_sideband_stream(&_impl_._has_bits_);
6017 _impl_.has_sideband_stream_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6018 CHK_(ptr);
6019 } else {
6020 goto handle_unusual;
6021 }
6022 continue;
6023 // optional .perfetto.protos.ColorTransformProto color_transform = 25;
6024 case 25:
6025 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 202)) {
6026 ptr = ctx->ParseMessage(_internal_mutable_color_transform(), ptr);
6027 CHK_(ptr);
6028 } else {
6029 goto handle_unusual;
6030 }
6031 continue;
6032 // repeated .perfetto.protos.BlurRegion blur_regions = 26;
6033 case 26:
6034 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 210)) {
6035 ptr -= 2;
6036 do {
6037 ptr += 2;
6038 ptr = ctx->ParseMessage(_internal_add_blur_regions(), ptr);
6039 CHK_(ptr);
6040 if (!ctx->DataAvailable(ptr)) break;
6041 } while (::PROTOBUF_NAMESPACE_ID::internal::ExpectTag<210>(ptr));
6042 } else {
6043 goto handle_unusual;
6044 }
6045 continue;
6046 // optional .perfetto.protos.LayerState.WindowInfo window_info_handle = 27;
6047 case 27:
6048 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 218)) {
6049 ptr = ctx->ParseMessage(_internal_mutable_window_info_handle(), ptr);
6050 CHK_(ptr);
6051 } else {
6052 goto handle_unusual;
6053 }
6054 continue;
6055 // optional float bg_color_alpha = 28;
6056 case 28:
6057 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 229)) {
6058 _Internal::set_has_bg_color_alpha(&_impl_._has_bits_);
6059 _impl_.bg_color_alpha_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
6060 ptr += sizeof(float);
6061 } else {
6062 goto handle_unusual;
6063 }
6064 continue;
6065 // optional int32 bg_color_dataspace = 29;
6066 case 29:
6067 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 232)) {
6068 _Internal::set_has_bg_color_dataspace(&_impl_._has_bits_);
6069 _impl_.bg_color_dataspace_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
6070 CHK_(ptr);
6071 } else {
6072 goto handle_unusual;
6073 }
6074 continue;
6075 // optional bool color_space_agnostic = 30;
6076 case 30:
6077 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 240)) {
6078 _Internal::set_has_color_space_agnostic(&_impl_._has_bits_);
6079 _impl_.color_space_agnostic_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6080 CHK_(ptr);
6081 } else {
6082 goto handle_unusual;
6083 }
6084 continue;
6085 // optional float shadow_radius = 31;
6086 case 31:
6087 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 253)) {
6088 _Internal::set_has_shadow_radius(&_impl_._has_bits_);
6089 _impl_.shadow_radius_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
6090 ptr += sizeof(float);
6091 } else {
6092 goto handle_unusual;
6093 }
6094 continue;
6095 // optional int32 frame_rate_selection_priority = 32;
6096 case 32:
6097 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 0)) {
6098 _Internal::set_has_frame_rate_selection_priority(&_impl_._has_bits_);
6099 _impl_.frame_rate_selection_priority_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
6100 CHK_(ptr);
6101 } else {
6102 goto handle_unusual;
6103 }
6104 continue;
6105 // optional float frame_rate = 33;
6106 case 33:
6107 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 13)) {
6108 _Internal::set_has_frame_rate(&_impl_._has_bits_);
6109 _impl_.frame_rate_ = ::PROTOBUF_NAMESPACE_ID::internal::UnalignedLoad<float>(ptr);
6110 ptr += sizeof(float);
6111 } else {
6112 goto handle_unusual;
6113 }
6114 continue;
6115 // optional int32 frame_rate_compatibility = 34;
6116 case 34:
6117 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
6118 _Internal::set_has_frame_rate_compatibility(&_impl_._has_bits_);
6119 _impl_.frame_rate_compatibility_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
6120 CHK_(ptr);
6121 } else {
6122 goto handle_unusual;
6123 }
6124 continue;
6125 // optional int32 change_frame_rate_strategy = 35;
6126 case 35:
6127 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
6128 _Internal::set_has_change_frame_rate_strategy(&_impl_._has_bits_);
6129 _impl_.change_frame_rate_strategy_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
6130 CHK_(ptr);
6131 } else {
6132 goto handle_unusual;
6133 }
6134 continue;
6135 // optional uint32 fixed_transform_hint = 36;
6136 case 36:
6137 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
6138 _Internal::set_has_fixed_transform_hint(&_impl_._has_bits_);
6139 _impl_.fixed_transform_hint_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
6140 CHK_(ptr);
6141 } else {
6142 goto handle_unusual;
6143 }
6144 continue;
6145 // optional uint64 frame_number = 37;
6146 case 37:
6147 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
6148 _Internal::set_has_frame_number(&_impl_._has_bits_);
6149 _impl_.frame_number_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6150 CHK_(ptr);
6151 } else {
6152 goto handle_unusual;
6153 }
6154 continue;
6155 // optional bool auto_refresh = 38;
6156 case 38:
6157 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 48)) {
6158 _Internal::set_has_auto_refresh(&_impl_._has_bits_);
6159 _impl_.auto_refresh_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6160 CHK_(ptr);
6161 } else {
6162 goto handle_unusual;
6163 }
6164 continue;
6165 // optional bool is_trusted_overlay = 39;
6166 case 39:
6167 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 56)) {
6168 _Internal::set_has_is_trusted_overlay(&_impl_._has_bits_);
6169 _impl_.is_trusted_overlay_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6170 CHK_(ptr);
6171 } else {
6172 goto handle_unusual;
6173 }
6174 continue;
6175 // optional .perfetto.protos.RectProto buffer_crop = 40;
6176 case 40:
6177 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 66)) {
6178 ptr = ctx->ParseMessage(_internal_mutable_buffer_crop(), ptr);
6179 CHK_(ptr);
6180 } else {
6181 goto handle_unusual;
6182 }
6183 continue;
6184 // optional .perfetto.protos.RectProto destination_frame = 41;
6185 case 41:
6186 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 74)) {
6187 ptr = ctx->ParseMessage(_internal_mutable_destination_frame(), ptr);
6188 CHK_(ptr);
6189 } else {
6190 goto handle_unusual;
6191 }
6192 continue;
6193 // optional .perfetto.protos.LayerState.DropInputMode drop_input_mode = 42;
6194 case 42:
6195 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 80)) {
6196 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6197 CHK_(ptr);
6198 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::LayerState_DropInputMode_IsValid(val))) {
6199 _internal_set_drop_input_mode(static_cast<::perfetto::protos::LayerState_DropInputMode>(val));
6200 } else {
6201 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(42, val, mutable_unknown_fields());
6202 }
6203 } else {
6204 goto handle_unusual;
6205 }
6206 continue;
6207 // optional .perfetto.protos.TrustedOverlay trusted_overlay = 43;
6208 case 43:
6209 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 88)) {
6210 ::uint64_t val = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint64(&ptr);
6211 CHK_(ptr);
6212 if (PROTOBUF_PREDICT_TRUE(::perfetto::protos::TrustedOverlay_IsValid(val))) {
6213 _internal_set_trusted_overlay(static_cast<::perfetto::protos::TrustedOverlay>(val));
6214 } else {
6215 ::PROTOBUF_NAMESPACE_ID::internal::WriteVarint(43, val, mutable_unknown_fields());
6216 }
6217 } else {
6218 goto handle_unusual;
6219 }
6220 continue;
6221 default:
6222 goto handle_unusual;
6223 } // switch
6224 handle_unusual:
6225 if ((tag == 0) || ((tag & 7) == 4)) {
6226 CHK_(ptr);
6227 ctx->SetLastTag(tag);
6228 goto message_done;
6229 }
6230 ptr = UnknownFieldParse(
6231 tag,
6232 _internal_metadata_.mutable_unknown_fields<std::string>(),
6233 ptr, ctx);
6234 CHK_(ptr != nullptr);
6235 } // while
6236 message_done:
6237 return ptr;
6238 failure:
6239 ptr = nullptr;
6240 goto message_done;
6241 #undef CHK_
6242 }
6243
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const6244 ::uint8_t* LayerState::_InternalSerialize(
6245 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
6246 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.LayerState)
6247 ::uint32_t cached_has_bits = 0;
6248 (void) cached_has_bits;
6249
6250 cached_has_bits = _impl_._has_bits_[0];
6251 // optional uint32 layer_id = 1;
6252 if (cached_has_bits & 0x00000400u) {
6253 target = stream->EnsureSpace(target);
6254 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(1, this->_internal_layer_id(), target);
6255 }
6256
6257 // optional uint64 what = 2;
6258 if (cached_has_bits & 0x00000200u) {
6259 target = stream->EnsureSpace(target);
6260 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(2, this->_internal_what(), target);
6261 }
6262
6263 // optional float x = 3;
6264 if (cached_has_bits & 0x00000800u) {
6265 target = stream->EnsureSpace(target);
6266 target = ::_pbi::WireFormatLite::WriteFloatToArray(3, this->_internal_x(), target);
6267 }
6268
6269 // optional float y = 4;
6270 if (cached_has_bits & 0x00001000u) {
6271 target = stream->EnsureSpace(target);
6272 target = ::_pbi::WireFormatLite::WriteFloatToArray(4, this->_internal_y(), target);
6273 }
6274
6275 // optional int32 z = 5;
6276 if (cached_has_bits & 0x00002000u) {
6277 target = stream->EnsureSpace(target);
6278 target = ::_pbi::WireFormatLite::WriteInt32ToArray(5, this->_internal_z(), target);
6279 }
6280
6281 // optional uint32 w = 6;
6282 if (cached_has_bits & 0x00004000u) {
6283 target = stream->EnsureSpace(target);
6284 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(6, this->_internal_w(), target);
6285 }
6286
6287 // optional uint32 h = 7;
6288 if (cached_has_bits & 0x00008000u) {
6289 target = stream->EnsureSpace(target);
6290 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(7, this->_internal_h(), target);
6291 }
6292
6293 // optional uint32 layer_stack = 8;
6294 if (cached_has_bits & 0x00010000u) {
6295 target = stream->EnsureSpace(target);
6296 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(8, this->_internal_layer_stack(), target);
6297 }
6298
6299 // optional uint32 flags = 9;
6300 if (cached_has_bits & 0x00020000u) {
6301 target = stream->EnsureSpace(target);
6302 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(9, this->_internal_flags(), target);
6303 }
6304
6305 // optional uint32 mask = 10;
6306 if (cached_has_bits & 0x00040000u) {
6307 target = stream->EnsureSpace(target);
6308 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(10, this->_internal_mask(), target);
6309 }
6310
6311 // optional .perfetto.protos.LayerState.Matrix22 matrix = 11;
6312 if (cached_has_bits & 0x00000001u) {
6313 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6314 InternalWriteMessage(11, _Internal::matrix(this),
6315 _Internal::matrix(this).GetCachedSize(), target, stream);
6316 }
6317
6318 // optional float corner_radius = 12;
6319 if (cached_has_bits & 0x00080000u) {
6320 target = stream->EnsureSpace(target);
6321 target = ::_pbi::WireFormatLite::WriteFloatToArray(12, this->_internal_corner_radius(), target);
6322 }
6323
6324 // optional uint32 background_blur_radius = 13;
6325 if (cached_has_bits & 0x00100000u) {
6326 target = stream->EnsureSpace(target);
6327 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(13, this->_internal_background_blur_radius(), target);
6328 }
6329
6330 // optional uint32 parent_id = 14;
6331 if (cached_has_bits & 0x00200000u) {
6332 target = stream->EnsureSpace(target);
6333 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(14, this->_internal_parent_id(), target);
6334 }
6335
6336 // optional uint32 relative_parent_id = 15;
6337 if (cached_has_bits & 0x00400000u) {
6338 target = stream->EnsureSpace(target);
6339 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(15, this->_internal_relative_parent_id(), target);
6340 }
6341
6342 // optional float alpha = 16;
6343 if (cached_has_bits & 0x00800000u) {
6344 target = stream->EnsureSpace(target);
6345 target = ::_pbi::WireFormatLite::WriteFloatToArray(16, this->_internal_alpha(), target);
6346 }
6347
6348 // optional .perfetto.protos.LayerState.Color3 color = 17;
6349 if (cached_has_bits & 0x00000002u) {
6350 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6351 InternalWriteMessage(17, _Internal::color(this),
6352 _Internal::color(this).GetCachedSize(), target, stream);
6353 }
6354
6355 // optional .perfetto.protos.RegionProto transparent_region = 18;
6356 if (cached_has_bits & 0x00000004u) {
6357 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6358 InternalWriteMessage(18, _Internal::transparent_region(this),
6359 _Internal::transparent_region(this).GetCachedSize(), target, stream);
6360 }
6361
6362 // optional uint32 transform = 19;
6363 if (cached_has_bits & 0x01000000u) {
6364 target = stream->EnsureSpace(target);
6365 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(19, this->_internal_transform(), target);
6366 }
6367
6368 // optional bool transform_to_display_inverse = 20;
6369 if (cached_has_bits & 0x08000000u) {
6370 target = stream->EnsureSpace(target);
6371 target = ::_pbi::WireFormatLite::WriteBoolToArray(20, this->_internal_transform_to_display_inverse(), target);
6372 }
6373
6374 // optional .perfetto.protos.RectProto crop = 21;
6375 if (cached_has_bits & 0x00000008u) {
6376 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6377 InternalWriteMessage(21, _Internal::crop(this),
6378 _Internal::crop(this).GetCachedSize(), target, stream);
6379 }
6380
6381 // optional .perfetto.protos.LayerState.BufferData buffer_data = 22;
6382 if (cached_has_bits & 0x00000010u) {
6383 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6384 InternalWriteMessage(22, _Internal::buffer_data(this),
6385 _Internal::buffer_data(this).GetCachedSize(), target, stream);
6386 }
6387
6388 // optional int32 api = 23;
6389 if (cached_has_bits & 0x02000000u) {
6390 target = stream->EnsureSpace(target);
6391 target = ::_pbi::WireFormatLite::WriteInt32ToArray(23, this->_internal_api(), target);
6392 }
6393
6394 // optional bool has_sideband_stream = 24;
6395 if (cached_has_bits & 0x10000000u) {
6396 target = stream->EnsureSpace(target);
6397 target = ::_pbi::WireFormatLite::WriteBoolToArray(24, this->_internal_has_sideband_stream(), target);
6398 }
6399
6400 // optional .perfetto.protos.ColorTransformProto color_transform = 25;
6401 if (cached_has_bits & 0x00000020u) {
6402 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6403 InternalWriteMessage(25, _Internal::color_transform(this),
6404 _Internal::color_transform(this).GetCachedSize(), target, stream);
6405 }
6406
6407 // repeated .perfetto.protos.BlurRegion blur_regions = 26;
6408 for (unsigned i = 0,
6409 n = static_cast<unsigned>(this->_internal_blur_regions_size()); i < n; i++) {
6410 const auto& repfield = this->_internal_blur_regions(i);
6411 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6412 InternalWriteMessage(26, repfield, repfield.GetCachedSize(), target, stream);
6413 }
6414
6415 // optional .perfetto.protos.LayerState.WindowInfo window_info_handle = 27;
6416 if (cached_has_bits & 0x00000040u) {
6417 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6418 InternalWriteMessage(27, _Internal::window_info_handle(this),
6419 _Internal::window_info_handle(this).GetCachedSize(), target, stream);
6420 }
6421
6422 // optional float bg_color_alpha = 28;
6423 if (cached_has_bits & 0x04000000u) {
6424 target = stream->EnsureSpace(target);
6425 target = ::_pbi::WireFormatLite::WriteFloatToArray(28, this->_internal_bg_color_alpha(), target);
6426 }
6427
6428 // optional int32 bg_color_dataspace = 29;
6429 if (cached_has_bits & 0x80000000u) {
6430 target = stream->EnsureSpace(target);
6431 target = ::_pbi::WireFormatLite::WriteInt32ToArray(29, this->_internal_bg_color_dataspace(), target);
6432 }
6433
6434 // optional bool color_space_agnostic = 30;
6435 if (cached_has_bits & 0x20000000u) {
6436 target = stream->EnsureSpace(target);
6437 target = ::_pbi::WireFormatLite::WriteBoolToArray(30, this->_internal_color_space_agnostic(), target);
6438 }
6439
6440 cached_has_bits = _impl_._has_bits_[1];
6441 // optional float shadow_radius = 31;
6442 if (cached_has_bits & 0x00000001u) {
6443 target = stream->EnsureSpace(target);
6444 target = ::_pbi::WireFormatLite::WriteFloatToArray(31, this->_internal_shadow_radius(), target);
6445 }
6446
6447 // optional int32 frame_rate_selection_priority = 32;
6448 if (cached_has_bits & 0x00000002u) {
6449 target = stream->EnsureSpace(target);
6450 target = ::_pbi::WireFormatLite::WriteInt32ToArray(32, this->_internal_frame_rate_selection_priority(), target);
6451 }
6452
6453 // optional float frame_rate = 33;
6454 if (cached_has_bits & 0x00000004u) {
6455 target = stream->EnsureSpace(target);
6456 target = ::_pbi::WireFormatLite::WriteFloatToArray(33, this->_internal_frame_rate(), target);
6457 }
6458
6459 // optional int32 frame_rate_compatibility = 34;
6460 if (cached_has_bits & 0x00000008u) {
6461 target = stream->EnsureSpace(target);
6462 target = ::_pbi::WireFormatLite::WriteInt32ToArray(34, this->_internal_frame_rate_compatibility(), target);
6463 }
6464
6465 // optional int32 change_frame_rate_strategy = 35;
6466 if (cached_has_bits & 0x00000010u) {
6467 target = stream->EnsureSpace(target);
6468 target = ::_pbi::WireFormatLite::WriteInt32ToArray(35, this->_internal_change_frame_rate_strategy(), target);
6469 }
6470
6471 // optional uint32 fixed_transform_hint = 36;
6472 if (cached_has_bits & 0x00000040u) {
6473 target = stream->EnsureSpace(target);
6474 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(36, this->_internal_fixed_transform_hint(), target);
6475 }
6476
6477 // optional uint64 frame_number = 37;
6478 if (cached_has_bits & 0x00000020u) {
6479 target = stream->EnsureSpace(target);
6480 target = ::_pbi::WireFormatLite::WriteUInt64ToArray(37, this->_internal_frame_number(), target);
6481 }
6482
6483 cached_has_bits = _impl_._has_bits_[0];
6484 // optional bool auto_refresh = 38;
6485 if (cached_has_bits & 0x40000000u) {
6486 target = stream->EnsureSpace(target);
6487 target = ::_pbi::WireFormatLite::WriteBoolToArray(38, this->_internal_auto_refresh(), target);
6488 }
6489
6490 cached_has_bits = _impl_._has_bits_[1];
6491 // optional bool is_trusted_overlay = 39;
6492 if (cached_has_bits & 0x00000080u) {
6493 target = stream->EnsureSpace(target);
6494 target = ::_pbi::WireFormatLite::WriteBoolToArray(39, this->_internal_is_trusted_overlay(), target);
6495 }
6496
6497 cached_has_bits = _impl_._has_bits_[0];
6498 // optional .perfetto.protos.RectProto buffer_crop = 40;
6499 if (cached_has_bits & 0x00000080u) {
6500 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6501 InternalWriteMessage(40, _Internal::buffer_crop(this),
6502 _Internal::buffer_crop(this).GetCachedSize(), target, stream);
6503 }
6504
6505 // optional .perfetto.protos.RectProto destination_frame = 41;
6506 if (cached_has_bits & 0x00000100u) {
6507 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
6508 InternalWriteMessage(41, _Internal::destination_frame(this),
6509 _Internal::destination_frame(this).GetCachedSize(), target, stream);
6510 }
6511
6512 cached_has_bits = _impl_._has_bits_[1];
6513 // optional .perfetto.protos.LayerState.DropInputMode drop_input_mode = 42;
6514 if (cached_has_bits & 0x00000100u) {
6515 target = stream->EnsureSpace(target);
6516 target = ::_pbi::WireFormatLite::WriteEnumToArray(
6517 42, this->_internal_drop_input_mode(), target);
6518 }
6519
6520 // optional .perfetto.protos.TrustedOverlay trusted_overlay = 43;
6521 if (cached_has_bits & 0x00000200u) {
6522 target = stream->EnsureSpace(target);
6523 target = ::_pbi::WireFormatLite::WriteEnumToArray(
6524 43, this->_internal_trusted_overlay(), target);
6525 }
6526
6527 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
6528 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
6529 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
6530 }
6531 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.LayerState)
6532 return target;
6533 }
6534
ByteSizeLong() const6535 size_t LayerState::ByteSizeLong() const {
6536 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.LayerState)
6537 size_t total_size = 0;
6538
6539 ::uint32_t cached_has_bits = 0;
6540 // Prevent compiler warnings about cached_has_bits being unused
6541 (void) cached_has_bits;
6542
6543 // repeated .perfetto.protos.BlurRegion blur_regions = 26;
6544 total_size += 2UL * this->_internal_blur_regions_size();
6545 for (const auto& msg : this->_impl_.blur_regions_) {
6546 total_size +=
6547 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(msg);
6548 }
6549
6550 cached_has_bits = _impl_._has_bits_[0];
6551 if (cached_has_bits & 0x000000ffu) {
6552 // optional .perfetto.protos.LayerState.Matrix22 matrix = 11;
6553 if (cached_has_bits & 0x00000001u) {
6554 total_size += 1 +
6555 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6556 *_impl_.matrix_);
6557 }
6558
6559 // optional .perfetto.protos.LayerState.Color3 color = 17;
6560 if (cached_has_bits & 0x00000002u) {
6561 total_size += 2 +
6562 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6563 *_impl_.color_);
6564 }
6565
6566 // optional .perfetto.protos.RegionProto transparent_region = 18;
6567 if (cached_has_bits & 0x00000004u) {
6568 total_size += 2 +
6569 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6570 *_impl_.transparent_region_);
6571 }
6572
6573 // optional .perfetto.protos.RectProto crop = 21;
6574 if (cached_has_bits & 0x00000008u) {
6575 total_size += 2 +
6576 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6577 *_impl_.crop_);
6578 }
6579
6580 // optional .perfetto.protos.LayerState.BufferData buffer_data = 22;
6581 if (cached_has_bits & 0x00000010u) {
6582 total_size += 2 +
6583 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6584 *_impl_.buffer_data_);
6585 }
6586
6587 // optional .perfetto.protos.ColorTransformProto color_transform = 25;
6588 if (cached_has_bits & 0x00000020u) {
6589 total_size += 2 +
6590 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6591 *_impl_.color_transform_);
6592 }
6593
6594 // optional .perfetto.protos.LayerState.WindowInfo window_info_handle = 27;
6595 if (cached_has_bits & 0x00000040u) {
6596 total_size += 2 +
6597 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6598 *_impl_.window_info_handle_);
6599 }
6600
6601 // optional .perfetto.protos.RectProto buffer_crop = 40;
6602 if (cached_has_bits & 0x00000080u) {
6603 total_size += 2 +
6604 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6605 *_impl_.buffer_crop_);
6606 }
6607
6608 }
6609 if (cached_has_bits & 0x0000ff00u) {
6610 // optional .perfetto.protos.RectProto destination_frame = 41;
6611 if (cached_has_bits & 0x00000100u) {
6612 total_size += 2 +
6613 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
6614 *_impl_.destination_frame_);
6615 }
6616
6617 // optional uint64 what = 2;
6618 if (cached_has_bits & 0x00000200u) {
6619 total_size += ::_pbi::WireFormatLite::UInt64SizePlusOne(this->_internal_what());
6620 }
6621
6622 // optional uint32 layer_id = 1;
6623 if (cached_has_bits & 0x00000400u) {
6624 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_layer_id());
6625 }
6626
6627 // optional float x = 3;
6628 if (cached_has_bits & 0x00000800u) {
6629 total_size += 1 + 4;
6630 }
6631
6632 // optional float y = 4;
6633 if (cached_has_bits & 0x00001000u) {
6634 total_size += 1 + 4;
6635 }
6636
6637 // optional int32 z = 5;
6638 if (cached_has_bits & 0x00002000u) {
6639 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_z());
6640 }
6641
6642 // optional uint32 w = 6;
6643 if (cached_has_bits & 0x00004000u) {
6644 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_w());
6645 }
6646
6647 // optional uint32 h = 7;
6648 if (cached_has_bits & 0x00008000u) {
6649 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_h());
6650 }
6651
6652 }
6653 if (cached_has_bits & 0x00ff0000u) {
6654 // optional uint32 layer_stack = 8;
6655 if (cached_has_bits & 0x00010000u) {
6656 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_layer_stack());
6657 }
6658
6659 // optional uint32 flags = 9;
6660 if (cached_has_bits & 0x00020000u) {
6661 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_flags());
6662 }
6663
6664 // optional uint32 mask = 10;
6665 if (cached_has_bits & 0x00040000u) {
6666 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_mask());
6667 }
6668
6669 // optional float corner_radius = 12;
6670 if (cached_has_bits & 0x00080000u) {
6671 total_size += 1 + 4;
6672 }
6673
6674 // optional uint32 background_blur_radius = 13;
6675 if (cached_has_bits & 0x00100000u) {
6676 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_background_blur_radius());
6677 }
6678
6679 // optional uint32 parent_id = 14;
6680 if (cached_has_bits & 0x00200000u) {
6681 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_parent_id());
6682 }
6683
6684 // optional uint32 relative_parent_id = 15;
6685 if (cached_has_bits & 0x00400000u) {
6686 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_relative_parent_id());
6687 }
6688
6689 // optional float alpha = 16;
6690 if (cached_has_bits & 0x00800000u) {
6691 total_size += 2 + 4;
6692 }
6693
6694 }
6695 if (cached_has_bits & 0xff000000u) {
6696 // optional uint32 transform = 19;
6697 if (cached_has_bits & 0x01000000u) {
6698 total_size += 2 +
6699 ::_pbi::WireFormatLite::UInt32Size(
6700 this->_internal_transform());
6701 }
6702
6703 // optional int32 api = 23;
6704 if (cached_has_bits & 0x02000000u) {
6705 total_size += 2 +
6706 ::_pbi::WireFormatLite::Int32Size(
6707 this->_internal_api());
6708 }
6709
6710 // optional float bg_color_alpha = 28;
6711 if (cached_has_bits & 0x04000000u) {
6712 total_size += 2 + 4;
6713 }
6714
6715 // optional bool transform_to_display_inverse = 20;
6716 if (cached_has_bits & 0x08000000u) {
6717 total_size += 2 + 1;
6718 }
6719
6720 // optional bool has_sideband_stream = 24;
6721 if (cached_has_bits & 0x10000000u) {
6722 total_size += 2 + 1;
6723 }
6724
6725 // optional bool color_space_agnostic = 30;
6726 if (cached_has_bits & 0x20000000u) {
6727 total_size += 2 + 1;
6728 }
6729
6730 // optional bool auto_refresh = 38;
6731 if (cached_has_bits & 0x40000000u) {
6732 total_size += 2 + 1;
6733 }
6734
6735 // optional int32 bg_color_dataspace = 29;
6736 if (cached_has_bits & 0x80000000u) {
6737 total_size += 2 +
6738 ::_pbi::WireFormatLite::Int32Size(
6739 this->_internal_bg_color_dataspace());
6740 }
6741
6742 }
6743 cached_has_bits = _impl_._has_bits_[1];
6744 if (cached_has_bits & 0x000000ffu) {
6745 // optional float shadow_radius = 31;
6746 if (cached_has_bits & 0x00000001u) {
6747 total_size += 2 + 4;
6748 }
6749
6750 // optional int32 frame_rate_selection_priority = 32;
6751 if (cached_has_bits & 0x00000002u) {
6752 total_size += 2 +
6753 ::_pbi::WireFormatLite::Int32Size(
6754 this->_internal_frame_rate_selection_priority());
6755 }
6756
6757 // optional float frame_rate = 33;
6758 if (cached_has_bits & 0x00000004u) {
6759 total_size += 2 + 4;
6760 }
6761
6762 // optional int32 frame_rate_compatibility = 34;
6763 if (cached_has_bits & 0x00000008u) {
6764 total_size += 2 +
6765 ::_pbi::WireFormatLite::Int32Size(
6766 this->_internal_frame_rate_compatibility());
6767 }
6768
6769 // optional int32 change_frame_rate_strategy = 35;
6770 if (cached_has_bits & 0x00000010u) {
6771 total_size += 2 +
6772 ::_pbi::WireFormatLite::Int32Size(
6773 this->_internal_change_frame_rate_strategy());
6774 }
6775
6776 // optional uint64 frame_number = 37;
6777 if (cached_has_bits & 0x00000020u) {
6778 total_size += 2 +
6779 ::_pbi::WireFormatLite::UInt64Size(
6780 this->_internal_frame_number());
6781 }
6782
6783 // optional uint32 fixed_transform_hint = 36;
6784 if (cached_has_bits & 0x00000040u) {
6785 total_size += 2 +
6786 ::_pbi::WireFormatLite::UInt32Size(
6787 this->_internal_fixed_transform_hint());
6788 }
6789
6790 // optional bool is_trusted_overlay = 39;
6791 if (cached_has_bits & 0x00000080u) {
6792 total_size += 2 + 1;
6793 }
6794
6795 }
6796 if (cached_has_bits & 0x00000300u) {
6797 // optional .perfetto.protos.LayerState.DropInputMode drop_input_mode = 42;
6798 if (cached_has_bits & 0x00000100u) {
6799 total_size += 2 +
6800 ::_pbi::WireFormatLite::EnumSize(this->_internal_drop_input_mode());
6801 }
6802
6803 // optional .perfetto.protos.TrustedOverlay trusted_overlay = 43;
6804 if (cached_has_bits & 0x00000200u) {
6805 total_size += 2 +
6806 ::_pbi::WireFormatLite::EnumSize(this->_internal_trusted_overlay());
6807 }
6808
6809 }
6810 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
6811 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
6812 }
6813 int cached_size = ::_pbi::ToCachedSize(total_size);
6814 SetCachedSize(cached_size);
6815 return total_size;
6816 }
6817
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)6818 void LayerState::CheckTypeAndMergeFrom(
6819 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
6820 MergeFrom(*::_pbi::DownCast<const LayerState*>(
6821 &from));
6822 }
6823
MergeFrom(const LayerState & from)6824 void LayerState::MergeFrom(const LayerState& from) {
6825 LayerState* const _this = this;
6826 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.LayerState)
6827 GOOGLE_DCHECK_NE(&from, _this);
6828 ::uint32_t cached_has_bits = 0;
6829 (void) cached_has_bits;
6830
6831 _this->_impl_.blur_regions_.MergeFrom(from._impl_.blur_regions_);
6832 cached_has_bits = from._impl_._has_bits_[0];
6833 if (cached_has_bits & 0x000000ffu) {
6834 if (cached_has_bits & 0x00000001u) {
6835 _this->_internal_mutable_matrix()->::perfetto::protos::LayerState_Matrix22::MergeFrom(
6836 from._internal_matrix());
6837 }
6838 if (cached_has_bits & 0x00000002u) {
6839 _this->_internal_mutable_color()->::perfetto::protos::LayerState_Color3::MergeFrom(
6840 from._internal_color());
6841 }
6842 if (cached_has_bits & 0x00000004u) {
6843 _this->_internal_mutable_transparent_region()->::perfetto::protos::RegionProto::MergeFrom(
6844 from._internal_transparent_region());
6845 }
6846 if (cached_has_bits & 0x00000008u) {
6847 _this->_internal_mutable_crop()->::perfetto::protos::RectProto::MergeFrom(
6848 from._internal_crop());
6849 }
6850 if (cached_has_bits & 0x00000010u) {
6851 _this->_internal_mutable_buffer_data()->::perfetto::protos::LayerState_BufferData::MergeFrom(
6852 from._internal_buffer_data());
6853 }
6854 if (cached_has_bits & 0x00000020u) {
6855 _this->_internal_mutable_color_transform()->::perfetto::protos::ColorTransformProto::MergeFrom(
6856 from._internal_color_transform());
6857 }
6858 if (cached_has_bits & 0x00000040u) {
6859 _this->_internal_mutable_window_info_handle()->::perfetto::protos::LayerState_WindowInfo::MergeFrom(
6860 from._internal_window_info_handle());
6861 }
6862 if (cached_has_bits & 0x00000080u) {
6863 _this->_internal_mutable_buffer_crop()->::perfetto::protos::RectProto::MergeFrom(
6864 from._internal_buffer_crop());
6865 }
6866 }
6867 if (cached_has_bits & 0x0000ff00u) {
6868 if (cached_has_bits & 0x00000100u) {
6869 _this->_internal_mutable_destination_frame()->::perfetto::protos::RectProto::MergeFrom(
6870 from._internal_destination_frame());
6871 }
6872 if (cached_has_bits & 0x00000200u) {
6873 _this->_impl_.what_ = from._impl_.what_;
6874 }
6875 if (cached_has_bits & 0x00000400u) {
6876 _this->_impl_.layer_id_ = from._impl_.layer_id_;
6877 }
6878 if (cached_has_bits & 0x00000800u) {
6879 _this->_impl_.x_ = from._impl_.x_;
6880 }
6881 if (cached_has_bits & 0x00001000u) {
6882 _this->_impl_.y_ = from._impl_.y_;
6883 }
6884 if (cached_has_bits & 0x00002000u) {
6885 _this->_impl_.z_ = from._impl_.z_;
6886 }
6887 if (cached_has_bits & 0x00004000u) {
6888 _this->_impl_.w_ = from._impl_.w_;
6889 }
6890 if (cached_has_bits & 0x00008000u) {
6891 _this->_impl_.h_ = from._impl_.h_;
6892 }
6893 _this->_impl_._has_bits_[0] |= cached_has_bits;
6894 }
6895 if (cached_has_bits & 0x00ff0000u) {
6896 if (cached_has_bits & 0x00010000u) {
6897 _this->_impl_.layer_stack_ = from._impl_.layer_stack_;
6898 }
6899 if (cached_has_bits & 0x00020000u) {
6900 _this->_impl_.flags_ = from._impl_.flags_;
6901 }
6902 if (cached_has_bits & 0x00040000u) {
6903 _this->_impl_.mask_ = from._impl_.mask_;
6904 }
6905 if (cached_has_bits & 0x00080000u) {
6906 _this->_impl_.corner_radius_ = from._impl_.corner_radius_;
6907 }
6908 if (cached_has_bits & 0x00100000u) {
6909 _this->_impl_.background_blur_radius_ = from._impl_.background_blur_radius_;
6910 }
6911 if (cached_has_bits & 0x00200000u) {
6912 _this->_impl_.parent_id_ = from._impl_.parent_id_;
6913 }
6914 if (cached_has_bits & 0x00400000u) {
6915 _this->_impl_.relative_parent_id_ = from._impl_.relative_parent_id_;
6916 }
6917 if (cached_has_bits & 0x00800000u) {
6918 _this->_impl_.alpha_ = from._impl_.alpha_;
6919 }
6920 _this->_impl_._has_bits_[0] |= cached_has_bits;
6921 }
6922 if (cached_has_bits & 0xff000000u) {
6923 if (cached_has_bits & 0x01000000u) {
6924 _this->_impl_.transform_ = from._impl_.transform_;
6925 }
6926 if (cached_has_bits & 0x02000000u) {
6927 _this->_impl_.api_ = from._impl_.api_;
6928 }
6929 if (cached_has_bits & 0x04000000u) {
6930 _this->_impl_.bg_color_alpha_ = from._impl_.bg_color_alpha_;
6931 }
6932 if (cached_has_bits & 0x08000000u) {
6933 _this->_impl_.transform_to_display_inverse_ = from._impl_.transform_to_display_inverse_;
6934 }
6935 if (cached_has_bits & 0x10000000u) {
6936 _this->_impl_.has_sideband_stream_ = from._impl_.has_sideband_stream_;
6937 }
6938 if (cached_has_bits & 0x20000000u) {
6939 _this->_impl_.color_space_agnostic_ = from._impl_.color_space_agnostic_;
6940 }
6941 if (cached_has_bits & 0x40000000u) {
6942 _this->_impl_.auto_refresh_ = from._impl_.auto_refresh_;
6943 }
6944 if (cached_has_bits & 0x80000000u) {
6945 _this->_impl_.bg_color_dataspace_ = from._impl_.bg_color_dataspace_;
6946 }
6947 _this->_impl_._has_bits_[0] |= cached_has_bits;
6948 }
6949 cached_has_bits = from._impl_._has_bits_[1];
6950 if (cached_has_bits & 0x000000ffu) {
6951 if (cached_has_bits & 0x00000001u) {
6952 _this->_impl_.shadow_radius_ = from._impl_.shadow_radius_;
6953 }
6954 if (cached_has_bits & 0x00000002u) {
6955 _this->_impl_.frame_rate_selection_priority_ = from._impl_.frame_rate_selection_priority_;
6956 }
6957 if (cached_has_bits & 0x00000004u) {
6958 _this->_impl_.frame_rate_ = from._impl_.frame_rate_;
6959 }
6960 if (cached_has_bits & 0x00000008u) {
6961 _this->_impl_.frame_rate_compatibility_ = from._impl_.frame_rate_compatibility_;
6962 }
6963 if (cached_has_bits & 0x00000010u) {
6964 _this->_impl_.change_frame_rate_strategy_ = from._impl_.change_frame_rate_strategy_;
6965 }
6966 if (cached_has_bits & 0x00000020u) {
6967 _this->_impl_.frame_number_ = from._impl_.frame_number_;
6968 }
6969 if (cached_has_bits & 0x00000040u) {
6970 _this->_impl_.fixed_transform_hint_ = from._impl_.fixed_transform_hint_;
6971 }
6972 if (cached_has_bits & 0x00000080u) {
6973 _this->_impl_.is_trusted_overlay_ = from._impl_.is_trusted_overlay_;
6974 }
6975 _this->_impl_._has_bits_[1] |= cached_has_bits;
6976 }
6977 if (cached_has_bits & 0x00000300u) {
6978 if (cached_has_bits & 0x00000100u) {
6979 _this->_impl_.drop_input_mode_ = from._impl_.drop_input_mode_;
6980 }
6981 if (cached_has_bits & 0x00000200u) {
6982 _this->_impl_.trusted_overlay_ = from._impl_.trusted_overlay_;
6983 }
6984 _this->_impl_._has_bits_[1] |= cached_has_bits;
6985 }
6986 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
6987 }
6988
CopyFrom(const LayerState & from)6989 void LayerState::CopyFrom(const LayerState& from) {
6990 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.LayerState)
6991 if (&from == this) return;
6992 Clear();
6993 MergeFrom(from);
6994 }
6995
IsInitialized() const6996 bool LayerState::IsInitialized() const {
6997 return true;
6998 }
6999
InternalSwap(LayerState * other)7000 void LayerState::InternalSwap(LayerState* other) {
7001 using std::swap;
7002 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
7003 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
7004 swap(_impl_._has_bits_[1], other->_impl_._has_bits_[1]);
7005 _impl_.blur_regions_.InternalSwap(&other->_impl_.blur_regions_);
7006 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
7007 PROTOBUF_FIELD_OFFSET(LayerState, _impl_.trusted_overlay_)
7008 + sizeof(LayerState::_impl_.trusted_overlay_) // NOLINT
7009 - PROTOBUF_FIELD_OFFSET(LayerState, _impl_.matrix_)>(
7010 reinterpret_cast<char*>(&_impl_.matrix_),
7011 reinterpret_cast<char*>(&other->_impl_.matrix_));
7012 }
7013
GetTypeName() const7014 std::string LayerState::GetTypeName() const {
7015 return "perfetto.protos.LayerState";
7016 }
7017
7018
7019 // ===================================================================
7020
7021 class DisplayState::_Internal {
7022 public:
7023 using HasBits = decltype(std::declval<DisplayState>()._impl_._has_bits_);
set_has_id(HasBits * has_bits)7024 static void set_has_id(HasBits* has_bits) {
7025 (*has_bits)[0] |= 4u;
7026 }
set_has_what(HasBits * has_bits)7027 static void set_has_what(HasBits* has_bits) {
7028 (*has_bits)[0] |= 8u;
7029 }
set_has_flags(HasBits * has_bits)7030 static void set_has_flags(HasBits* has_bits) {
7031 (*has_bits)[0] |= 16u;
7032 }
set_has_layer_stack(HasBits * has_bits)7033 static void set_has_layer_stack(HasBits* has_bits) {
7034 (*has_bits)[0] |= 32u;
7035 }
set_has_orientation(HasBits * has_bits)7036 static void set_has_orientation(HasBits* has_bits) {
7037 (*has_bits)[0] |= 64u;
7038 }
7039 static const ::perfetto::protos::RectProto& layer_stack_space_rect(const DisplayState* msg);
set_has_layer_stack_space_rect(HasBits * has_bits)7040 static void set_has_layer_stack_space_rect(HasBits* has_bits) {
7041 (*has_bits)[0] |= 1u;
7042 }
7043 static const ::perfetto::protos::RectProto& oriented_display_space_rect(const DisplayState* msg);
set_has_oriented_display_space_rect(HasBits * has_bits)7044 static void set_has_oriented_display_space_rect(HasBits* has_bits) {
7045 (*has_bits)[0] |= 2u;
7046 }
set_has_width(HasBits * has_bits)7047 static void set_has_width(HasBits* has_bits) {
7048 (*has_bits)[0] |= 128u;
7049 }
set_has_height(HasBits * has_bits)7050 static void set_has_height(HasBits* has_bits) {
7051 (*has_bits)[0] |= 256u;
7052 }
7053 };
7054
7055 const ::perfetto::protos::RectProto&
layer_stack_space_rect(const DisplayState * msg)7056 DisplayState::_Internal::layer_stack_space_rect(const DisplayState* msg) {
7057 return *msg->_impl_.layer_stack_space_rect_;
7058 }
7059 const ::perfetto::protos::RectProto&
oriented_display_space_rect(const DisplayState * msg)7060 DisplayState::_Internal::oriented_display_space_rect(const DisplayState* msg) {
7061 return *msg->_impl_.oriented_display_space_rect_;
7062 }
clear_layer_stack_space_rect()7063 void DisplayState::clear_layer_stack_space_rect() {
7064 if (_impl_.layer_stack_space_rect_ != nullptr) _impl_.layer_stack_space_rect_->Clear();
7065 _impl_._has_bits_[0] &= ~0x00000001u;
7066 }
clear_oriented_display_space_rect()7067 void DisplayState::clear_oriented_display_space_rect() {
7068 if (_impl_.oriented_display_space_rect_ != nullptr) _impl_.oriented_display_space_rect_->Clear();
7069 _impl_._has_bits_[0] &= ~0x00000002u;
7070 }
DisplayState(::PROTOBUF_NAMESPACE_ID::Arena * arena,bool is_message_owned)7071 DisplayState::DisplayState(::PROTOBUF_NAMESPACE_ID::Arena* arena,
7072 bool is_message_owned)
7073 : ::PROTOBUF_NAMESPACE_ID::MessageLite(arena, is_message_owned) {
7074 SharedCtor(arena, is_message_owned);
7075 // @@protoc_insertion_point(arena_constructor:perfetto.protos.DisplayState)
7076 }
DisplayState(const DisplayState & from)7077 DisplayState::DisplayState(const DisplayState& from)
7078 : ::PROTOBUF_NAMESPACE_ID::MessageLite() {
7079 DisplayState* const _this = this; (void)_this;
7080 new (&_impl_) Impl_{
7081 decltype(_impl_._has_bits_){from._impl_._has_bits_}
7082 , /*decltype(_impl_._cached_size_)*/{}
7083 , decltype(_impl_.layer_stack_space_rect_){nullptr}
7084 , decltype(_impl_.oriented_display_space_rect_){nullptr}
7085 , decltype(_impl_.id_){}
7086 , decltype(_impl_.what_){}
7087 , decltype(_impl_.flags_){}
7088 , decltype(_impl_.layer_stack_){}
7089 , decltype(_impl_.orientation_){}
7090 , decltype(_impl_.width_){}
7091 , decltype(_impl_.height_){}};
7092
7093 _internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
7094 if (from._internal_has_layer_stack_space_rect()) {
7095 _this->_impl_.layer_stack_space_rect_ = new ::perfetto::protos::RectProto(*from._impl_.layer_stack_space_rect_);
7096 }
7097 if (from._internal_has_oriented_display_space_rect()) {
7098 _this->_impl_.oriented_display_space_rect_ = new ::perfetto::protos::RectProto(*from._impl_.oriented_display_space_rect_);
7099 }
7100 ::memcpy(&_impl_.id_, &from._impl_.id_,
7101 static_cast<size_t>(reinterpret_cast<char*>(&_impl_.height_) -
7102 reinterpret_cast<char*>(&_impl_.id_)) + sizeof(_impl_.height_));
7103 // @@protoc_insertion_point(copy_constructor:perfetto.protos.DisplayState)
7104 }
7105
SharedCtor(::_pb::Arena * arena,bool is_message_owned)7106 inline void DisplayState::SharedCtor(
7107 ::_pb::Arena* arena, bool is_message_owned) {
7108 (void)arena;
7109 (void)is_message_owned;
7110 new (&_impl_) Impl_{
7111 decltype(_impl_._has_bits_){}
7112 , /*decltype(_impl_._cached_size_)*/{}
7113 , decltype(_impl_.layer_stack_space_rect_){nullptr}
7114 , decltype(_impl_.oriented_display_space_rect_){nullptr}
7115 , decltype(_impl_.id_){0}
7116 , decltype(_impl_.what_){0u}
7117 , decltype(_impl_.flags_){0u}
7118 , decltype(_impl_.layer_stack_){0u}
7119 , decltype(_impl_.orientation_){0u}
7120 , decltype(_impl_.width_){0u}
7121 , decltype(_impl_.height_){0u}
7122 };
7123 }
7124
~DisplayState()7125 DisplayState::~DisplayState() {
7126 // @@protoc_insertion_point(destructor:perfetto.protos.DisplayState)
7127 if (auto *arena = _internal_metadata_.DeleteReturnArena<std::string>()) {
7128 (void)arena;
7129 return;
7130 }
7131 SharedDtor();
7132 }
7133
SharedDtor()7134 inline void DisplayState::SharedDtor() {
7135 GOOGLE_DCHECK(GetArenaForAllocation() == nullptr);
7136 if (this != internal_default_instance()) delete _impl_.layer_stack_space_rect_;
7137 if (this != internal_default_instance()) delete _impl_.oriented_display_space_rect_;
7138 }
7139
SetCachedSize(int size) const7140 void DisplayState::SetCachedSize(int size) const {
7141 _impl_._cached_size_.Set(size);
7142 }
7143
Clear()7144 void DisplayState::Clear() {
7145 // @@protoc_insertion_point(message_clear_start:perfetto.protos.DisplayState)
7146 ::uint32_t cached_has_bits = 0;
7147 // Prevent compiler warnings about cached_has_bits being unused
7148 (void) cached_has_bits;
7149
7150 cached_has_bits = _impl_._has_bits_[0];
7151 if (cached_has_bits & 0x00000003u) {
7152 if (cached_has_bits & 0x00000001u) {
7153 GOOGLE_DCHECK(_impl_.layer_stack_space_rect_ != nullptr);
7154 _impl_.layer_stack_space_rect_->Clear();
7155 }
7156 if (cached_has_bits & 0x00000002u) {
7157 GOOGLE_DCHECK(_impl_.oriented_display_space_rect_ != nullptr);
7158 _impl_.oriented_display_space_rect_->Clear();
7159 }
7160 }
7161 if (cached_has_bits & 0x000000fcu) {
7162 ::memset(&_impl_.id_, 0, static_cast<size_t>(
7163 reinterpret_cast<char*>(&_impl_.width_) -
7164 reinterpret_cast<char*>(&_impl_.id_)) + sizeof(_impl_.width_));
7165 }
7166 _impl_.height_ = 0u;
7167 _impl_._has_bits_.Clear();
7168 _internal_metadata_.Clear<std::string>();
7169 }
7170
_InternalParse(const char * ptr,::_pbi::ParseContext * ctx)7171 const char* DisplayState::_InternalParse(const char* ptr, ::_pbi::ParseContext* ctx) {
7172 #define CHK_(x) if (PROTOBUF_PREDICT_FALSE(!(x))) goto failure
7173 _Internal::HasBits has_bits{};
7174 while (!ctx->Done(&ptr)) {
7175 ::uint32_t tag;
7176 ptr = ::_pbi::ReadTag(ptr, &tag);
7177 switch (tag >> 3) {
7178 // optional int32 id = 1;
7179 case 1:
7180 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 8)) {
7181 _Internal::set_has_id(&has_bits);
7182 _impl_.id_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
7183 CHK_(ptr);
7184 } else {
7185 goto handle_unusual;
7186 }
7187 continue;
7188 // optional uint32 what = 2;
7189 case 2:
7190 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 16)) {
7191 _Internal::set_has_what(&has_bits);
7192 _impl_.what_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
7193 CHK_(ptr);
7194 } else {
7195 goto handle_unusual;
7196 }
7197 continue;
7198 // optional uint32 flags = 3;
7199 case 3:
7200 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 24)) {
7201 _Internal::set_has_flags(&has_bits);
7202 _impl_.flags_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
7203 CHK_(ptr);
7204 } else {
7205 goto handle_unusual;
7206 }
7207 continue;
7208 // optional uint32 layer_stack = 4;
7209 case 4:
7210 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 32)) {
7211 _Internal::set_has_layer_stack(&has_bits);
7212 _impl_.layer_stack_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
7213 CHK_(ptr);
7214 } else {
7215 goto handle_unusual;
7216 }
7217 continue;
7218 // optional uint32 orientation = 5;
7219 case 5:
7220 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 40)) {
7221 _Internal::set_has_orientation(&has_bits);
7222 _impl_.orientation_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
7223 CHK_(ptr);
7224 } else {
7225 goto handle_unusual;
7226 }
7227 continue;
7228 // optional .perfetto.protos.RectProto layer_stack_space_rect = 6;
7229 case 6:
7230 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 50)) {
7231 ptr = ctx->ParseMessage(_internal_mutable_layer_stack_space_rect(), ptr);
7232 CHK_(ptr);
7233 } else {
7234 goto handle_unusual;
7235 }
7236 continue;
7237 // optional .perfetto.protos.RectProto oriented_display_space_rect = 7;
7238 case 7:
7239 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 58)) {
7240 ptr = ctx->ParseMessage(_internal_mutable_oriented_display_space_rect(), ptr);
7241 CHK_(ptr);
7242 } else {
7243 goto handle_unusual;
7244 }
7245 continue;
7246 // optional uint32 width = 8;
7247 case 8:
7248 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 64)) {
7249 _Internal::set_has_width(&has_bits);
7250 _impl_.width_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
7251 CHK_(ptr);
7252 } else {
7253 goto handle_unusual;
7254 }
7255 continue;
7256 // optional uint32 height = 9;
7257 case 9:
7258 if (PROTOBUF_PREDICT_TRUE(static_cast<::uint8_t>(tag) == 72)) {
7259 _Internal::set_has_height(&has_bits);
7260 _impl_.height_ = ::PROTOBUF_NAMESPACE_ID::internal::ReadVarint32(&ptr);
7261 CHK_(ptr);
7262 } else {
7263 goto handle_unusual;
7264 }
7265 continue;
7266 default:
7267 goto handle_unusual;
7268 } // switch
7269 handle_unusual:
7270 if ((tag == 0) || ((tag & 7) == 4)) {
7271 CHK_(ptr);
7272 ctx->SetLastTag(tag);
7273 goto message_done;
7274 }
7275 ptr = UnknownFieldParse(
7276 tag,
7277 _internal_metadata_.mutable_unknown_fields<std::string>(),
7278 ptr, ctx);
7279 CHK_(ptr != nullptr);
7280 } // while
7281 message_done:
7282 _impl_._has_bits_.Or(has_bits);
7283 return ptr;
7284 failure:
7285 ptr = nullptr;
7286 goto message_done;
7287 #undef CHK_
7288 }
7289
_InternalSerialize(::uint8_t * target,::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream * stream) const7290 ::uint8_t* DisplayState::_InternalSerialize(
7291 ::uint8_t* target, ::PROTOBUF_NAMESPACE_ID::io::EpsCopyOutputStream* stream) const {
7292 // @@protoc_insertion_point(serialize_to_array_start:perfetto.protos.DisplayState)
7293 ::uint32_t cached_has_bits = 0;
7294 (void) cached_has_bits;
7295
7296 cached_has_bits = _impl_._has_bits_[0];
7297 // optional int32 id = 1;
7298 if (cached_has_bits & 0x00000004u) {
7299 target = stream->EnsureSpace(target);
7300 target = ::_pbi::WireFormatLite::WriteInt32ToArray(1, this->_internal_id(), target);
7301 }
7302
7303 // optional uint32 what = 2;
7304 if (cached_has_bits & 0x00000008u) {
7305 target = stream->EnsureSpace(target);
7306 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(2, this->_internal_what(), target);
7307 }
7308
7309 // optional uint32 flags = 3;
7310 if (cached_has_bits & 0x00000010u) {
7311 target = stream->EnsureSpace(target);
7312 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(3, this->_internal_flags(), target);
7313 }
7314
7315 // optional uint32 layer_stack = 4;
7316 if (cached_has_bits & 0x00000020u) {
7317 target = stream->EnsureSpace(target);
7318 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(4, this->_internal_layer_stack(), target);
7319 }
7320
7321 // optional uint32 orientation = 5;
7322 if (cached_has_bits & 0x00000040u) {
7323 target = stream->EnsureSpace(target);
7324 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(5, this->_internal_orientation(), target);
7325 }
7326
7327 // optional .perfetto.protos.RectProto layer_stack_space_rect = 6;
7328 if (cached_has_bits & 0x00000001u) {
7329 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
7330 InternalWriteMessage(6, _Internal::layer_stack_space_rect(this),
7331 _Internal::layer_stack_space_rect(this).GetCachedSize(), target, stream);
7332 }
7333
7334 // optional .perfetto.protos.RectProto oriented_display_space_rect = 7;
7335 if (cached_has_bits & 0x00000002u) {
7336 target = ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::
7337 InternalWriteMessage(7, _Internal::oriented_display_space_rect(this),
7338 _Internal::oriented_display_space_rect(this).GetCachedSize(), target, stream);
7339 }
7340
7341 // optional uint32 width = 8;
7342 if (cached_has_bits & 0x00000080u) {
7343 target = stream->EnsureSpace(target);
7344 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(8, this->_internal_width(), target);
7345 }
7346
7347 // optional uint32 height = 9;
7348 if (cached_has_bits & 0x00000100u) {
7349 target = stream->EnsureSpace(target);
7350 target = ::_pbi::WireFormatLite::WriteUInt32ToArray(9, this->_internal_height(), target);
7351 }
7352
7353 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
7354 target = stream->WriteRaw(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).data(),
7355 static_cast<int>(_internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size()), target);
7356 }
7357 // @@protoc_insertion_point(serialize_to_array_end:perfetto.protos.DisplayState)
7358 return target;
7359 }
7360
ByteSizeLong() const7361 size_t DisplayState::ByteSizeLong() const {
7362 // @@protoc_insertion_point(message_byte_size_start:perfetto.protos.DisplayState)
7363 size_t total_size = 0;
7364
7365 ::uint32_t cached_has_bits = 0;
7366 // Prevent compiler warnings about cached_has_bits being unused
7367 (void) cached_has_bits;
7368
7369 cached_has_bits = _impl_._has_bits_[0];
7370 if (cached_has_bits & 0x000000ffu) {
7371 // optional .perfetto.protos.RectProto layer_stack_space_rect = 6;
7372 if (cached_has_bits & 0x00000001u) {
7373 total_size += 1 +
7374 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
7375 *_impl_.layer_stack_space_rect_);
7376 }
7377
7378 // optional .perfetto.protos.RectProto oriented_display_space_rect = 7;
7379 if (cached_has_bits & 0x00000002u) {
7380 total_size += 1 +
7381 ::PROTOBUF_NAMESPACE_ID::internal::WireFormatLite::MessageSize(
7382 *_impl_.oriented_display_space_rect_);
7383 }
7384
7385 // optional int32 id = 1;
7386 if (cached_has_bits & 0x00000004u) {
7387 total_size += ::_pbi::WireFormatLite::Int32SizePlusOne(this->_internal_id());
7388 }
7389
7390 // optional uint32 what = 2;
7391 if (cached_has_bits & 0x00000008u) {
7392 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_what());
7393 }
7394
7395 // optional uint32 flags = 3;
7396 if (cached_has_bits & 0x00000010u) {
7397 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_flags());
7398 }
7399
7400 // optional uint32 layer_stack = 4;
7401 if (cached_has_bits & 0x00000020u) {
7402 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_layer_stack());
7403 }
7404
7405 // optional uint32 orientation = 5;
7406 if (cached_has_bits & 0x00000040u) {
7407 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_orientation());
7408 }
7409
7410 // optional uint32 width = 8;
7411 if (cached_has_bits & 0x00000080u) {
7412 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_width());
7413 }
7414
7415 }
7416 // optional uint32 height = 9;
7417 if (cached_has_bits & 0x00000100u) {
7418 total_size += ::_pbi::WireFormatLite::UInt32SizePlusOne(this->_internal_height());
7419 }
7420
7421 if (PROTOBUF_PREDICT_FALSE(_internal_metadata_.have_unknown_fields())) {
7422 total_size += _internal_metadata_.unknown_fields<std::string>(::PROTOBUF_NAMESPACE_ID::internal::GetEmptyString).size();
7423 }
7424 int cached_size = ::_pbi::ToCachedSize(total_size);
7425 SetCachedSize(cached_size);
7426 return total_size;
7427 }
7428
CheckTypeAndMergeFrom(const::PROTOBUF_NAMESPACE_ID::MessageLite & from)7429 void DisplayState::CheckTypeAndMergeFrom(
7430 const ::PROTOBUF_NAMESPACE_ID::MessageLite& from) {
7431 MergeFrom(*::_pbi::DownCast<const DisplayState*>(
7432 &from));
7433 }
7434
MergeFrom(const DisplayState & from)7435 void DisplayState::MergeFrom(const DisplayState& from) {
7436 DisplayState* const _this = this;
7437 // @@protoc_insertion_point(class_specific_merge_from_start:perfetto.protos.DisplayState)
7438 GOOGLE_DCHECK_NE(&from, _this);
7439 ::uint32_t cached_has_bits = 0;
7440 (void) cached_has_bits;
7441
7442 cached_has_bits = from._impl_._has_bits_[0];
7443 if (cached_has_bits & 0x000000ffu) {
7444 if (cached_has_bits & 0x00000001u) {
7445 _this->_internal_mutable_layer_stack_space_rect()->::perfetto::protos::RectProto::MergeFrom(
7446 from._internal_layer_stack_space_rect());
7447 }
7448 if (cached_has_bits & 0x00000002u) {
7449 _this->_internal_mutable_oriented_display_space_rect()->::perfetto::protos::RectProto::MergeFrom(
7450 from._internal_oriented_display_space_rect());
7451 }
7452 if (cached_has_bits & 0x00000004u) {
7453 _this->_impl_.id_ = from._impl_.id_;
7454 }
7455 if (cached_has_bits & 0x00000008u) {
7456 _this->_impl_.what_ = from._impl_.what_;
7457 }
7458 if (cached_has_bits & 0x00000010u) {
7459 _this->_impl_.flags_ = from._impl_.flags_;
7460 }
7461 if (cached_has_bits & 0x00000020u) {
7462 _this->_impl_.layer_stack_ = from._impl_.layer_stack_;
7463 }
7464 if (cached_has_bits & 0x00000040u) {
7465 _this->_impl_.orientation_ = from._impl_.orientation_;
7466 }
7467 if (cached_has_bits & 0x00000080u) {
7468 _this->_impl_.width_ = from._impl_.width_;
7469 }
7470 _this->_impl_._has_bits_[0] |= cached_has_bits;
7471 }
7472 if (cached_has_bits & 0x00000100u) {
7473 _this->_internal_set_height(from._internal_height());
7474 }
7475 _this->_internal_metadata_.MergeFrom<std::string>(from._internal_metadata_);
7476 }
7477
CopyFrom(const DisplayState & from)7478 void DisplayState::CopyFrom(const DisplayState& from) {
7479 // @@protoc_insertion_point(class_specific_copy_from_start:perfetto.protos.DisplayState)
7480 if (&from == this) return;
7481 Clear();
7482 MergeFrom(from);
7483 }
7484
IsInitialized() const7485 bool DisplayState::IsInitialized() const {
7486 return true;
7487 }
7488
InternalSwap(DisplayState * other)7489 void DisplayState::InternalSwap(DisplayState* other) {
7490 using std::swap;
7491 _internal_metadata_.InternalSwap(&other->_internal_metadata_);
7492 swap(_impl_._has_bits_[0], other->_impl_._has_bits_[0]);
7493 ::PROTOBUF_NAMESPACE_ID::internal::memswap<
7494 PROTOBUF_FIELD_OFFSET(DisplayState, _impl_.height_)
7495 + sizeof(DisplayState::_impl_.height_) // NOLINT
7496 - PROTOBUF_FIELD_OFFSET(DisplayState, _impl_.layer_stack_space_rect_)>(
7497 reinterpret_cast<char*>(&_impl_.layer_stack_space_rect_),
7498 reinterpret_cast<char*>(&other->_impl_.layer_stack_space_rect_));
7499 }
7500
GetTypeName() const7501 std::string DisplayState::GetTypeName() const {
7502 return "perfetto.protos.DisplayState";
7503 }
7504
7505
7506 // @@protoc_insertion_point(namespace_scope)
7507 } // namespace protos
7508 } // namespace perfetto
7509 PROTOBUF_NAMESPACE_OPEN
7510 template<> PROTOBUF_NOINLINE ::perfetto::protos::TransactionTraceFile*
CreateMaybeMessage(Arena * arena)7511 Arena::CreateMaybeMessage< ::perfetto::protos::TransactionTraceFile >(Arena* arena) {
7512 return Arena::CreateMessageInternal< ::perfetto::protos::TransactionTraceFile >(arena);
7513 }
7514 template<> PROTOBUF_NOINLINE ::perfetto::protos::TransactionTraceEntry*
CreateMaybeMessage(Arena * arena)7515 Arena::CreateMaybeMessage< ::perfetto::protos::TransactionTraceEntry >(Arena* arena) {
7516 return Arena::CreateMessageInternal< ::perfetto::protos::TransactionTraceEntry >(arena);
7517 }
7518 template<> PROTOBUF_NOINLINE ::perfetto::protos::DisplayInfo*
CreateMaybeMessage(Arena * arena)7519 Arena::CreateMaybeMessage< ::perfetto::protos::DisplayInfo >(Arena* arena) {
7520 return Arena::CreateMessageInternal< ::perfetto::protos::DisplayInfo >(arena);
7521 }
7522 template<> PROTOBUF_NOINLINE ::perfetto::protos::LayerCreationArgs*
CreateMaybeMessage(Arena * arena)7523 Arena::CreateMaybeMessage< ::perfetto::protos::LayerCreationArgs >(Arena* arena) {
7524 return Arena::CreateMessageInternal< ::perfetto::protos::LayerCreationArgs >(arena);
7525 }
7526 template<> PROTOBUF_NOINLINE ::perfetto::protos::Transform*
CreateMaybeMessage(Arena * arena)7527 Arena::CreateMaybeMessage< ::perfetto::protos::Transform >(Arena* arena) {
7528 return Arena::CreateMessageInternal< ::perfetto::protos::Transform >(arena);
7529 }
7530 template<> PROTOBUF_NOINLINE ::perfetto::protos::TransactionState*
CreateMaybeMessage(Arena * arena)7531 Arena::CreateMaybeMessage< ::perfetto::protos::TransactionState >(Arena* arena) {
7532 return Arena::CreateMessageInternal< ::perfetto::protos::TransactionState >(arena);
7533 }
7534 template<> PROTOBUF_NOINLINE ::perfetto::protos::LayerState_Matrix22*
CreateMaybeMessage(Arena * arena)7535 Arena::CreateMaybeMessage< ::perfetto::protos::LayerState_Matrix22 >(Arena* arena) {
7536 return Arena::CreateMessageInternal< ::perfetto::protos::LayerState_Matrix22 >(arena);
7537 }
7538 template<> PROTOBUF_NOINLINE ::perfetto::protos::LayerState_Color3*
CreateMaybeMessage(Arena * arena)7539 Arena::CreateMaybeMessage< ::perfetto::protos::LayerState_Color3 >(Arena* arena) {
7540 return Arena::CreateMessageInternal< ::perfetto::protos::LayerState_Color3 >(arena);
7541 }
7542 template<> PROTOBUF_NOINLINE ::perfetto::protos::LayerState_BufferData*
CreateMaybeMessage(Arena * arena)7543 Arena::CreateMaybeMessage< ::perfetto::protos::LayerState_BufferData >(Arena* arena) {
7544 return Arena::CreateMessageInternal< ::perfetto::protos::LayerState_BufferData >(arena);
7545 }
7546 template<> PROTOBUF_NOINLINE ::perfetto::protos::LayerState_WindowInfo*
CreateMaybeMessage(Arena * arena)7547 Arena::CreateMaybeMessage< ::perfetto::protos::LayerState_WindowInfo >(Arena* arena) {
7548 return Arena::CreateMessageInternal< ::perfetto::protos::LayerState_WindowInfo >(arena);
7549 }
7550 template<> PROTOBUF_NOINLINE ::perfetto::protos::LayerState*
CreateMaybeMessage(Arena * arena)7551 Arena::CreateMaybeMessage< ::perfetto::protos::LayerState >(Arena* arena) {
7552 return Arena::CreateMessageInternal< ::perfetto::protos::LayerState >(arena);
7553 }
7554 template<> PROTOBUF_NOINLINE ::perfetto::protos::DisplayState*
CreateMaybeMessage(Arena * arena)7555 Arena::CreateMaybeMessage< ::perfetto::protos::DisplayState >(Arena* arena) {
7556 return Arena::CreateMessageInternal< ::perfetto::protos::DisplayState >(arena);
7557 }
7558 PROTOBUF_NAMESPACE_CLOSE
7559
7560 // @@protoc_insertion_point(global_scope)
7561 #include <google/protobuf/port_undef.inc>
7562