[FFmpeg-cvslog] Make avcodec_find_best_pix_fmt_of_list const-correct

Michael Bradshaw git at videolan.org
Tue Sep 10 12:56:33 CEST 2013


ffmpeg | branch: master | Michael Bradshaw <mjbshaw at gmail.com> | Mon Sep  9 22:32:03 2013 -0600| [9b07d34efb122377a0c8735b4008d7fcdf3d1298] | committer: Michael Niedermayer

Make avcodec_find_best_pix_fmt_of_list const-correct

Signed-off-by: Michael Bradshaw <mjbshaw at gmail.com>
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9b07d34efb122377a0c8735b4008d7fcdf3d1298
---

 libavcodec/avcodec.h    |    2 +-
 libavcodec/imgconvert.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h
index 572c5fd..66d7a8b 100644
--- a/libavcodec/avcodec.h
+++ b/libavcodec/avcodec.h
@@ -4568,7 +4568,7 @@ int avcodec_get_pix_fmt_loss(enum AVPixelFormat dst_pix_fmt, enum AVPixelFormat
  * @param[out] loss_ptr Combination of flags informing you what kind of losses will occur.
  * @return The best pixel format to convert to or -1 if none was found.
  */
-enum AVPixelFormat avcodec_find_best_pix_fmt_of_list(enum AVPixelFormat *pix_fmt_list,
+enum AVPixelFormat avcodec_find_best_pix_fmt_of_list(const enum AVPixelFormat *pix_fmt_list,
                                             enum AVPixelFormat src_pix_fmt,
                                             int has_alpha, int *loss_ptr);
 
diff --git a/libavcodec/imgconvert.c b/libavcodec/imgconvert.c
index 1835e00..42c75a5 100644
--- a/libavcodec/imgconvert.c
+++ b/libavcodec/imgconvert.c
@@ -261,7 +261,7 @@ enum AVPixelFormat avcodec_find_best_pix_fmt2(enum AVPixelFormat dst_pix_fmt1, e
 }
 #endif
 
-enum AVPixelFormat avcodec_find_best_pix_fmt_of_list(enum AVPixelFormat *pix_fmt_list,
+enum AVPixelFormat avcodec_find_best_pix_fmt_of_list(const enum AVPixelFormat *pix_fmt_list,
                                             enum AVPixelFormat src_pix_fmt,
                                             int has_alpha, int *loss_ptr){
     int i;



More information about the ffmpeg-cvslog mailing list