[vlc-devel] [PATCH 08/12] bluray: Adding support for overlay.

Hugo Beauzée-Luyssen beauze.h at gmail.com
Sun Jan 22 21:33:26 CET 2012


On Sun, Jan 22, 2012 at 8:32 PM, Hugo Beauzée-Luyssen
<beauze.h at gmail.com> wrote:
> On Sun, Jan 22, 2012 at 5:26 PM, Laurent Aimar <fenrir at elivagar.org> wrote:
>> On Sun, Jan 22, 2012 at 05:06:57PM +0100, Hugo Beauzée-Luyssen wrote:
>>> > If you need to update it later, you have 2 choices:
>>> >  - you can send a new one to invalid the previous one (if you use ephemere
>>> >  subpictures)
>>> >  - you can use the subpicture_updater_t facility. In this case, you need to
>>> >  properly lock and refcount things as subpicture_updater_t functions will
>>> >  be called asynchronously from the vout thread.
>>
>>> Attached are two patches that handle overlay updating using
>>> subpicture_updater_t, thus without using the subpicture_t directly
>>> once it has been sent to the vout.
>>> Thanks for the review!
>>
>>
>>> +struct subpicture_updater_sys_t
>>> +{
>>> +    demux_sys_t *p_demux_sys;
>>> +    int         i_plane;
>>> +};
>>  Becareful, the vout can outlive the demuxer and thus accessing p_demux_sys
>> from the updater callbacks may not always be valid.
>>  You could create a structure that holds what is needed for the subpictures
>> and for the demuxer and then use refcounting (vlc_gc_* could be used).
>>
>> Regards
>>
>
> These patches should solve it.
>
> Regards,
>

Hmmm the previous patch wasn't holding the ressource for the demux
thread. This patch does (and it removes a debuging msg_Err)

Regards,


-- 
Hugo Beauzée-Luyssen
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0014-bluray-Use-refcounting-to-avoid-accessing-invalid-fi.patch
Type: text/x-patch
Size: 14299 bytes
Desc: not available
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20120122/a69fa63e/attachment.bin>


More information about the vlc-devel mailing list