Skip to content

Commit 8fbb02c

Browse files
committed
vcomp/lavc: print the list if no codec found
print_pix_fmts() is called `if (pix_fmt == AV_PIX_FMT_NONE || log_level >= LOG_LEVEL_VERBOSE)` But in the former case (if no pixel format was found) and log level < VERBOSE, nothihg was actually print, because the function used VERBOSE log level to the printout. Use the current log_level to be print unconditionally (if called).
1 parent 70f1ad2 commit 8fbb02c

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

src/video_compress/libavcodec.cpp

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -781,8 +781,9 @@ static int vaapi_init(struct AVCodecContext *s){
781781
#endif
782782

783783
void print_codec_supp_pix_fmts(const enum AVPixelFormat *first) {
784-
MSG(VERBOSE, "Codec supported pixel formats: " TBOLD("%s") "\n",
785-
get_avpixfmts_names(first));
784+
log_msg(log_level,
785+
MOD_NAME "Codec supported pixel formats: " TBOLD("%s") "\n",
786+
get_avpixfmts_names(first));
786787
}
787788

788789
void print_pix_fmts(const list<enum AVPixelFormat>
@@ -795,8 +796,9 @@ void print_pix_fmts(const list<enum AVPixelFormat>
795796
*pixfmts_it++ = c;
796797
}
797798
*pixfmts_it++ = AV_PIX_FMT_NONE;
798-
MSG(VERBOSE, "Supported pixel formats: " TBOLD("%s") "\n",
799-
get_avpixfmts_names(pixfmts));
799+
log_msg(log_level,
800+
MOD_NAME "Supported pixel formats: " TBOLD("%s") "\n",
801+
get_avpixfmts_names(pixfmts));
800802
}
801803

802804
/**

0 commit comments

Comments
 (0)