Commit 41b05b84 authored by Andreas Rheinhardt's avatar Andreas Rheinhardt Committed by James Almer

avcodec/avcodec: Adapt the doc of av_bsf_send_packet to match its actual implementation.

Explicitly allowing empty packets to signal flushing helps getting rid
of special cases. It does not hinder the ability to send i.e.
timing-only packets, because one can send packets with zero size and
pkt->data set.
Signed-off-by: 's avatarAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: 's avatarJames Almer <jamrial@gmail.com>
parent a7245ade
......@@ -5946,11 +5946,13 @@ int av_bsf_init(AVBSFContext *ctx);
*
* @param pkt the packet to filter. The bitstream filter will take ownership of
* the packet and reset the contents of pkt. pkt is not touched if an error occurs.
* This parameter may be NULL, which signals the end of the stream (i.e. no more
* packets will be sent). That will cause the filter to output any packets it
* may have buffered internally.
* If pkt is empty (i.e. NULL, or pkt->data is NULL and pkt->side_data_elems zero),
* it signals the end of the stream (i.e. no more non-empty packets will be sent;
* sending more empty packets does nothing) and will cause the filter to output
* any packets it may have buffered internally.
*
* @return 0 on success, a negative AVERROR on error.
* @return 0 on success, a negative AVERROR on error. This function never fails if
* pkt is empty.
*/
int av_bsf_send_packet(AVBSFContext *ctx, AVPacket *pkt);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment