Line data Source code
1 : //
2 : // Automatically generated by ipdlc.
3 : // Edit at your own risk
4 : //
5 :
6 :
7 : #include "mozilla/dom/PVideoDecoderManagerParent.h"
8 : #include "mozilla/layers/CompositorTypes.h"
9 : #ifdef MOZ_CRASHREPORTER
10 : # include "nsXULAppAPI.h"
11 : #endif
12 :
13 : #include "mozilla/layers/PTextureParent.h"
14 : #include "mozilla/dom/PVideoDecoderParent.h"
15 :
16 : #include "nsIFile.h"
17 : #include "GeckoProfiler.h"
18 :
19 : namespace mozilla {
20 : namespace dom {
21 :
22 :
23 0 : auto PVideoDecoderManagerParent::RecvPVideoDecoderConstructor(
24 : PVideoDecoderParent* actor,
25 : const VideoInfo& info,
26 : const TextureFactoryIdentifier& identifier,
27 : bool* success) -> mozilla::ipc::IPCResult
28 : {
29 0 : return IPC_OK();
30 : }
31 :
32 :
33 0 : auto PVideoDecoderManagerParent::ProcessingError(
34 : Result aCode,
35 : const char* aReason) -> void
36 : {
37 0 : }
38 :
39 0 : auto PVideoDecoderManagerParent::ShouldContinueFromReplyTimeout() -> bool
40 : {
41 0 : return true;
42 : }
43 :
44 0 : auto PVideoDecoderManagerParent::EnteredCxxStack() -> void
45 : {
46 0 : }
47 :
48 0 : auto PVideoDecoderManagerParent::ExitedCxxStack() -> void
49 : {
50 0 : }
51 :
52 0 : auto PVideoDecoderManagerParent::EnteredCall() -> void
53 : {
54 0 : }
55 :
56 0 : auto PVideoDecoderManagerParent::ExitedCall() -> void
57 : {
58 0 : }
59 :
60 0 : MOZ_IMPLICIT PVideoDecoderManagerParent::PVideoDecoderManagerParent() :
61 : mozilla::ipc::IToplevelProtocol(PVideoDecoderManagerMsgStart, mozilla::ipc::ParentSide),
62 : mChannel("PVideoDecoderManagerParent", ALLOW_THIS_IN_INITIALIZER_LIST(this)),
63 0 : mState(PVideoDecoderManager::__Start)
64 : {
65 0 : MOZ_COUNT_CTOR(PVideoDecoderManagerParent);
66 0 : }
67 :
68 0 : PVideoDecoderManagerParent::~PVideoDecoderManagerParent()
69 : {
70 0 : MOZ_COUNT_DTOR(PVideoDecoderManagerParent);
71 0 : }
72 :
73 0 : auto PVideoDecoderManagerParent::ManagedPVideoDecoderParent(nsTArray<PVideoDecoderParent*>& aArr) const -> void
74 : {
75 0 : (mManagedPVideoDecoderParent).ToArray(aArr);
76 0 : }
77 :
78 0 : auto PVideoDecoderManagerParent::ManagedPVideoDecoderParent() const -> const ManagedContainer<PVideoDecoderParent>&
79 : {
80 0 : return mManagedPVideoDecoderParent;
81 : }
82 :
83 0 : auto PVideoDecoderManagerParent::GetIPCChannel() -> MessageChannel*
84 : {
85 0 : return (&(mChannel));
86 : }
87 :
88 0 : auto PVideoDecoderManagerParent::GetIPCChannel() const -> const MessageChannel*
89 : {
90 0 : return (&(mChannel));
91 : }
92 :
93 0 : auto PVideoDecoderManagerParent::RemoveManagee(
94 : int32_t aProtocolId,
95 : ProtocolBase* aListener) -> void
96 : {
97 0 : switch (aProtocolId) {
98 : case PVideoDecoderMsgStart:
99 : {
100 0 : PVideoDecoderParent* actor = static_cast<PVideoDecoderParent*>(aListener);
101 0 : auto& container = mManagedPVideoDecoderParent;
102 0 : MOZ_RELEASE_ASSERT((container).Contains(actor), "actor not managed by this!");
103 :
104 0 : (container).RemoveEntry(actor);
105 0 : DeallocPVideoDecoderParent(actor);
106 0 : return;
107 : }
108 : default:
109 : {
110 0 : FatalError("unreached");
111 0 : return;
112 : }
113 : }
114 : }
115 :
116 0 : auto PVideoDecoderManagerParent::OnMessageReceived(const Message& msg__) -> PVideoDecoderManagerParent::Result
117 : {
118 0 : int32_t route__ = (msg__).routing_id();
119 0 : if ((MSG_ROUTING_CONTROL) != (route__)) {
120 0 : ChannelListener* routed__ = Lookup(route__);
121 0 : if ((!(routed__))) {
122 0 : return MsgRouteError;
123 : }
124 0 : return (routed__)->OnMessageReceived(msg__);
125 : }
126 :
127 0 : switch ((msg__).type()) {
128 : case PVideoDecoderManager::Msg_DeallocateSurfaceDescriptorGPUVideo__ID:
129 : {
130 0 : if (mozilla::ipc::LoggingEnabledFor("PVideoDecoderManagerParent")) {
131 0 : mozilla::ipc::LogMessageForProtocol("PVideoDecoderManagerParent", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
132 : }
133 0 : AUTO_PROFILER_LABEL("PVideoDecoderManager::Msg_DeallocateSurfaceDescriptorGPUVideo", OTHER);
134 :
135 0 : PickleIterator iter__(msg__);
136 0 : SurfaceDescriptorGPUVideo sd;
137 :
138 0 : if ((!(Read((&(sd)), (&(msg__)), (&(iter__)))))) {
139 0 : FatalError("Error deserializing 'SurfaceDescriptorGPUVideo'");
140 0 : return MsgValueError;
141 : }
142 : // Sentinel = 'sd'
143 0 : if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2856126975)))) {
144 0 : mozilla::ipc::SentinelReadError("Error deserializing 'SurfaceDescriptorGPUVideo'");
145 0 : return MsgValueError;
146 : }
147 0 : (msg__).EndRead(iter__, (msg__).type());
148 0 : PVideoDecoderManager::Transition(PVideoDecoderManager::Msg_DeallocateSurfaceDescriptorGPUVideo__ID, (&(mState)));
149 0 : if ((!(RecvDeallocateSurfaceDescriptorGPUVideo(mozilla::Move(sd))))) {
150 0 : mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
151 : // Error handled in mozilla::ipc::IPCResult
152 0 : return MsgProcessingError;
153 : }
154 :
155 0 : return MsgProcessed;
156 : }
157 : default:
158 : {
159 0 : return MsgNotKnown;
160 : }
161 : case SHMEM_CREATED_MESSAGE_TYPE:
162 : {
163 0 : if ((!(ShmemCreated(msg__)))) {
164 0 : return MsgPayloadError;
165 : }
166 0 : return MsgProcessed;
167 : }
168 : case SHMEM_DESTROYED_MESSAGE_TYPE:
169 : {
170 0 : if ((!(ShmemDestroyed(msg__)))) {
171 0 : return MsgPayloadError;
172 : }
173 0 : return MsgProcessed;
174 : }
175 : }
176 : }
177 :
178 0 : auto PVideoDecoderManagerParent::OnMessageReceived(
179 : const Message& msg__,
180 : Message*& reply__) -> PVideoDecoderManagerParent::Result
181 : {
182 0 : int32_t route__ = (msg__).routing_id();
183 0 : if ((MSG_ROUTING_CONTROL) != (route__)) {
184 0 : ChannelListener* routed__ = Lookup(route__);
185 0 : if ((!(routed__))) {
186 0 : return MsgRouteError;
187 : }
188 0 : return (routed__)->OnMessageReceived(msg__, reply__);
189 : }
190 :
191 0 : switch ((msg__).type()) {
192 : case PVideoDecoderManager::Msg_PVideoDecoderConstructor__ID:
193 : {
194 0 : if (mozilla::ipc::LoggingEnabledFor("PVideoDecoderManagerParent")) {
195 0 : mozilla::ipc::LogMessageForProtocol("PVideoDecoderManagerParent", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
196 : }
197 0 : AUTO_PROFILER_LABEL("PVideoDecoderManager::Msg_PVideoDecoderConstructor", OTHER);
198 :
199 0 : PickleIterator iter__(msg__);
200 : ActorHandle handle__;
201 : PVideoDecoderParent* actor;
202 0 : VideoInfo info;
203 0 : TextureFactoryIdentifier identifier;
204 :
205 0 : if ((!(Read((&(handle__)), (&(msg__)), (&(iter__)))))) {
206 0 : FatalError("Error deserializing 'ActorHandle'");
207 0 : return MsgValueError;
208 : }
209 : // Sentinel = 'actor'
210 0 : if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 875202478)))) {
211 0 : mozilla::ipc::SentinelReadError("Error deserializing 'ActorHandle'");
212 0 : return MsgValueError;
213 : }
214 0 : if ((!(Read((&(info)), (&(msg__)), (&(iter__)))))) {
215 0 : FatalError("Error deserializing 'VideoInfo'");
216 0 : return MsgValueError;
217 : }
218 : // Sentinel = 'info'
219 0 : if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3750868832)))) {
220 0 : mozilla::ipc::SentinelReadError("Error deserializing 'VideoInfo'");
221 0 : return MsgValueError;
222 : }
223 0 : if ((!(Read((&(identifier)), (&(msg__)), (&(iter__)))))) {
224 0 : FatalError("Error deserializing 'TextureFactoryIdentifier'");
225 0 : return MsgValueError;
226 : }
227 : // Sentinel = 'identifier'
228 0 : if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2916735611)))) {
229 0 : mozilla::ipc::SentinelReadError("Error deserializing 'TextureFactoryIdentifier'");
230 0 : return MsgValueError;
231 : }
232 0 : (msg__).EndRead(iter__, (msg__).type());
233 0 : PVideoDecoderManager::Transition(PVideoDecoderManager::Msg_PVideoDecoderConstructor__ID, (&(mState)));
234 : bool success;
235 0 : actor = AllocPVideoDecoderParent(info, identifier, (&(success)));
236 0 : if ((!(actor))) {
237 0 : NS_WARNING("Error constructing actor PVideoDecoderParent");
238 0 : return MsgValueError;
239 : }
240 0 : (actor)->SetManager(this);
241 0 : RegisterID(actor, (handle__).mId);
242 0 : (actor)->SetIPCChannel(GetIPCChannel());
243 0 : (mManagedPVideoDecoderParent).PutEntry(actor);
244 0 : (actor)->mState = mozilla::dom::PVideoDecoder::__Start;
245 :
246 0 : int32_t id__ = MSG_ROUTING_CONTROL;
247 0 : if ((!(RecvPVideoDecoderConstructor(mozilla::Move(actor), mozilla::Move(info), mozilla::Move(identifier), (&(success)))))) {
248 0 : mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
249 : // Error handled in mozilla::ipc::IPCResult
250 0 : return MsgProcessingError;
251 : }
252 0 : reply__ = PVideoDecoderManager::Reply_PVideoDecoderConstructor(id__);
253 :
254 0 : Write(success, reply__);
255 : // Sentinel = 'success'
256 0 : (reply__)->WriteSentinel(3877396070);
257 0 : (reply__)->set_sync();
258 0 : (reply__)->set_constructor();
259 0 : (reply__)->set_reply();
260 :
261 0 : if (mozilla::ipc::LoggingEnabledFor("PVideoDecoderManagerParent")) {
262 0 : mozilla::ipc::LogMessageForProtocol("PVideoDecoderManagerParent", OtherPid(), "Sending reply ", (reply__)->type(), mozilla::ipc::MessageDirection::eSending);
263 : }
264 :
265 0 : return MsgProcessed;
266 : }
267 : case PVideoDecoderManager::Msg_Readback__ID:
268 : {
269 0 : if (mozilla::ipc::LoggingEnabledFor("PVideoDecoderManagerParent")) {
270 0 : mozilla::ipc::LogMessageForProtocol("PVideoDecoderManagerParent", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
271 : }
272 0 : AUTO_PROFILER_LABEL("PVideoDecoderManager::Msg_Readback", OTHER);
273 :
274 0 : PickleIterator iter__(msg__);
275 0 : SurfaceDescriptorGPUVideo sd;
276 :
277 0 : if ((!(Read((&(sd)), (&(msg__)), (&(iter__)))))) {
278 0 : FatalError("Error deserializing 'SurfaceDescriptorGPUVideo'");
279 0 : return MsgValueError;
280 : }
281 : // Sentinel = 'sd'
282 0 : if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2856126975)))) {
283 0 : mozilla::ipc::SentinelReadError("Error deserializing 'SurfaceDescriptorGPUVideo'");
284 0 : return MsgValueError;
285 : }
286 0 : (msg__).EndRead(iter__, (msg__).type());
287 0 : PVideoDecoderManager::Transition(PVideoDecoderManager::Msg_Readback__ID, (&(mState)));
288 0 : int32_t id__ = MSG_ROUTING_CONTROL;
289 0 : SurfaceDescriptor aResult;
290 0 : if ((!(RecvReadback(mozilla::Move(sd), (&(aResult)))))) {
291 0 : mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
292 : // Error handled in mozilla::ipc::IPCResult
293 0 : return MsgProcessingError;
294 : }
295 :
296 0 : reply__ = PVideoDecoderManager::Reply_Readback(id__);
297 :
298 0 : Write(aResult, reply__);
299 : // Sentinel = 'aResult'
300 0 : (reply__)->WriteSentinel(3888726089);
301 0 : (reply__)->set_sync();
302 0 : (reply__)->set_reply();
303 :
304 0 : if (mozilla::ipc::LoggingEnabledFor("PVideoDecoderManagerParent")) {
305 0 : mozilla::ipc::LogMessageForProtocol("PVideoDecoderManagerParent", OtherPid(), "Sending reply ", (reply__)->type(), mozilla::ipc::MessageDirection::eSending);
306 : }
307 0 : return MsgProcessed;
308 : }
309 : default:
310 : {
311 0 : return MsgNotKnown;
312 : }
313 : }
314 : }
315 :
316 0 : auto PVideoDecoderManagerParent::OnCallReceived(
317 : const Message& msg__,
318 : Message*& reply__) -> PVideoDecoderManagerParent::Result
319 : {
320 0 : MOZ_ASSERT_UNREACHABLE("message protocol not supported");
321 : return MsgNotKnown;
322 : }
323 :
324 0 : auto PVideoDecoderManagerParent::GetProtocolTypeId() -> int32_t
325 : {
326 0 : return PVideoDecoderManagerMsgStart;
327 : }
328 :
329 0 : auto PVideoDecoderManagerParent::OnChannelClose() -> void
330 : {
331 0 : DestroySubtree(NormalShutdown);
332 0 : DeallocSubtree();
333 0 : DeallocShmems();
334 0 : DeallocPVideoDecoderManagerParent();
335 0 : }
336 :
337 0 : auto PVideoDecoderManagerParent::OnChannelError() -> void
338 : {
339 0 : DestroySubtree(AbnormalShutdown);
340 0 : DeallocSubtree();
341 0 : DeallocShmems();
342 0 : DeallocPVideoDecoderManagerParent();
343 0 : }
344 :
345 0 : auto PVideoDecoderManagerParent::ProtocolName() const -> const char*
346 : {
347 0 : return "PVideoDecoderManagerParent";
348 : }
349 :
350 0 : auto PVideoDecoderManagerParent::DestroySubtree(ActorDestroyReason why) -> void
351 : {
352 0 : ActorDestroyReason subtreewhy = (((why) == (Deletion)) || ((why) == (FailedConstructor)) ? AncestorDeletion : why);
353 :
354 : {
355 : // Recursively shutting down PVideoDecoder kids
356 0 : nsTArray<PVideoDecoderParent*> kids;
357 : // Accumulate kids into a stable structure to iterate over
358 0 : ManagedPVideoDecoderParent(kids);
359 0 : for (auto& kid : kids) {
360 : // Guarding against a child removing a sibling from the list during the iteration.
361 0 : if ((mManagedPVideoDecoderParent).Contains(kid)) {
362 0 : (kid)->DestroySubtree(subtreewhy);
363 : }
364 : }
365 : }
366 :
367 : // Reject owning pending promises.
368 0 : (GetIPCChannel())->RejectPendingPromisesForActor(this);
369 :
370 : // Finally, destroy "us".
371 0 : ActorDestroy(why);
372 0 : }
373 :
374 0 : auto PVideoDecoderManagerParent::DeallocSubtree() -> void
375 : {
376 : {
377 : // Recursively deleting PVideoDecoder kids
378 0 : for (auto iter = (mManagedPVideoDecoderParent).Iter(); (!((iter).Done())); (iter).Next()) {
379 0 : (((iter).Get())->GetKey())->DeallocSubtree();
380 : }
381 :
382 0 : for (auto iter = (mManagedPVideoDecoderParent).Iter(); (!((iter).Done())); (iter).Next()) {
383 0 : DeallocPVideoDecoderParent(((iter).Get())->GetKey());
384 : }
385 0 : (mManagedPVideoDecoderParent).Clear();
386 : }
387 0 : }
388 :
389 0 : auto PVideoDecoderManagerParent::DeallocPVideoDecoderManagerParent() -> void
390 : {
391 0 : }
392 :
393 0 : auto PVideoDecoderManagerParent::Write(
394 : const EGLImageDescriptor& v__,
395 : Message* msg__) -> void
396 : {
397 0 : Write((v__).image(), msg__);
398 : // Sentinel = 'image'
399 0 : (msg__)->WriteSentinel(103190282);
400 0 : Write((v__).fence(), msg__);
401 : // Sentinel = 'fence'
402 0 : (msg__)->WriteSentinel(1225633926);
403 0 : Write((v__).size(), msg__);
404 : // Sentinel = 'size'
405 0 : (msg__)->WriteSentinel(931048223);
406 0 : Write((v__).hasAlpha(), msg__);
407 : // Sentinel = 'hasAlpha'
408 0 : (msg__)->WriteSentinel(309498444);
409 0 : }
410 :
411 0 : auto PVideoDecoderManagerParent::Read(
412 : EGLImageDescriptor* v__,
413 : const Message* msg__,
414 : PickleIterator* iter__) -> bool
415 : {
416 0 : if ((!(Read((&((v__)->image())), msg__, iter__)))) {
417 0 : FatalError("Error deserializing 'image' (uintptr_t) member of 'EGLImageDescriptor'");
418 0 : return false;
419 : }
420 : // Sentinel = 'image'
421 0 : if ((!((msg__)->ReadSentinel(iter__, 103190282)))) {
422 0 : mozilla::ipc::SentinelReadError("Error deserializing 'image' (uintptr_t) member of 'EGLImageDescriptor'");
423 0 : return false;
424 : }
425 0 : if ((!(Read((&((v__)->fence())), msg__, iter__)))) {
426 0 : FatalError("Error deserializing 'fence' (uintptr_t) member of 'EGLImageDescriptor'");
427 0 : return false;
428 : }
429 : // Sentinel = 'fence'
430 0 : if ((!((msg__)->ReadSentinel(iter__, 1225633926)))) {
431 0 : mozilla::ipc::SentinelReadError("Error deserializing 'fence' (uintptr_t) member of 'EGLImageDescriptor'");
432 0 : return false;
433 : }
434 0 : if ((!(Read((&((v__)->size())), msg__, iter__)))) {
435 0 : FatalError("Error deserializing 'size' (IntSize) member of 'EGLImageDescriptor'");
436 0 : return false;
437 : }
438 : // Sentinel = 'size'
439 0 : if ((!((msg__)->ReadSentinel(iter__, 931048223)))) {
440 0 : mozilla::ipc::SentinelReadError("Error deserializing 'size' (IntSize) member of 'EGLImageDescriptor'");
441 0 : return false;
442 : }
443 0 : if ((!(Read((&((v__)->hasAlpha())), msg__, iter__)))) {
444 0 : FatalError("Error deserializing 'hasAlpha' (bool) member of 'EGLImageDescriptor'");
445 0 : return false;
446 : }
447 : // Sentinel = 'hasAlpha'
448 0 : if ((!((msg__)->ReadSentinel(iter__, 309498444)))) {
449 0 : mozilla::ipc::SentinelReadError("Error deserializing 'hasAlpha' (bool) member of 'EGLImageDescriptor'");
450 0 : return false;
451 : }
452 0 : return true;
453 : }
454 :
455 0 : auto PVideoDecoderManagerParent::Write(
456 : const SurfaceDescriptor& v__,
457 : Message* msg__) -> void
458 : {
459 : typedef SurfaceDescriptor type__;
460 0 : Write(int((v__).type()), msg__);
461 : // Sentinel = 'SurfaceDescriptor'
462 0 : (msg__)->WriteSentinel(1058499359);
463 :
464 0 : switch ((v__).type()) {
465 : case type__::TSurfaceDescriptorBuffer:
466 : {
467 0 : Write((v__).get_SurfaceDescriptorBuffer(), msg__);
468 : // Sentinel = 'TSurfaceDescriptorBuffer'
469 0 : (msg__)->WriteSentinel(2202696360);
470 0 : return;
471 : }
472 : case type__::TSurfaceDescriptorDIB:
473 : {
474 0 : Write((v__).get_SurfaceDescriptorDIB(), msg__);
475 : // Sentinel = 'TSurfaceDescriptorDIB'
476 0 : (msg__)->WriteSentinel(998410538);
477 0 : return;
478 : }
479 : case type__::TSurfaceDescriptorD3D10:
480 : {
481 0 : Write((v__).get_SurfaceDescriptorD3D10(), msg__);
482 : // Sentinel = 'TSurfaceDescriptorD3D10'
483 0 : (msg__)->WriteSentinel(2753564567);
484 0 : return;
485 : }
486 : case type__::TSurfaceDescriptorFileMapping:
487 : {
488 0 : Write((v__).get_SurfaceDescriptorFileMapping(), msg__);
489 : // Sentinel = 'TSurfaceDescriptorFileMapping'
490 0 : (msg__)->WriteSentinel(722196935);
491 0 : return;
492 : }
493 : case type__::TSurfaceDescriptorDXGIYCbCr:
494 : {
495 0 : Write((v__).get_SurfaceDescriptorDXGIYCbCr(), msg__);
496 : // Sentinel = 'TSurfaceDescriptorDXGIYCbCr'
497 0 : (msg__)->WriteSentinel(3061212892);
498 0 : return;
499 : }
500 : case type__::TSurfaceDescriptorX11:
501 : {
502 0 : Write((v__).get_SurfaceDescriptorX11(), msg__);
503 : // Sentinel = 'TSurfaceDescriptorX11'
504 0 : (msg__)->WriteSentinel(3923930613);
505 0 : return;
506 : }
507 : case type__::TSurfaceTextureDescriptor:
508 : {
509 0 : Write((v__).get_SurfaceTextureDescriptor(), msg__);
510 : // Sentinel = 'TSurfaceTextureDescriptor'
511 0 : (msg__)->WriteSentinel(2253946800);
512 0 : return;
513 : }
514 : case type__::TEGLImageDescriptor:
515 : {
516 0 : Write((v__).get_EGLImageDescriptor(), msg__);
517 : // Sentinel = 'TEGLImageDescriptor'
518 0 : (msg__)->WriteSentinel(2680446099);
519 0 : return;
520 : }
521 : case type__::TSurfaceDescriptorMacIOSurface:
522 : {
523 0 : Write((v__).get_SurfaceDescriptorMacIOSurface(), msg__);
524 : // Sentinel = 'TSurfaceDescriptorMacIOSurface'
525 0 : (msg__)->WriteSentinel(4267688786);
526 0 : return;
527 : }
528 : case type__::TSurfaceDescriptorSharedGLTexture:
529 : {
530 0 : Write((v__).get_SurfaceDescriptorSharedGLTexture(), msg__);
531 : // Sentinel = 'TSurfaceDescriptorSharedGLTexture'
532 0 : (msg__)->WriteSentinel(4169514976);
533 0 : return;
534 : }
535 : case type__::TSurfaceDescriptorGPUVideo:
536 : {
537 0 : Write((v__).get_SurfaceDescriptorGPUVideo(), msg__);
538 : // Sentinel = 'TSurfaceDescriptorGPUVideo'
539 0 : (msg__)->WriteSentinel(2406892431);
540 0 : return;
541 : }
542 : case type__::Tnull_t:
543 : {
544 0 : Write((v__).get_null_t(), msg__);
545 : // Sentinel = 'Tnull_t'
546 0 : (msg__)->WriteSentinel(3731137201);
547 0 : return;
548 : }
549 : default:
550 : {
551 0 : FatalError("unknown union type");
552 0 : return;
553 : }
554 : }
555 : }
556 :
557 0 : auto PVideoDecoderManagerParent::Read(
558 : SurfaceDescriptor* v__,
559 : const Message* msg__,
560 : PickleIterator* iter__) -> bool
561 : {
562 : typedef SurfaceDescriptor type__;
563 : int type;
564 0 : if ((!(Read((&(type)), msg__, iter__)))) {
565 0 : mozilla::ipc::UnionTypeReadError("SurfaceDescriptor");
566 0 : return false;
567 : }
568 : // Sentinel = 'SurfaceDescriptor'
569 0 : if ((!((msg__)->ReadSentinel(iter__, 1058499359)))) {
570 0 : mozilla::ipc::SentinelReadError("SurfaceDescriptor");
571 0 : return false;
572 : }
573 :
574 0 : switch (type) {
575 : case type__::TSurfaceDescriptorBuffer:
576 : {
577 0 : SurfaceDescriptorBuffer tmp = SurfaceDescriptorBuffer();
578 0 : (*(v__)) = tmp;
579 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorBuffer())), msg__, iter__)))) {
580 0 : FatalError("Error deserializing Union type");
581 0 : return false;
582 : }
583 : // Sentinel = 'TSurfaceDescriptorBuffer'
584 0 : if ((!((msg__)->ReadSentinel(iter__, 2202696360)))) {
585 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
586 0 : return false;
587 : }
588 0 : return true;
589 : }
590 : case type__::TSurfaceDescriptorDIB:
591 : {
592 0 : SurfaceDescriptorDIB tmp = SurfaceDescriptorDIB();
593 0 : (*(v__)) = tmp;
594 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorDIB())), msg__, iter__)))) {
595 0 : FatalError("Error deserializing Union type");
596 0 : return false;
597 : }
598 : // Sentinel = 'TSurfaceDescriptorDIB'
599 0 : if ((!((msg__)->ReadSentinel(iter__, 998410538)))) {
600 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
601 0 : return false;
602 : }
603 0 : return true;
604 : }
605 : case type__::TSurfaceDescriptorD3D10:
606 : {
607 0 : SurfaceDescriptorD3D10 tmp = SurfaceDescriptorD3D10();
608 0 : (*(v__)) = tmp;
609 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorD3D10())), msg__, iter__)))) {
610 0 : FatalError("Error deserializing Union type");
611 0 : return false;
612 : }
613 : // Sentinel = 'TSurfaceDescriptorD3D10'
614 0 : if ((!((msg__)->ReadSentinel(iter__, 2753564567)))) {
615 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
616 0 : return false;
617 : }
618 0 : return true;
619 : }
620 : case type__::TSurfaceDescriptorFileMapping:
621 : {
622 0 : SurfaceDescriptorFileMapping tmp = SurfaceDescriptorFileMapping();
623 0 : (*(v__)) = tmp;
624 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorFileMapping())), msg__, iter__)))) {
625 0 : FatalError("Error deserializing Union type");
626 0 : return false;
627 : }
628 : // Sentinel = 'TSurfaceDescriptorFileMapping'
629 0 : if ((!((msg__)->ReadSentinel(iter__, 722196935)))) {
630 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
631 0 : return false;
632 : }
633 0 : return true;
634 : }
635 : case type__::TSurfaceDescriptorDXGIYCbCr:
636 : {
637 0 : SurfaceDescriptorDXGIYCbCr tmp = SurfaceDescriptorDXGIYCbCr();
638 0 : (*(v__)) = tmp;
639 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorDXGIYCbCr())), msg__, iter__)))) {
640 0 : FatalError("Error deserializing Union type");
641 0 : return false;
642 : }
643 : // Sentinel = 'TSurfaceDescriptorDXGIYCbCr'
644 0 : if ((!((msg__)->ReadSentinel(iter__, 3061212892)))) {
645 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
646 0 : return false;
647 : }
648 0 : return true;
649 : }
650 : case type__::TSurfaceDescriptorX11:
651 : {
652 0 : SurfaceDescriptorX11 tmp = SurfaceDescriptorX11();
653 0 : (*(v__)) = tmp;
654 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorX11())), msg__, iter__)))) {
655 0 : FatalError("Error deserializing Union type");
656 0 : return false;
657 : }
658 : // Sentinel = 'TSurfaceDescriptorX11'
659 0 : if ((!((msg__)->ReadSentinel(iter__, 3923930613)))) {
660 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
661 0 : return false;
662 : }
663 0 : return true;
664 : }
665 : case type__::TSurfaceTextureDescriptor:
666 : {
667 0 : SurfaceTextureDescriptor tmp = SurfaceTextureDescriptor();
668 0 : (*(v__)) = tmp;
669 0 : if ((!(Read((&((v__)->get_SurfaceTextureDescriptor())), msg__, iter__)))) {
670 0 : FatalError("Error deserializing Union type");
671 0 : return false;
672 : }
673 : // Sentinel = 'TSurfaceTextureDescriptor'
674 0 : if ((!((msg__)->ReadSentinel(iter__, 2253946800)))) {
675 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
676 0 : return false;
677 : }
678 0 : return true;
679 : }
680 : case type__::TEGLImageDescriptor:
681 : {
682 0 : EGLImageDescriptor tmp = EGLImageDescriptor();
683 0 : (*(v__)) = tmp;
684 0 : if ((!(Read((&((v__)->get_EGLImageDescriptor())), msg__, iter__)))) {
685 0 : FatalError("Error deserializing Union type");
686 0 : return false;
687 : }
688 : // Sentinel = 'TEGLImageDescriptor'
689 0 : if ((!((msg__)->ReadSentinel(iter__, 2680446099)))) {
690 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
691 0 : return false;
692 : }
693 0 : return true;
694 : }
695 : case type__::TSurfaceDescriptorMacIOSurface:
696 : {
697 0 : SurfaceDescriptorMacIOSurface tmp = SurfaceDescriptorMacIOSurface();
698 0 : (*(v__)) = tmp;
699 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorMacIOSurface())), msg__, iter__)))) {
700 0 : FatalError("Error deserializing Union type");
701 0 : return false;
702 : }
703 : // Sentinel = 'TSurfaceDescriptorMacIOSurface'
704 0 : if ((!((msg__)->ReadSentinel(iter__, 4267688786)))) {
705 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
706 0 : return false;
707 : }
708 0 : return true;
709 : }
710 : case type__::TSurfaceDescriptorSharedGLTexture:
711 : {
712 0 : SurfaceDescriptorSharedGLTexture tmp = SurfaceDescriptorSharedGLTexture();
713 0 : (*(v__)) = tmp;
714 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorSharedGLTexture())), msg__, iter__)))) {
715 0 : FatalError("Error deserializing Union type");
716 0 : return false;
717 : }
718 : // Sentinel = 'TSurfaceDescriptorSharedGLTexture'
719 0 : if ((!((msg__)->ReadSentinel(iter__, 4169514976)))) {
720 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
721 0 : return false;
722 : }
723 0 : return true;
724 : }
725 : case type__::TSurfaceDescriptorGPUVideo:
726 : {
727 0 : SurfaceDescriptorGPUVideo tmp = SurfaceDescriptorGPUVideo();
728 0 : (*(v__)) = tmp;
729 0 : if ((!(Read((&((v__)->get_SurfaceDescriptorGPUVideo())), msg__, iter__)))) {
730 0 : FatalError("Error deserializing Union type");
731 0 : return false;
732 : }
733 : // Sentinel = 'TSurfaceDescriptorGPUVideo'
734 0 : if ((!((msg__)->ReadSentinel(iter__, 2406892431)))) {
735 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
736 0 : return false;
737 : }
738 0 : return true;
739 : }
740 : case type__::Tnull_t:
741 : {
742 : null_t tmp = null_t();
743 0 : (*(v__)) = tmp;
744 0 : if ((!(Read((&((v__)->get_null_t())), msg__, iter__)))) {
745 0 : FatalError("Error deserializing Union type");
746 0 : return false;
747 : }
748 : // Sentinel = 'Tnull_t'
749 0 : if ((!((msg__)->ReadSentinel(iter__, 3731137201)))) {
750 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
751 0 : return false;
752 : }
753 0 : return true;
754 : }
755 : default:
756 : {
757 0 : FatalError("unknown union type");
758 0 : return false;
759 : }
760 : }
761 : }
762 :
763 0 : auto PVideoDecoderManagerParent::Write(
764 : const MemoryOrShmem& v__,
765 : Message* msg__) -> void
766 : {
767 : typedef MemoryOrShmem type__;
768 0 : Write(int((v__).type()), msg__);
769 : // Sentinel = 'MemoryOrShmem'
770 0 : (msg__)->WriteSentinel(3227621763);
771 :
772 0 : switch ((v__).type()) {
773 : case type__::Tuintptr_t:
774 : {
775 0 : Write((v__).get_uintptr_t(), msg__);
776 : // Sentinel = 'Tuintptr_t'
777 0 : (msg__)->WriteSentinel(3218141805);
778 0 : return;
779 : }
780 : case type__::TShmem:
781 : {
782 0 : Write((v__).get_Shmem(), msg__);
783 : // Sentinel = 'TShmem'
784 0 : (msg__)->WriteSentinel(3517971266);
785 0 : return;
786 : }
787 : default:
788 : {
789 0 : FatalError("unknown union type");
790 0 : return;
791 : }
792 : }
793 : }
794 :
795 0 : auto PVideoDecoderManagerParent::Read(
796 : MemoryOrShmem* v__,
797 : const Message* msg__,
798 : PickleIterator* iter__) -> bool
799 : {
800 : typedef MemoryOrShmem type__;
801 : int type;
802 0 : if ((!(Read((&(type)), msg__, iter__)))) {
803 0 : mozilla::ipc::UnionTypeReadError("MemoryOrShmem");
804 0 : return false;
805 : }
806 : // Sentinel = 'MemoryOrShmem'
807 0 : if ((!((msg__)->ReadSentinel(iter__, 3227621763)))) {
808 0 : mozilla::ipc::SentinelReadError("MemoryOrShmem");
809 0 : return false;
810 : }
811 :
812 0 : switch (type) {
813 : case type__::Tuintptr_t:
814 : {
815 0 : uintptr_t tmp = uintptr_t();
816 0 : (*(v__)) = tmp;
817 0 : if ((!(Read((&((v__)->get_uintptr_t())), msg__, iter__)))) {
818 0 : FatalError("Error deserializing Union type");
819 0 : return false;
820 : }
821 : // Sentinel = 'Tuintptr_t'
822 0 : if ((!((msg__)->ReadSentinel(iter__, 3218141805)))) {
823 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
824 0 : return false;
825 : }
826 0 : return true;
827 : }
828 : case type__::TShmem:
829 : {
830 0 : Shmem tmp = Shmem();
831 0 : (*(v__)) = tmp;
832 0 : if ((!(Read((&((v__)->get_Shmem())), msg__, iter__)))) {
833 0 : FatalError("Error deserializing Union type");
834 0 : return false;
835 : }
836 : // Sentinel = 'TShmem'
837 0 : if ((!((msg__)->ReadSentinel(iter__, 3517971266)))) {
838 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
839 0 : return false;
840 : }
841 0 : return true;
842 : }
843 : default:
844 : {
845 0 : FatalError("unknown union type");
846 0 : return false;
847 : }
848 : }
849 : }
850 :
851 0 : auto PVideoDecoderManagerParent::Write(
852 : const SurfaceDescriptorBuffer& v__,
853 : Message* msg__) -> void
854 : {
855 0 : Write((v__).desc(), msg__);
856 : // Sentinel = 'desc'
857 0 : (msg__)->WriteSentinel(3761872479);
858 0 : Write((v__).data(), msg__);
859 : // Sentinel = 'data'
860 0 : (msg__)->WriteSentinel(843352540);
861 0 : }
862 :
863 0 : auto PVideoDecoderManagerParent::Read(
864 : SurfaceDescriptorBuffer* v__,
865 : const Message* msg__,
866 : PickleIterator* iter__) -> bool
867 : {
868 0 : if ((!(Read((&((v__)->desc())), msg__, iter__)))) {
869 0 : FatalError("Error deserializing 'desc' (BufferDescriptor) member of 'SurfaceDescriptorBuffer'");
870 0 : return false;
871 : }
872 : // Sentinel = 'desc'
873 0 : if ((!((msg__)->ReadSentinel(iter__, 3761872479)))) {
874 0 : mozilla::ipc::SentinelReadError("Error deserializing 'desc' (BufferDescriptor) member of 'SurfaceDescriptorBuffer'");
875 0 : return false;
876 : }
877 0 : if ((!(Read((&((v__)->data())), msg__, iter__)))) {
878 0 : FatalError("Error deserializing 'data' (MemoryOrShmem) member of 'SurfaceDescriptorBuffer'");
879 0 : return false;
880 : }
881 : // Sentinel = 'data'
882 0 : if ((!((msg__)->ReadSentinel(iter__, 843352540)))) {
883 0 : mozilla::ipc::SentinelReadError("Error deserializing 'data' (MemoryOrShmem) member of 'SurfaceDescriptorBuffer'");
884 0 : return false;
885 : }
886 0 : return true;
887 : }
888 :
889 0 : auto PVideoDecoderManagerParent::Write(
890 : const SurfaceDescriptorDXGIYCbCr& v__,
891 : Message* msg__) -> void
892 : {
893 0 : Write((v__).handleY(), msg__);
894 : // Sentinel = 'handleY'
895 0 : (msg__)->WriteSentinel(2719705368);
896 0 : Write((v__).handleCb(), msg__);
897 : // Sentinel = 'handleCb'
898 0 : (msg__)->WriteSentinel(2777335333);
899 0 : Write((v__).handleCr(), msg__);
900 : // Sentinel = 'handleCr'
901 0 : (msg__)->WriteSentinel(2777335349);
902 0 : Write((v__).size(), msg__);
903 : // Sentinel = 'size'
904 0 : (msg__)->WriteSentinel(931048223);
905 0 : Write((v__).sizeY(), msg__);
906 : // Sentinel = 'sizeY'
907 0 : (msg__)->WriteSentinel(886619725);
908 0 : Write((v__).sizeCbCr(), msg__);
909 : // Sentinel = 'sizeCbCr'
910 0 : (msg__)->WriteSentinel(2196484423);
911 0 : }
912 :
913 0 : auto PVideoDecoderManagerParent::Read(
914 : SurfaceDescriptorDXGIYCbCr* v__,
915 : const Message* msg__,
916 : PickleIterator* iter__) -> bool
917 : {
918 0 : if ((!(Read((&((v__)->handleY())), msg__, iter__)))) {
919 0 : FatalError("Error deserializing 'handleY' (WindowsHandle) member of 'SurfaceDescriptorDXGIYCbCr'");
920 0 : return false;
921 : }
922 : // Sentinel = 'handleY'
923 0 : if ((!((msg__)->ReadSentinel(iter__, 2719705368)))) {
924 0 : mozilla::ipc::SentinelReadError("Error deserializing 'handleY' (WindowsHandle) member of 'SurfaceDescriptorDXGIYCbCr'");
925 0 : return false;
926 : }
927 0 : if ((!(Read((&((v__)->handleCb())), msg__, iter__)))) {
928 0 : FatalError("Error deserializing 'handleCb' (WindowsHandle) member of 'SurfaceDescriptorDXGIYCbCr'");
929 0 : return false;
930 : }
931 : // Sentinel = 'handleCb'
932 0 : if ((!((msg__)->ReadSentinel(iter__, 2777335333)))) {
933 0 : mozilla::ipc::SentinelReadError("Error deserializing 'handleCb' (WindowsHandle) member of 'SurfaceDescriptorDXGIYCbCr'");
934 0 : return false;
935 : }
936 0 : if ((!(Read((&((v__)->handleCr())), msg__, iter__)))) {
937 0 : FatalError("Error deserializing 'handleCr' (WindowsHandle) member of 'SurfaceDescriptorDXGIYCbCr'");
938 0 : return false;
939 : }
940 : // Sentinel = 'handleCr'
941 0 : if ((!((msg__)->ReadSentinel(iter__, 2777335349)))) {
942 0 : mozilla::ipc::SentinelReadError("Error deserializing 'handleCr' (WindowsHandle) member of 'SurfaceDescriptorDXGIYCbCr'");
943 0 : return false;
944 : }
945 0 : if ((!(Read((&((v__)->size())), msg__, iter__)))) {
946 0 : FatalError("Error deserializing 'size' (IntSize) member of 'SurfaceDescriptorDXGIYCbCr'");
947 0 : return false;
948 : }
949 : // Sentinel = 'size'
950 0 : if ((!((msg__)->ReadSentinel(iter__, 931048223)))) {
951 0 : mozilla::ipc::SentinelReadError("Error deserializing 'size' (IntSize) member of 'SurfaceDescriptorDXGIYCbCr'");
952 0 : return false;
953 : }
954 0 : if ((!(Read((&((v__)->sizeY())), msg__, iter__)))) {
955 0 : FatalError("Error deserializing 'sizeY' (IntSize) member of 'SurfaceDescriptorDXGIYCbCr'");
956 0 : return false;
957 : }
958 : // Sentinel = 'sizeY'
959 0 : if ((!((msg__)->ReadSentinel(iter__, 886619725)))) {
960 0 : mozilla::ipc::SentinelReadError("Error deserializing 'sizeY' (IntSize) member of 'SurfaceDescriptorDXGIYCbCr'");
961 0 : return false;
962 : }
963 0 : if ((!(Read((&((v__)->sizeCbCr())), msg__, iter__)))) {
964 0 : FatalError("Error deserializing 'sizeCbCr' (IntSize) member of 'SurfaceDescriptorDXGIYCbCr'");
965 0 : return false;
966 : }
967 : // Sentinel = 'sizeCbCr'
968 0 : if ((!((msg__)->ReadSentinel(iter__, 2196484423)))) {
969 0 : mozilla::ipc::SentinelReadError("Error deserializing 'sizeCbCr' (IntSize) member of 'SurfaceDescriptorDXGIYCbCr'");
970 0 : return false;
971 : }
972 0 : return true;
973 : }
974 :
975 0 : auto PVideoDecoderManagerParent::Write(
976 : const SurfaceDescriptorDIB& v__,
977 : Message* msg__) -> void
978 : {
979 0 : Write((v__).surface(), msg__);
980 : // Sentinel = 'surface'
981 0 : (msg__)->WriteSentinel(2386836878);
982 0 : }
983 :
984 0 : auto PVideoDecoderManagerParent::Read(
985 : SurfaceDescriptorDIB* v__,
986 : const Message* msg__,
987 : PickleIterator* iter__) -> bool
988 : {
989 0 : if ((!(Read((&((v__)->surface())), msg__, iter__)))) {
990 0 : FatalError("Error deserializing 'surface' (uintptr_t) member of 'SurfaceDescriptorDIB'");
991 0 : return false;
992 : }
993 : // Sentinel = 'surface'
994 0 : if ((!((msg__)->ReadSentinel(iter__, 2386836878)))) {
995 0 : mozilla::ipc::SentinelReadError("Error deserializing 'surface' (uintptr_t) member of 'SurfaceDescriptorDIB'");
996 0 : return false;
997 : }
998 0 : return true;
999 : }
1000 :
1001 0 : auto PVideoDecoderManagerParent::Write(
1002 : const RGBDescriptor& v__,
1003 : Message* msg__) -> void
1004 : {
1005 0 : Write((v__).size(), msg__);
1006 : // Sentinel = 'size'
1007 0 : (msg__)->WriteSentinel(931048223);
1008 0 : Write((v__).format(), msg__);
1009 : // Sentinel = 'format'
1010 0 : (msg__)->WriteSentinel(2052265543);
1011 0 : Write((v__).hasIntermediateBuffer(), msg__);
1012 : // Sentinel = 'hasIntermediateBuffer'
1013 0 : (msg__)->WriteSentinel(985857996);
1014 0 : }
1015 :
1016 0 : auto PVideoDecoderManagerParent::Read(
1017 : RGBDescriptor* v__,
1018 : const Message* msg__,
1019 : PickleIterator* iter__) -> bool
1020 : {
1021 0 : if ((!(Read((&((v__)->size())), msg__, iter__)))) {
1022 0 : FatalError("Error deserializing 'size' (IntSize) member of 'RGBDescriptor'");
1023 0 : return false;
1024 : }
1025 : // Sentinel = 'size'
1026 0 : if ((!((msg__)->ReadSentinel(iter__, 931048223)))) {
1027 0 : mozilla::ipc::SentinelReadError("Error deserializing 'size' (IntSize) member of 'RGBDescriptor'");
1028 0 : return false;
1029 : }
1030 0 : if ((!(Read((&((v__)->format())), msg__, iter__)))) {
1031 0 : FatalError("Error deserializing 'format' (SurfaceFormat) member of 'RGBDescriptor'");
1032 0 : return false;
1033 : }
1034 : // Sentinel = 'format'
1035 0 : if ((!((msg__)->ReadSentinel(iter__, 2052265543)))) {
1036 0 : mozilla::ipc::SentinelReadError("Error deserializing 'format' (SurfaceFormat) member of 'RGBDescriptor'");
1037 0 : return false;
1038 : }
1039 0 : if ((!(Read((&((v__)->hasIntermediateBuffer())), msg__, iter__)))) {
1040 0 : FatalError("Error deserializing 'hasIntermediateBuffer' (bool) member of 'RGBDescriptor'");
1041 0 : return false;
1042 : }
1043 : // Sentinel = 'hasIntermediateBuffer'
1044 0 : if ((!((msg__)->ReadSentinel(iter__, 985857996)))) {
1045 0 : mozilla::ipc::SentinelReadError("Error deserializing 'hasIntermediateBuffer' (bool) member of 'RGBDescriptor'");
1046 0 : return false;
1047 : }
1048 0 : return true;
1049 : }
1050 :
1051 0 : auto PVideoDecoderManagerParent::Write(
1052 : const SurfaceTextureDescriptor& v__,
1053 : Message* msg__) -> void
1054 : {
1055 0 : Write((v__).handle(), msg__);
1056 : // Sentinel = 'handle'
1057 0 : (msg__)->WriteSentinel(453975108);
1058 0 : Write((v__).size(), msg__);
1059 : // Sentinel = 'size'
1060 0 : (msg__)->WriteSentinel(931048223);
1061 0 : Write((v__).continuous(), msg__);
1062 : // Sentinel = 'continuous'
1063 0 : (msg__)->WriteSentinel(2103626571);
1064 0 : }
1065 :
1066 0 : auto PVideoDecoderManagerParent::Read(
1067 : SurfaceTextureDescriptor* v__,
1068 : const Message* msg__,
1069 : PickleIterator* iter__) -> bool
1070 : {
1071 0 : if ((!(Read((&((v__)->handle())), msg__, iter__)))) {
1072 0 : FatalError("Error deserializing 'handle' (uint64_t) member of 'SurfaceTextureDescriptor'");
1073 0 : return false;
1074 : }
1075 : // Sentinel = 'handle'
1076 0 : if ((!((msg__)->ReadSentinel(iter__, 453975108)))) {
1077 0 : mozilla::ipc::SentinelReadError("Error deserializing 'handle' (uint64_t) member of 'SurfaceTextureDescriptor'");
1078 0 : return false;
1079 : }
1080 0 : if ((!(Read((&((v__)->size())), msg__, iter__)))) {
1081 0 : FatalError("Error deserializing 'size' (IntSize) member of 'SurfaceTextureDescriptor'");
1082 0 : return false;
1083 : }
1084 : // Sentinel = 'size'
1085 0 : if ((!((msg__)->ReadSentinel(iter__, 931048223)))) {
1086 0 : mozilla::ipc::SentinelReadError("Error deserializing 'size' (IntSize) member of 'SurfaceTextureDescriptor'");
1087 0 : return false;
1088 : }
1089 0 : if ((!(Read((&((v__)->continuous())), msg__, iter__)))) {
1090 0 : FatalError("Error deserializing 'continuous' (bool) member of 'SurfaceTextureDescriptor'");
1091 0 : return false;
1092 : }
1093 : // Sentinel = 'continuous'
1094 0 : if ((!((msg__)->ReadSentinel(iter__, 2103626571)))) {
1095 0 : mozilla::ipc::SentinelReadError("Error deserializing 'continuous' (bool) member of 'SurfaceTextureDescriptor'");
1096 0 : return false;
1097 : }
1098 0 : return true;
1099 : }
1100 :
1101 0 : auto PVideoDecoderManagerParent::Write(
1102 : const SurfaceDescriptorSharedGLTexture& v__,
1103 : Message* msg__) -> void
1104 : {
1105 0 : Write((v__).texture(), msg__);
1106 : // Sentinel = 'texture'
1107 0 : (msg__)->WriteSentinel(3654462510);
1108 0 : Write((v__).target(), msg__);
1109 : // Sentinel = 'target'
1110 0 : (msg__)->WriteSentinel(2226365285);
1111 0 : Write((v__).fence(), msg__);
1112 : // Sentinel = 'fence'
1113 0 : (msg__)->WriteSentinel(1225633926);
1114 0 : Write((v__).size(), msg__);
1115 : // Sentinel = 'size'
1116 0 : (msg__)->WriteSentinel(931048223);
1117 0 : Write((v__).hasAlpha(), msg__);
1118 : // Sentinel = 'hasAlpha'
1119 0 : (msg__)->WriteSentinel(309498444);
1120 0 : }
1121 :
1122 0 : auto PVideoDecoderManagerParent::Read(
1123 : SurfaceDescriptorSharedGLTexture* v__,
1124 : const Message* msg__,
1125 : PickleIterator* iter__) -> bool
1126 : {
1127 0 : if ((!(Read((&((v__)->texture())), msg__, iter__)))) {
1128 0 : FatalError("Error deserializing 'texture' (uint32_t) member of 'SurfaceDescriptorSharedGLTexture'");
1129 0 : return false;
1130 : }
1131 : // Sentinel = 'texture'
1132 0 : if ((!((msg__)->ReadSentinel(iter__, 3654462510)))) {
1133 0 : mozilla::ipc::SentinelReadError("Error deserializing 'texture' (uint32_t) member of 'SurfaceDescriptorSharedGLTexture'");
1134 0 : return false;
1135 : }
1136 0 : if ((!(Read((&((v__)->target())), msg__, iter__)))) {
1137 0 : FatalError("Error deserializing 'target' (uint32_t) member of 'SurfaceDescriptorSharedGLTexture'");
1138 0 : return false;
1139 : }
1140 : // Sentinel = 'target'
1141 0 : if ((!((msg__)->ReadSentinel(iter__, 2226365285)))) {
1142 0 : mozilla::ipc::SentinelReadError("Error deserializing 'target' (uint32_t) member of 'SurfaceDescriptorSharedGLTexture'");
1143 0 : return false;
1144 : }
1145 0 : if ((!(Read((&((v__)->fence())), msg__, iter__)))) {
1146 0 : FatalError("Error deserializing 'fence' (uintptr_t) member of 'SurfaceDescriptorSharedGLTexture'");
1147 0 : return false;
1148 : }
1149 : // Sentinel = 'fence'
1150 0 : if ((!((msg__)->ReadSentinel(iter__, 1225633926)))) {
1151 0 : mozilla::ipc::SentinelReadError("Error deserializing 'fence' (uintptr_t) member of 'SurfaceDescriptorSharedGLTexture'");
1152 0 : return false;
1153 : }
1154 0 : if ((!(Read((&((v__)->size())), msg__, iter__)))) {
1155 0 : FatalError("Error deserializing 'size' (IntSize) member of 'SurfaceDescriptorSharedGLTexture'");
1156 0 : return false;
1157 : }
1158 : // Sentinel = 'size'
1159 0 : if ((!((msg__)->ReadSentinel(iter__, 931048223)))) {
1160 0 : mozilla::ipc::SentinelReadError("Error deserializing 'size' (IntSize) member of 'SurfaceDescriptorSharedGLTexture'");
1161 0 : return false;
1162 : }
1163 0 : if ((!(Read((&((v__)->hasAlpha())), msg__, iter__)))) {
1164 0 : FatalError("Error deserializing 'hasAlpha' (bool) member of 'SurfaceDescriptorSharedGLTexture'");
1165 0 : return false;
1166 : }
1167 : // Sentinel = 'hasAlpha'
1168 0 : if ((!((msg__)->ReadSentinel(iter__, 309498444)))) {
1169 0 : mozilla::ipc::SentinelReadError("Error deserializing 'hasAlpha' (bool) member of 'SurfaceDescriptorSharedGLTexture'");
1170 0 : return false;
1171 : }
1172 0 : return true;
1173 : }
1174 :
1175 0 : auto PVideoDecoderManagerParent::Write(
1176 : const PVideoDecoderParent* v__,
1177 : Message* msg__,
1178 : bool nullable__) -> void
1179 : {
1180 : int32_t id;
1181 0 : if ((!(v__))) {
1182 0 : if ((!(nullable__))) {
1183 0 : FatalError("NULL actor value passed to non-nullable param");
1184 : }
1185 0 : id = 0;
1186 : }
1187 : else {
1188 0 : id = (v__)->Id();
1189 0 : if ((1) == (id)) {
1190 0 : FatalError("actor has been |delete|d");
1191 : }
1192 : }
1193 :
1194 0 : Write(id, msg__);
1195 0 : }
1196 :
1197 0 : auto PVideoDecoderManagerParent::Read(
1198 : PVideoDecoderParent** v__,
1199 : const Message* msg__,
1200 : PickleIterator* iter__,
1201 : bool nullable__) -> bool
1202 : {
1203 0 : Maybe<mozilla::ipc::IProtocol*> actor = ReadActor(msg__, iter__, nullable__, "PVideoDecoder", PVideoDecoderMsgStart);
1204 0 : if ((actor).isNothing()) {
1205 0 : return false;
1206 : }
1207 :
1208 0 : (*(v__)) = static_cast<PVideoDecoderParent*>((actor).value());
1209 0 : return true;
1210 : }
1211 :
1212 0 : auto PVideoDecoderManagerParent::Write(
1213 : const SurfaceDescriptorGPUVideo& v__,
1214 : Message* msg__) -> void
1215 : {
1216 0 : Write((v__).handle(), msg__);
1217 : // Sentinel = 'handle'
1218 0 : (msg__)->WriteSentinel(453975108);
1219 0 : }
1220 :
1221 0 : auto PVideoDecoderManagerParent::Read(
1222 : SurfaceDescriptorGPUVideo* v__,
1223 : const Message* msg__,
1224 : PickleIterator* iter__) -> bool
1225 : {
1226 0 : if ((!(Read((&((v__)->handle())), msg__, iter__)))) {
1227 0 : FatalError("Error deserializing 'handle' (uint64_t) member of 'SurfaceDescriptorGPUVideo'");
1228 0 : return false;
1229 : }
1230 : // Sentinel = 'handle'
1231 0 : if ((!((msg__)->ReadSentinel(iter__, 453975108)))) {
1232 0 : mozilla::ipc::SentinelReadError("Error deserializing 'handle' (uint64_t) member of 'SurfaceDescriptorGPUVideo'");
1233 0 : return false;
1234 : }
1235 0 : return true;
1236 : }
1237 :
1238 0 : auto PVideoDecoderManagerParent::Write(
1239 : const SurfaceDescriptorMacIOSurface& v__,
1240 : Message* msg__) -> void
1241 : {
1242 0 : Write((v__).surfaceId(), msg__);
1243 : // Sentinel = 'surfaceId'
1244 0 : (msg__)->WriteSentinel(4108848731);
1245 0 : Write((v__).scaleFactor(), msg__);
1246 : // Sentinel = 'scaleFactor'
1247 0 : (msg__)->WriteSentinel(1184637148);
1248 0 : Write((v__).isOpaque(), msg__);
1249 : // Sentinel = 'isOpaque'
1250 0 : (msg__)->WriteSentinel(3519081617);
1251 0 : }
1252 :
1253 0 : auto PVideoDecoderManagerParent::Read(
1254 : SurfaceDescriptorMacIOSurface* v__,
1255 : const Message* msg__,
1256 : PickleIterator* iter__) -> bool
1257 : {
1258 0 : if ((!(Read((&((v__)->surfaceId())), msg__, iter__)))) {
1259 0 : FatalError("Error deserializing 'surfaceId' (uint32_t) member of 'SurfaceDescriptorMacIOSurface'");
1260 0 : return false;
1261 : }
1262 : // Sentinel = 'surfaceId'
1263 0 : if ((!((msg__)->ReadSentinel(iter__, 4108848731)))) {
1264 0 : mozilla::ipc::SentinelReadError("Error deserializing 'surfaceId' (uint32_t) member of 'SurfaceDescriptorMacIOSurface'");
1265 0 : return false;
1266 : }
1267 0 : if ((!(Read((&((v__)->scaleFactor())), msg__, iter__)))) {
1268 0 : FatalError("Error deserializing 'scaleFactor' (double) member of 'SurfaceDescriptorMacIOSurface'");
1269 0 : return false;
1270 : }
1271 : // Sentinel = 'scaleFactor'
1272 0 : if ((!((msg__)->ReadSentinel(iter__, 1184637148)))) {
1273 0 : mozilla::ipc::SentinelReadError("Error deserializing 'scaleFactor' (double) member of 'SurfaceDescriptorMacIOSurface'");
1274 0 : return false;
1275 : }
1276 0 : if ((!(Read((&((v__)->isOpaque())), msg__, iter__)))) {
1277 0 : FatalError("Error deserializing 'isOpaque' (bool) member of 'SurfaceDescriptorMacIOSurface'");
1278 0 : return false;
1279 : }
1280 : // Sentinel = 'isOpaque'
1281 0 : if ((!((msg__)->ReadSentinel(iter__, 3519081617)))) {
1282 0 : mozilla::ipc::SentinelReadError("Error deserializing 'isOpaque' (bool) member of 'SurfaceDescriptorMacIOSurface'");
1283 0 : return false;
1284 : }
1285 0 : return true;
1286 : }
1287 :
1288 0 : auto PVideoDecoderManagerParent::Write(
1289 : const SurfaceDescriptorD3D10& v__,
1290 : Message* msg__) -> void
1291 : {
1292 0 : Write((v__).handle(), msg__);
1293 : // Sentinel = 'handle'
1294 0 : (msg__)->WriteSentinel(453975108);
1295 0 : Write((v__).format(), msg__);
1296 : // Sentinel = 'format'
1297 0 : (msg__)->WriteSentinel(2052265543);
1298 0 : Write((v__).size(), msg__);
1299 : // Sentinel = 'size'
1300 0 : (msg__)->WriteSentinel(931048223);
1301 0 : }
1302 :
1303 0 : auto PVideoDecoderManagerParent::Read(
1304 : SurfaceDescriptorD3D10* v__,
1305 : const Message* msg__,
1306 : PickleIterator* iter__) -> bool
1307 : {
1308 0 : if ((!(Read((&((v__)->handle())), msg__, iter__)))) {
1309 0 : FatalError("Error deserializing 'handle' (WindowsHandle) member of 'SurfaceDescriptorD3D10'");
1310 0 : return false;
1311 : }
1312 : // Sentinel = 'handle'
1313 0 : if ((!((msg__)->ReadSentinel(iter__, 453975108)))) {
1314 0 : mozilla::ipc::SentinelReadError("Error deserializing 'handle' (WindowsHandle) member of 'SurfaceDescriptorD3D10'");
1315 0 : return false;
1316 : }
1317 0 : if ((!(Read((&((v__)->format())), msg__, iter__)))) {
1318 0 : FatalError("Error deserializing 'format' (SurfaceFormat) member of 'SurfaceDescriptorD3D10'");
1319 0 : return false;
1320 : }
1321 : // Sentinel = 'format'
1322 0 : if ((!((msg__)->ReadSentinel(iter__, 2052265543)))) {
1323 0 : mozilla::ipc::SentinelReadError("Error deserializing 'format' (SurfaceFormat) member of 'SurfaceDescriptorD3D10'");
1324 0 : return false;
1325 : }
1326 0 : if ((!(Read((&((v__)->size())), msg__, iter__)))) {
1327 0 : FatalError("Error deserializing 'size' (IntSize) member of 'SurfaceDescriptorD3D10'");
1328 0 : return false;
1329 : }
1330 : // Sentinel = 'size'
1331 0 : if ((!((msg__)->ReadSentinel(iter__, 931048223)))) {
1332 0 : mozilla::ipc::SentinelReadError("Error deserializing 'size' (IntSize) member of 'SurfaceDescriptorD3D10'");
1333 0 : return false;
1334 : }
1335 0 : return true;
1336 : }
1337 :
1338 0 : auto PVideoDecoderManagerParent::Write(
1339 : const BufferDescriptor& v__,
1340 : Message* msg__) -> void
1341 : {
1342 : typedef BufferDescriptor type__;
1343 0 : Write(int((v__).type()), msg__);
1344 : // Sentinel = 'BufferDescriptor'
1345 0 : (msg__)->WriteSentinel(764535685);
1346 :
1347 0 : switch ((v__).type()) {
1348 : case type__::TRGBDescriptor:
1349 : {
1350 0 : Write((v__).get_RGBDescriptor(), msg__);
1351 : // Sentinel = 'TRGBDescriptor'
1352 0 : (msg__)->WriteSentinel(2888062100);
1353 0 : return;
1354 : }
1355 : case type__::TYCbCrDescriptor:
1356 : {
1357 0 : Write((v__).get_YCbCrDescriptor(), msg__);
1358 : // Sentinel = 'TYCbCrDescriptor'
1359 0 : (msg__)->WriteSentinel(3533945878);
1360 0 : return;
1361 : }
1362 : default:
1363 : {
1364 0 : FatalError("unknown union type");
1365 0 : return;
1366 : }
1367 : }
1368 : }
1369 :
1370 0 : auto PVideoDecoderManagerParent::Read(
1371 : BufferDescriptor* v__,
1372 : const Message* msg__,
1373 : PickleIterator* iter__) -> bool
1374 : {
1375 : typedef BufferDescriptor type__;
1376 : int type;
1377 0 : if ((!(Read((&(type)), msg__, iter__)))) {
1378 0 : mozilla::ipc::UnionTypeReadError("BufferDescriptor");
1379 0 : return false;
1380 : }
1381 : // Sentinel = 'BufferDescriptor'
1382 0 : if ((!((msg__)->ReadSentinel(iter__, 764535685)))) {
1383 0 : mozilla::ipc::SentinelReadError("BufferDescriptor");
1384 0 : return false;
1385 : }
1386 :
1387 0 : switch (type) {
1388 : case type__::TRGBDescriptor:
1389 : {
1390 0 : RGBDescriptor tmp = RGBDescriptor();
1391 0 : (*(v__)) = tmp;
1392 0 : if ((!(Read((&((v__)->get_RGBDescriptor())), msg__, iter__)))) {
1393 0 : FatalError("Error deserializing Union type");
1394 0 : return false;
1395 : }
1396 : // Sentinel = 'TRGBDescriptor'
1397 0 : if ((!((msg__)->ReadSentinel(iter__, 2888062100)))) {
1398 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
1399 0 : return false;
1400 : }
1401 0 : return true;
1402 : }
1403 : case type__::TYCbCrDescriptor:
1404 : {
1405 0 : YCbCrDescriptor tmp = YCbCrDescriptor();
1406 0 : (*(v__)) = tmp;
1407 0 : if ((!(Read((&((v__)->get_YCbCrDescriptor())), msg__, iter__)))) {
1408 0 : FatalError("Error deserializing Union type");
1409 0 : return false;
1410 : }
1411 : // Sentinel = 'TYCbCrDescriptor'
1412 0 : if ((!((msg__)->ReadSentinel(iter__, 3533945878)))) {
1413 0 : mozilla::ipc::SentinelReadError("Error deserializing Union type");
1414 0 : return false;
1415 : }
1416 0 : return true;
1417 : }
1418 : default:
1419 : {
1420 0 : FatalError("unknown union type");
1421 0 : return false;
1422 : }
1423 : }
1424 : }
1425 :
1426 0 : auto PVideoDecoderManagerParent::Write(
1427 : const YCbCrDescriptor& v__,
1428 : Message* msg__) -> void
1429 : {
1430 0 : Write((v__).ySize(), msg__);
1431 : // Sentinel = 'ySize'
1432 0 : (msg__)->WriteSentinel(313512843);
1433 0 : Write((v__).cbCrSize(), msg__);
1434 : // Sentinel = 'cbCrSize'
1435 0 : (msg__)->WriteSentinel(2601117167);
1436 0 : Write((v__).yOffset(), msg__);
1437 : // Sentinel = 'yOffset'
1438 0 : (msg__)->WriteSentinel(983795183);
1439 0 : Write((v__).cbOffset(), msg__);
1440 : // Sentinel = 'cbOffset'
1441 0 : (msg__)->WriteSentinel(4197159602);
1442 0 : Write((v__).crOffset(), msg__);
1443 : // Sentinel = 'crOffset'
1444 0 : (msg__)->WriteSentinel(1739681986);
1445 0 : Write((v__).stereoMode(), msg__);
1446 : // Sentinel = 'stereoMode'
1447 0 : (msg__)->WriteSentinel(2234072623);
1448 0 : Write((v__).yUVColorSpace(), msg__);
1449 : // Sentinel = 'yUVColorSpace'
1450 0 : (msg__)->WriteSentinel(1051398544);
1451 0 : Write((v__).hasIntermediateBuffer(), msg__);
1452 : // Sentinel = 'hasIntermediateBuffer'
1453 0 : (msg__)->WriteSentinel(985857996);
1454 0 : }
1455 :
1456 0 : auto PVideoDecoderManagerParent::Read(
1457 : YCbCrDescriptor* v__,
1458 : const Message* msg__,
1459 : PickleIterator* iter__) -> bool
1460 : {
1461 0 : if ((!(Read((&((v__)->ySize())), msg__, iter__)))) {
1462 0 : FatalError("Error deserializing 'ySize' (IntSize) member of 'YCbCrDescriptor'");
1463 0 : return false;
1464 : }
1465 : // Sentinel = 'ySize'
1466 0 : if ((!((msg__)->ReadSentinel(iter__, 313512843)))) {
1467 0 : mozilla::ipc::SentinelReadError("Error deserializing 'ySize' (IntSize) member of 'YCbCrDescriptor'");
1468 0 : return false;
1469 : }
1470 0 : if ((!(Read((&((v__)->cbCrSize())), msg__, iter__)))) {
1471 0 : FatalError("Error deserializing 'cbCrSize' (IntSize) member of 'YCbCrDescriptor'");
1472 0 : return false;
1473 : }
1474 : // Sentinel = 'cbCrSize'
1475 0 : if ((!((msg__)->ReadSentinel(iter__, 2601117167)))) {
1476 0 : mozilla::ipc::SentinelReadError("Error deserializing 'cbCrSize' (IntSize) member of 'YCbCrDescriptor'");
1477 0 : return false;
1478 : }
1479 0 : if ((!(Read((&((v__)->yOffset())), msg__, iter__)))) {
1480 0 : FatalError("Error deserializing 'yOffset' (uint32_t) member of 'YCbCrDescriptor'");
1481 0 : return false;
1482 : }
1483 : // Sentinel = 'yOffset'
1484 0 : if ((!((msg__)->ReadSentinel(iter__, 983795183)))) {
1485 0 : mozilla::ipc::SentinelReadError("Error deserializing 'yOffset' (uint32_t) member of 'YCbCrDescriptor'");
1486 0 : return false;
1487 : }
1488 0 : if ((!(Read((&((v__)->cbOffset())), msg__, iter__)))) {
1489 0 : FatalError("Error deserializing 'cbOffset' (uint32_t) member of 'YCbCrDescriptor'");
1490 0 : return false;
1491 : }
1492 : // Sentinel = 'cbOffset'
1493 0 : if ((!((msg__)->ReadSentinel(iter__, 4197159602)))) {
1494 0 : mozilla::ipc::SentinelReadError("Error deserializing 'cbOffset' (uint32_t) member of 'YCbCrDescriptor'");
1495 0 : return false;
1496 : }
1497 0 : if ((!(Read((&((v__)->crOffset())), msg__, iter__)))) {
1498 0 : FatalError("Error deserializing 'crOffset' (uint32_t) member of 'YCbCrDescriptor'");
1499 0 : return false;
1500 : }
1501 : // Sentinel = 'crOffset'
1502 0 : if ((!((msg__)->ReadSentinel(iter__, 1739681986)))) {
1503 0 : mozilla::ipc::SentinelReadError("Error deserializing 'crOffset' (uint32_t) member of 'YCbCrDescriptor'");
1504 0 : return false;
1505 : }
1506 0 : if ((!(Read((&((v__)->stereoMode())), msg__, iter__)))) {
1507 0 : FatalError("Error deserializing 'stereoMode' (StereoMode) member of 'YCbCrDescriptor'");
1508 0 : return false;
1509 : }
1510 : // Sentinel = 'stereoMode'
1511 0 : if ((!((msg__)->ReadSentinel(iter__, 2234072623)))) {
1512 0 : mozilla::ipc::SentinelReadError("Error deserializing 'stereoMode' (StereoMode) member of 'YCbCrDescriptor'");
1513 0 : return false;
1514 : }
1515 0 : if ((!(Read((&((v__)->yUVColorSpace())), msg__, iter__)))) {
1516 0 : FatalError("Error deserializing 'yUVColorSpace' (YUVColorSpace) member of 'YCbCrDescriptor'");
1517 0 : return false;
1518 : }
1519 : // Sentinel = 'yUVColorSpace'
1520 0 : if ((!((msg__)->ReadSentinel(iter__, 1051398544)))) {
1521 0 : mozilla::ipc::SentinelReadError("Error deserializing 'yUVColorSpace' (YUVColorSpace) member of 'YCbCrDescriptor'");
1522 0 : return false;
1523 : }
1524 0 : if ((!(Read((&((v__)->hasIntermediateBuffer())), msg__, iter__)))) {
1525 0 : FatalError("Error deserializing 'hasIntermediateBuffer' (bool) member of 'YCbCrDescriptor'");
1526 0 : return false;
1527 : }
1528 : // Sentinel = 'hasIntermediateBuffer'
1529 0 : if ((!((msg__)->ReadSentinel(iter__, 985857996)))) {
1530 0 : mozilla::ipc::SentinelReadError("Error deserializing 'hasIntermediateBuffer' (bool) member of 'YCbCrDescriptor'");
1531 0 : return false;
1532 : }
1533 0 : return true;
1534 : }
1535 :
1536 0 : auto PVideoDecoderManagerParent::Write(
1537 : const SurfaceDescriptorFileMapping& v__,
1538 : Message* msg__) -> void
1539 : {
1540 0 : Write((v__).handle(), msg__);
1541 : // Sentinel = 'handle'
1542 0 : (msg__)->WriteSentinel(453975108);
1543 0 : Write((v__).format(), msg__);
1544 : // Sentinel = 'format'
1545 0 : (msg__)->WriteSentinel(2052265543);
1546 0 : Write((v__).size(), msg__);
1547 : // Sentinel = 'size'
1548 0 : (msg__)->WriteSentinel(931048223);
1549 0 : }
1550 :
1551 0 : auto PVideoDecoderManagerParent::Read(
1552 : SurfaceDescriptorFileMapping* v__,
1553 : const Message* msg__,
1554 : PickleIterator* iter__) -> bool
1555 : {
1556 0 : if ((!(Read((&((v__)->handle())), msg__, iter__)))) {
1557 0 : FatalError("Error deserializing 'handle' (WindowsHandle) member of 'SurfaceDescriptorFileMapping'");
1558 0 : return false;
1559 : }
1560 : // Sentinel = 'handle'
1561 0 : if ((!((msg__)->ReadSentinel(iter__, 453975108)))) {
1562 0 : mozilla::ipc::SentinelReadError("Error deserializing 'handle' (WindowsHandle) member of 'SurfaceDescriptorFileMapping'");
1563 0 : return false;
1564 : }
1565 0 : if ((!(Read((&((v__)->format())), msg__, iter__)))) {
1566 0 : FatalError("Error deserializing 'format' (SurfaceFormat) member of 'SurfaceDescriptorFileMapping'");
1567 0 : return false;
1568 : }
1569 : // Sentinel = 'format'
1570 0 : if ((!((msg__)->ReadSentinel(iter__, 2052265543)))) {
1571 0 : mozilla::ipc::SentinelReadError("Error deserializing 'format' (SurfaceFormat) member of 'SurfaceDescriptorFileMapping'");
1572 0 : return false;
1573 : }
1574 0 : if ((!(Read((&((v__)->size())), msg__, iter__)))) {
1575 0 : FatalError("Error deserializing 'size' (IntSize) member of 'SurfaceDescriptorFileMapping'");
1576 0 : return false;
1577 : }
1578 : // Sentinel = 'size'
1579 0 : if ((!((msg__)->ReadSentinel(iter__, 931048223)))) {
1580 0 : mozilla::ipc::SentinelReadError("Error deserializing 'size' (IntSize) member of 'SurfaceDescriptorFileMapping'");
1581 0 : return false;
1582 : }
1583 0 : return true;
1584 : }
1585 :
1586 0 : auto PVideoDecoderManagerParent::Write(
1587 : Shmem& v__,
1588 : Message* msg__) -> void
1589 : {
1590 0 : IPC::WriteParam(msg__, v__);
1591 0 : (v__).RevokeRights(Shmem::IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead());
1592 0 : (v__).forget(Shmem::IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead());
1593 0 : }
1594 :
1595 0 : auto PVideoDecoderManagerParent::Read(
1596 : Shmem* v__,
1597 : const Message* msg__,
1598 : PickleIterator* iter__) -> bool
1599 : {
1600 0 : Shmem tmp;
1601 0 : if ((!(IPC::ReadParam(msg__, iter__, (&(tmp)))))) {
1602 0 : return false;
1603 : }
1604 :
1605 0 : Shmem::id_t shmemid = (tmp).Id(Shmem::IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead());
1606 0 : Shmem::SharedMemory* rawmem = LookupSharedMemory(shmemid);
1607 0 : if (rawmem) {
1608 0 : (*(v__)) = Shmem(Shmem::IHadBetterBeIPDLCodeCallingThis_OtherwiseIAmADoodyhead(), rawmem, shmemid);
1609 0 : return true;
1610 : }
1611 0 : (*(v__)) = Shmem();
1612 0 : return true;
1613 : }
1614 :
1615 :
1616 :
1617 : } // namespace dom
1618 : } // namespace mozilla
|