Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | |
|
palmer
2014/02/11 00:50:04
2014
acolwell GONE FROM CHROMIUM
2014/02/11 00:57:38
nit: s/(c) 2013/2014/
hubbe
2014/02/12 00:54:24
Done.
hubbe
2014/02/12 00:54:24
Done.
| |
| 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 transport API. | |
| 6 // Multiply-included message file, hence no include guard. | |
| 7 | |
| 8 #include "ipc/ipc_message_macros.h" | |
| 9 #include "media/cast/cast_sender.h" | |
| 10 #include "media/cast/rtcp/rtcp_defines.h" | |
| 11 #include "media/cast/transport/cast_transport_sender.h" | |
| 12 #include "net/base/ip_endpoint.h" | |
| 13 #include "net/base/net_util.h" | |
| 14 | |
| 15 #undef IPC_MESSAGE_EXPORT | |
| 16 #define IPC_MESSAGE_EXPORT | |
| 17 #define IPC_MESSAGE_START CastMsgStart | |
| 18 | |
| 19 IPC_ENUM_TRAITS(media::cast::transport::AudioCodec) | |
| 20 IPC_ENUM_TRAITS(media::cast::transport::VideoCodec) | |
| 21 IPC_ENUM_TRAITS(media::cast::transport::RtcpSenderFrameStatus) | |
| 22 IPC_ENUM_TRAITS(media::cast::transport::CastTransportStatus) | |
| 23 | |
| 24 IPC_STRUCT_TRAITS_BEGIN(media::cast::transport::EncodedAudioFrame) | |
| 25 IPC_STRUCT_TRAITS_MEMBER(codec) | |
| 26 IPC_STRUCT_TRAITS_MEMBER(frame_id) | |
| 27 IPC_STRUCT_TRAITS_MEMBER(rtp_timestamp) | |
| 28 IPC_STRUCT_TRAITS_MEMBER(data) | |
| 29 IPC_STRUCT_TRAITS_END() | |
| 30 | |
| 31 IPC_STRUCT_TRAITS_BEGIN(media::cast::transport::EncodedVideoFrame) | |
| 32 IPC_STRUCT_TRAITS_MEMBER(codec) | |
| 33 IPC_STRUCT_TRAITS_MEMBER(key_frame) | |
| 34 IPC_STRUCT_TRAITS_MEMBER(frame_id) | |
| 35 IPC_STRUCT_TRAITS_MEMBER(last_referenced_frame_id) | |
| 36 IPC_STRUCT_TRAITS_MEMBER(data) | |
| 37 IPC_STRUCT_TRAITS_END() | |
| 38 | |
| 39 IPC_STRUCT_TRAITS_BEGIN(media::cast::transport::RtcpSenderInfo) | |
| 40 IPC_STRUCT_TRAITS_MEMBER(ntp_seconds) | |
| 41 IPC_STRUCT_TRAITS_MEMBER(ntp_fraction) | |
| 42 IPC_STRUCT_TRAITS_MEMBER(rtp_timestamp) | |
| 43 IPC_STRUCT_TRAITS_MEMBER(send_packet_count) | |
| 44 IPC_STRUCT_TRAITS_MEMBER(send_octet_count) | |
| 45 IPC_STRUCT_TRAITS_END() | |
| 46 | |
| 47 IPC_STRUCT_TRAITS_BEGIN(media::cast::transport::RtcpDlrrReportBlock) | |
| 48 IPC_STRUCT_TRAITS_MEMBER(last_rr) | |
| 49 IPC_STRUCT_TRAITS_MEMBER(delay_since_last_rr) | |
| 50 IPC_STRUCT_TRAITS_END() | |
| 51 | |
| 52 IPC_STRUCT_TRAITS_BEGIN(media::cast::transport::RtcpSenderFrameLogMessage) | |
| 53 IPC_STRUCT_TRAITS_MEMBER(frame_status) | |
| 54 IPC_STRUCT_TRAITS_MEMBER(rtp_timestamp) | |
| 55 IPC_STRUCT_TRAITS_END() | |
| 56 | |
| 57 IPC_STRUCT_TRAITS_BEGIN(media::cast::transport::RtpConfig) | |
| 58 IPC_STRUCT_TRAITS_MEMBER(history_ms) | |
| 59 IPC_STRUCT_TRAITS_MEMBER(max_delay_ms) | |
| 60 IPC_STRUCT_TRAITS_MEMBER(payload_type) | |
| 61 IPC_STRUCT_TRAITS_END() | |
| 62 | |
| 63 IPC_STRUCT_TRAITS_BEGIN(media::cast::transport::CastTransportConfig) | |
| 64 IPC_STRUCT_TRAITS_MEMBER(receiver_endpoint) | |
| 65 IPC_STRUCT_TRAITS_MEMBER(local_endpoint) | |
| 66 IPC_STRUCT_TRAITS_MEMBER(audio_ssrc) | |
| 67 IPC_STRUCT_TRAITS_MEMBER(video_ssrc) | |
| 68 IPC_STRUCT_TRAITS_MEMBER(video_codec) | |
| 69 IPC_STRUCT_TRAITS_MEMBER(audio_codec) | |
| 70 IPC_STRUCT_TRAITS_MEMBER(audio_frequency) | |
| 71 IPC_STRUCT_TRAITS_MEMBER(audio_channels) | |
| 72 IPC_STRUCT_TRAITS_MEMBER(audio_rtp_config) | |
| 73 IPC_STRUCT_TRAITS_MEMBER(video_rtp_config) | |
| 74 IPC_STRUCT_TRAITS_MEMBER(aes_key) | |
| 75 IPC_STRUCT_TRAITS_MEMBER(aes_iv_mask) | |
| 76 IPC_STRUCT_TRAITS_END() | |
| 77 | |
| 78 IPC_STRUCT_TRAITS_BEGIN(media::cast::transport::SendRtcpFromRtpSenderData) | |
| 79 IPC_STRUCT_TRAITS_MEMBER(packet_type_flags) | |
| 80 IPC_STRUCT_TRAITS_MEMBER(sending_ssrc) | |
| 81 IPC_STRUCT_TRAITS_MEMBER(c_name) | |
| 82 IPC_STRUCT_TRAITS_END() | |
| 83 | |
| 84 | |
| 85 // Cast messages sent from the browser to the renderer. | |
| 86 | |
| 87 IPC_MESSAGE_CONTROL2(CastMsg_ReceivedPacket, | |
| 88 int32 /* channel_id */, | |
| 89 media::cast::Packet /* packet */); | |
| 90 | |
| 91 IPC_MESSAGE_CONTROL2( | |
| 92 CastMsg_NotifyStatusChange, | |
| 93 int32 /* channel_id */, | |
| 94 media::cast::transport::CastTransportStatus /* status */); | |
| 95 | |
| 96 IPC_MESSAGE_CONTROL5( | |
| 97 CastMsg_RtpStatistics, | |
| 98 int32 /* channel_id */, | |
| 99 bool /* audio */, | |
| 100 media::cast::transport::RtcpSenderInfo /* sender_info */, | |
| 101 base::TimeTicks /* time_sent */, | |
| 102 uint32 /* rtp_timestamp */); | |
| 103 | |
| 104 | |
| 105 // Cast messages sent from the renderer to the browser. | |
| 106 | |
| 107 IPC_MESSAGE_CONTROL3( | |
| 108 CastHostMsg_InsertCodedAudioFrame, | |
| 109 int32 /* channel_id */, | |
| 110 media::cast::transport::EncodedAudioFrame /* audio_frame */, | |
| 111 base::TimeTicks /* recorded_time */) | |
| 112 | |
| 113 IPC_MESSAGE_CONTROL3( | |
| 114 CastHostMsg_InsertCodedVideoFrame, | |
| 115 int32 /* channel_id */, | |
| 116 media::cast::transport::EncodedVideoFrame /* video_frame */, | |
| 117 base::TimeTicks /* recorded_time */) | |
| 118 | |
| 119 IPC_MESSAGE_CONTROL5( | |
| 120 CastHostMsg_SendRtcpFromRtpSender, | |
| 121 int32 /* channel_id */, | |
| 122 media::cast::transport::SendRtcpFromRtpSenderData /* flags, ssrc, name */, | |
| 123 media::cast::transport::RtcpSenderInfo /* sender_info */, | |
| 124 media::cast::transport::RtcpDlrrReportBlock /* dlrr */, | |
| 125 media::cast::transport::RtcpSenderLogMessage /* sender_log */) | |
| 126 | |
| 127 IPC_MESSAGE_CONTROL3( | |
| 128 CastHostMsg_ResendPackets, | |
| 129 int32 /* channel_id */, | |
| 130 bool /* is_audio */, | |
| 131 media::cast::MissingFramesAndPacketsMap /* missing_packets */) | |
| 132 | |
| 133 IPC_MESSAGE_CONTROL2( | |
| 134 CastHostMsg_New, | |
| 135 int32 /* channel_id */, | |
| 136 media::cast::transport::CastTransportConfig /* config */); | |
| 137 | |
| 138 IPC_MESSAGE_CONTROL1( | |
| 139 CastHostMsg_Delete, | |
| 140 int32 /* channel_id */); | |
| OLD | NEW |