OLD | NEW |
| (Empty) |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 // IPC messages for the Cast Media Acceleration (CMA) pipeline. | |
6 // Multiply-included message file, hence no include guard. | |
7 | |
8 #include <stddef.h> | |
9 | |
10 #include "chromecast/common/media/cma_ipc_common.h" | |
11 #include "chromecast/common/media/cma_param_traits.h" | |
12 #include "chromecast/common/media/cma_param_traits_macros.h" | |
13 #include "chromecast/media/cma/pipeline/load_type.h" | |
14 #include "content/public/common/common_param_traits.h" | |
15 #include "ipc/ipc_message_macros.h" | |
16 #include "media/base/audio_decoder_config.h" | |
17 #include "media/base/buffering_state.h" | |
18 #include "media/base/pipeline_status.h" | |
19 #include "media/base/video_decoder_config.h" | |
20 #include "ui/gfx/ipc/gfx_param_traits.h" | |
21 #include "ui/gfx/ipc/skia/gfx_skia_param_traits.h" | |
22 | |
23 #undef IPC_MESSAGE_EXPORT | |
24 #define IPC_MESSAGE_EXPORT | |
25 #define IPC_MESSAGE_START CastMediaMsgStart | |
26 | |
27 // Messages sent from the renderer to the browser process. | |
28 | |
29 IPC_MESSAGE_CONTROL2(CmaHostMsg_CreateMedia, | |
30 int /* Media pipeline ID */, | |
31 chromecast::media::LoadType /* Load type */) | |
32 IPC_MESSAGE_CONTROL1(CmaHostMsg_DestroyMedia, | |
33 int /* Media pipeline ID */) | |
34 IPC_MESSAGE_CONTROL3(CmaHostMsg_SetCdm, | |
35 int /* Media pipeline ID */, | |
36 int /* render_frame_id */, | |
37 int /* cdm_id */) | |
38 IPC_MESSAGE_CONTROL2(CmaHostMsg_StartPlayingFrom, | |
39 int /* Media pipeline ID */, | |
40 base::TimeDelta /* Timestamp */) | |
41 IPC_MESSAGE_CONTROL1(CmaHostMsg_Flush, | |
42 int /* Media pipeline ID */) | |
43 IPC_MESSAGE_CONTROL1(CmaHostMsg_Stop, | |
44 int /* Media pipeline ID */) | |
45 IPC_MESSAGE_CONTROL2(CmaHostMsg_SetPlaybackRate, | |
46 int /* Media pipeline ID */, | |
47 double /* Playback rate */) | |
48 | |
49 IPC_MESSAGE_CONTROL3(CmaHostMsg_CreateAvPipe, | |
50 int /* Media pipeline ID */, | |
51 chromecast::media::TrackId /* Track ID */, | |
52 size_t /* Fifo size */) | |
53 IPC_MESSAGE_CONTROL3(CmaHostMsg_AudioInitialize, | |
54 int /* Media pipeline ID */, | |
55 chromecast::media::TrackId /* Track ID */, | |
56 ::media::AudioDecoderConfig /* Audio config */) | |
57 IPC_MESSAGE_CONTROL3(CmaHostMsg_VideoInitialize, | |
58 int /* Media pipeline ID */, | |
59 chromecast::media::TrackId /* Track ID */, | |
60 /* Video Config */ | |
61 std::vector<::media::VideoDecoderConfig>) | |
62 IPC_MESSAGE_CONTROL3(CmaHostMsg_SetVolume, | |
63 int /* Media pipeline ID */, | |
64 chromecast::media::TrackId /* Track ID */, | |
65 float /* Volume */) | |
66 IPC_MESSAGE_CONTROL2(CmaHostMsg_NotifyPipeWrite, | |
67 int /* Media pipeline ID */, | |
68 chromecast::media::TrackId /* Track ID */) | |
69 | |
70 // Messages from the browser to the renderer process. | |
71 | |
72 IPC_MESSAGE_CONTROL1(CmaMsg_FlushDone, int /* Media pipeline ID */) | |
73 IPC_MESSAGE_CONTROL4(CmaMsg_TimeUpdate, | |
74 int /* Media pipeline ID */, | |
75 base::TimeDelta /* Media time */, | |
76 base::TimeDelta /* Max media time */, | |
77 base::TimeTicks /* STC */) | |
78 IPC_MESSAGE_CONTROL2(CmaMsg_BufferingNotification, | |
79 int /* Media pipeline ID */, | |
80 media::BufferingState /* Buffering state */) | |
81 | |
82 IPC_MESSAGE_CONTROL5(CmaMsg_AvPipeCreated, | |
83 int /* Media pipeline ID */, | |
84 chromecast::media::TrackId /* Track ID */, | |
85 bool /* Status */, | |
86 base::SharedMemoryHandle /* Shared memory */, | |
87 base::FileDescriptor /* socket handle */) | |
88 IPC_MESSAGE_CONTROL3(CmaMsg_TrackStateChanged, | |
89 int /* Media pipeline ID */, | |
90 chromecast::media::TrackId /* Track ID */, | |
91 media::PipelineStatus /* Status */) | |
92 IPC_MESSAGE_CONTROL2(CmaMsg_NotifyPipeRead, | |
93 int /* Media pipeline ID */, | |
94 chromecast::media::TrackId /* Track ID */) | |
95 | |
96 IPC_MESSAGE_CONTROL2(CmaMsg_WaitForKey, | |
97 int /* Media pipeline ID */, | |
98 chromecast::media::TrackId /* Track ID */) | |
99 IPC_MESSAGE_CONTROL2(CmaMsg_Eos, | |
100 int /* Media pipeline ID */, | |
101 chromecast::media::TrackId /* Track ID */) | |
102 IPC_MESSAGE_CONTROL3(CmaMsg_PlaybackError, | |
103 int /* Media pipeline ID */, | |
104 chromecast::media::TrackId /* Track ID */, | |
105 media::PipelineStatus /* status */) | |
106 IPC_MESSAGE_CONTROL3(CmaMsg_PlaybackStatistics, | |
107 int /* Media pipeline ID */, | |
108 chromecast::media::TrackId /* Track ID */, | |
109 media::PipelineStatistics /* status */) | |
110 IPC_MESSAGE_CONTROL3(CmaMsg_NaturalSizeChanged, | |
111 int /* Media pipeline ID */, | |
112 chromecast::media::TrackId /* Track ID */, | |
113 gfx::Size /* Size */) | |
OLD | NEW |