Browse Source

imgutils: Fix a typo in avcodec_get_pix_fmt_loss

If the candidate does not have alpha and the source does have alpha
report the loss of alpha.

CC: libav-stable@libav.org
tags/n2.8
Luca Barbato 9 years ago
parent
commit
47b447aaff
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavcodec/imgconvert.c

+ 1
- 1
libavcodec/imgconvert.c View File

@@ -78,7 +78,7 @@ int avcodec_get_pix_fmt_loss(enum AVPixelFormat dst_pix_fmt,
loss |= FF_LOSS_COLORSPACE;

if (has_alpha && !(dst_desc->flags & AV_PIX_FMT_FLAG_ALPHA) &&
(dst_desc->flags & AV_PIX_FMT_FLAG_ALPHA))
(src_desc->flags & AV_PIX_FMT_FLAG_ALPHA))
loss |= FF_LOSS_ALPHA;

if (dst_pix_fmt == AV_PIX_FMT_PAL8 && !is_gray(src_desc))


Loading…
Cancel
Save