| 1293 | } |
| 1294 | |
| 1295 | int RtmpStreamBase::SendCuePoint(const RtmpCuePoint& cuepoint) { |
| 1296 | butil::IOBuf req_buf; |
| 1297 | { |
| 1298 | butil::IOBufAsZeroCopyOutputStream zc_stream(&req_buf); |
| 1299 | AMFOutputStream ostream(&zc_stream); |
| 1300 | WriteAMFString(RTMP_AMF0_SET_DATAFRAME, &ostream); |
| 1301 | WriteAMFString(RTMP_AMF0_ON_CUE_POINT, &ostream); |
| 1302 | WriteAMFObject(cuepoint.data, &ostream); |
| 1303 | if (!ostream.good()) { |
| 1304 | LOG(ERROR) << "Fail to serialize cuepoint"; |
| 1305 | return -1; |
| 1306 | } |
| 1307 | } |
| 1308 | return SendMessage(cuepoint.timestamp, policy::RTMP_MESSAGE_DATA_AMF0, req_buf); |
| 1309 | } |
| 1310 | |
| 1311 | int RtmpStreamBase::SendMetaData(const RtmpMetaData& metadata, |
| 1312 | const butil::StringPiece& name) { |
nothing calls this directly
no test coverage detected