[Ffmpeg-devel] av_log() bloatedness

Michael Niedermayer michaelni
Mon Jul 17 23:58:50 CEST 2006


On Mon, Jul 17, 2006 at 10:50:37PM +0200, Fran?ois Revol wrote:
> > Hi
> >
> > instead of directly using av_log_callback() we have av_log() and
> > av_vlog()
> > instead of directly setting av_log_level we have av_log_get/
> > set_level()
> >
> How about, like, we might want to always log to a file #if DEBUG in add
> of calling av_log_callback someday... 

writing to a file can and should be done in the callback not in a hack
somewhere else

> or some custom profiling...

i cant see how a log functions is related to profiling

> I'd think it should also do some thread locking to serialize calls to
> the callback, well that's how it should be done.

no, the application should do that

> and what if the callback ptr is set to NULL ? (don't slap :p)

then the pointer will be NULL and that NULL will be as nullish with
or without 5 layers of set/get functions around 

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

In the past you could go to a library and read, borrow or copy any book
Today you'd get arrested for mere telling someone where the library is

More information about the ffmpeg-devel mailing list