MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / gen_bytes_read

Function gen_bytes_read

libavformat/rtmpproto.c:1018–1032  ·  view source on GitHub ↗

* Generate report on bytes read so far and send it to the server. */

Source from the content-addressed store, hash-verified

1016 * Generate report on bytes read so far and send it to the server.
1017 */
1018static int gen_bytes_read(URLContext *s, RTMPContext *rt, uint32_t ts)
1019{
1020 RTMPPacket pkt;
1021 uint8_t *p;
1022 int ret;
1023
1024 if ((ret = ff_rtmp_packet_create(&pkt, RTMP_NETWORK_CHANNEL, RTMP_PT_BYTES_READ,
1025 ts, 4)) < 0)
1026 return ret;
1027
1028 p = pkt.data;
1029 bytestream_put_be32(&p, rt->bytes_read);
1030
1031 return rtmp_send_packet(rt, &pkt, 0);
1032}
1033
1034static int gen_fcsubscribe_stream(URLContext *s, RTMPContext *rt,
1035 const char *subscribe)

Callers 1

get_packetFunction · 0.85

Calls 2

ff_rtmp_packet_createFunction · 0.85
rtmp_send_packetFunction · 0.85

Tested by

no test coverage detected