[Ffmpeg-devel] [PATCH] Pass a context to av_log() in libswscale
Luca Abeni
lucabe72
Fri Jan 5 10:20:36 CET 2007
Hi Michael,
On Thu, 2007-01-04 at 17:48 +0100, Michael Niedermayer wrote:
[...]
> >
> > - MSG_WARN("No accelerated colorspace conversion found\n");
> > + av_log(c, AV_LOG_DEBUG, "No accelerated colorspace conversion found\n");
>
> hmm, shuldnt WARN->INFO rather?
Well, in the patch I respected the current mapping, that is
WARN -> DEBUG
FATAL -> ERROR
ERR -> ERROR
V -> INFO
DBG2 -> DEBUG
INFO -> INFO
Is "WARN->INFO" the only needed change, or should some other mapping be
changed? Let me know, and I'll update the patch.
> maybe we should also consider to increase the number of AV_LOG_* iam not sure
> though
We currently have: QUIET, ERROR, INFO, DEBUG. To have a 1->1 mapping
with the levels used in libswscale, we would need to add FATAL, WARNING,
and VERBOSE. I think this would result in an ABI incompatibility, so I
am not sure if it is worth doing it.
Anyway, if we decide to add some debug levels I'd like to do it before
committing this patch (otherwise, I would have to change the libswscale
code 2 times :).
> besides that, patch is ok assuimig it works with both ffmpeg and mplayer
I did some quick tests with both mplayer and ffmpeg yesterday, and
things seem to be ok (if someone has some particular mplayer's command
line that I should test, let me know).
> [...]
>
> > @@ -1991,6 +1997,7 @@
> > c= av_malloc(sizeof(SwsContext));
> > memset(c, 0, sizeof(SwsContext));
>
> offtopic but that should be changed to av_mallocz()
Ok, I'll prepare a separate patch for this.
Thanks,
Luca
--
_____________________________________________________________________________
Copy this in your signature, if you think it is important:
N O W A R ! ! !
More information about the ffmpeg-devel
mailing list