lavc: fix avcodec_find_best_pix_fmt() when there's more than 64 pixel formats
This fixed the problem where if there's more than 64 pixel formats defined avcodec_find_best_pix_fmt() returns the wrong pixel format. Signed-off-by: Matthew Einhorn <moiein2000@gmail.com> Signed-off-by: Stefano Sabatini <stefano.sabatini-lala@poste.it>
This commit is contained in:

committed by
Stefano Sabatini

parent
dc6c36ce46
commit
39f9601c10
@@ -3499,6 +3499,8 @@ int avcodec_get_pix_fmt_loss(enum PixelFormat dst_pix_fmt, enum PixelFormat src_
|
||||
* The pixel formats from which it chooses one, are determined by the
|
||||
* pix_fmt_mask parameter.
|
||||
*
|
||||
* Note, only the first 64 pixel formats will fit in pix_fmt_mask.
|
||||
*
|
||||
* @code
|
||||
* src_pix_fmt = PIX_FMT_YUV420P;
|
||||
* pix_fmt_mask = (1 << PIX_FMT_YUV422P) || (1 << PIX_FMT_RGB24);
|
||||
|
Reference in New Issue
Block a user