[MPlayer-dev-eng] [PATCH] ad_ffmpeg does not honor log level

Vlad Seryakov vseryakov at gmail.com
Sat Aug 21 19:09:27 CEST 2010


On Aug 21, 2010, at 9:41 AM, Diego Biurrun wrote:
>>>> +      case 7:
>>>> +      case 8:
>>>> +      case 9:
>>>> +      case 10: av_log_set_level(AV_LOG_VERBOSE); break;
>>>> +      }
>>> 
>>> This could use a default case.
>>> 
>> I am not sure if INFO is a good choice for default but this is what is
>> default in avutil/log.c so at least it preserves default logging level
> 
> I was thinking about the empty cases for 7, 8, 9.  Why are they empty?
> 

In ffmpeg these levels fall into verbose category and verbose cannot be default level

>> --- libmpcodecs/ad_ffmpeg.c	(revision 31984)
>> +++ libmpcodecs/ad_ffmpeg.c	(working copy)
>> @@ -99,6 +99,18 @@
>> +      
>> +      switch(verbose){
>> +      case MSGL_FATAL: av_log_set_level(AV_LOG_FATAL); break;
>> +      case MSGL_ERR:   av_log_set_level(AV_LOG_ERROR); break;
>> +      case MSGL_WARN:  av_log_set_level(AV_LOG_WARNING); break;
>> +      case MSGL_INFO:  av_log_set_level(AV_LOG_INFO); break;
>> +      case MSGL_V:     av_log_set_level(AV_LOG_DEBUG); break;
> 
> Align the break statements for even better readability.
> 

-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: avlog.txt
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20100821/b39705c0/attachment.txt>
-------------- next part --------------



More information about the MPlayer-dev-eng mailing list