[MPlayer-cvslog] r21258 - trunk/libmpcodecs/vd_ffmpeg.c
henry
subversion at mplayerhq.hu
Sun Nov 26 13:08:40 CET 2006
Author: henry
Date: Sun Nov 26 13:08:40 2006
New Revision: 21258
Modified:
trunk/libmpcodecs/vd_ffmpeg.c
Log:
Check the log level before processing the message
Modified: trunk/libmpcodecs/vd_ffmpeg.c
==============================================================================
--- trunk/libmpcodecs/vd_ffmpeg.c (original)
+++ trunk/libmpcodecs/vd_ffmpeg.c Sun Nov 26 13:08:40 2006
@@ -175,6 +175,15 @@
int mp_level;
char buf[256];
+ switch(level){
+ case AV_LOG_DEBUG: mp_level= MSGL_V ; break;
+ case AV_LOG_INFO : mp_level= MSGL_INFO; break;
+ case AV_LOG_ERROR: mp_level= MSGL_ERR ; break;
+ default : mp_level= MSGL_ERR ; break;
+ }
+
+ if (!mp_msg_test(type, mp_level)) return;
+
if(ptr){
if(!strcmp(avc->class_name, "AVCodecContext")){
AVCodecContext * s= ptr;
@@ -199,13 +208,6 @@
}
}
- switch(level){
- case AV_LOG_DEBUG: mp_level= MSGL_V ; break;
- case AV_LOG_INFO : mp_level= MSGL_INFO; break;
- case AV_LOG_ERROR: mp_level= MSGL_ERR ; break;
- default : mp_level= MSGL_ERR ; break;
- }
-
if(print_prefix && avc) {
mp_msg(type, mp_level, "[%s @ %p]", avc->item_name(ptr), avc);
}
More information about the MPlayer-cvslog
mailing list