[vlc-devel] [PATCH 1/2] demux: Implement legacy fallbacks in the modules

Hugo Beauzée-Luyssen hugo at beauzee.fr
Tue Jan 16 15:11:35 CET 2018


On Tue, Jan 16, 2018, at 2:54 PM, Denis Charmet wrote:
> Hi,
> 
> On 2018-01-16 14:11, Hugo Beauzée-Luyssen wrote:
> > This is a pre-requisite to revert
> > a2beb67ed706e299010c28d8733e2c0123b57168
> 
> Why changing all the demuxes and not just do something like the 
> following?
> 
> int demux_vaControl( demux_t *demux, int query, va_list args )
> {
>      int ret = demux->pf_control( demux, query, args );
>      if (ret != VLC_SUCCESS && demux->s != NULL)
>          ret = demux_vaControlHelper( p_demux->s, 0, -1, 0, 1, query, 
> args );
>      return ret;
> }
> 

I thought of simply adding a call to demux_vaControlHelper to all demuxers (which could indeed be done in demux_vaControl), but :
- I'm afraid of unforeseen consequences if adding some extra control sequences to quite a few demuxers, especially since this needs to be backported to 3.0
- The point was to avoid doing that in a demux helper, as it could potentially be used for demux filters, which don't have a stream.  Since demux_vaControlHelper uses the stream to implement the default behavior for most control, that seems like bad idea

Regards,


-- 
  Hugo Beauzée-Luyssen
  hugo at beauzee.fr


More information about the vlc-devel mailing list