[vlc-devel] [PATCH 1/8] Add CALayer module

David Menestrina dmenest-vlc at ofb.net
Fri Sep 10 19:30:25 CEST 2010

On Fri, Sep 10, 2010 at 1:03 AM, Pierre d'Herbemont <pdherbemont at free.fr> wrote:
> About the coding style, could you pick one, ie:
>> +    if( self = [super init] )
> and
>> +    if (currentpic != NULL)

I get to choose?  I am used to the latter, but then sometimes I
remember the official VLC coding style is the former.  I started to go
back and fix things up, but then I saw in another vout that the style
was inconsistent.  Anyways, if one style is preferred over the other,
let me know.

>> +    if( self = [super init] )
>> +    {
>> +        currentpic = NULL;
>> +        vd = p_vd;
>> +        pthread_mutex_init(&mutex, NULL);
> NSLock?

I believe the vout thread is a POSIX thread, not an NSThread.  And it
doesn't have a runloop or an autorelease pool.  So I avoided using NS*
stuff whereever possible.  Also, I'm a Linux guy, so I've never used
NSLock. :)  If it is better to use NSLock here given the above
considerations, let me know.


More information about the vlc-devel mailing list