[vlc-devel] Re: Patch: DirectShow does not set tuner card input

Patrick Horn patrick.horn at mindspring.com
Thu Jun 29 10:47:57 CEST 2006


Hi,
I made a small but significant mistake when I wrote the input patch.

But in modules/access/dshow/dshow.cpp (line 458), I had checked if it 
was greater than zero:
          var_Get( p_this, "dshow-video-input", &val );
            if( val.i_int > 0 )
                    p_sys->crossbar_routes[i].VideoInputIndex=val.i_int;
            var_Get( p_this, "dshow-video-output", &val );
            if( val.i_int > 0 )
                    p_sys->crossbar_routes[i].VideoOutputIndex=val.i_int;
            var_Get( p_this, "dshow-audio-input", &val );
            if( val.i_int > 0 )
                    p_sys->crossbar_routes[i].AudioInputIndex=val.i_int;
            var_Get( p_this, "dshow-audio-output", &val );
            if( val.i_int > 0 )
                    p_sys->crossbar_routes[i].AudioOutputIndex=val.i_int;

This unfortunately doesn't allow changing the input pin back to 0 
(composite for my card) without going through the device options screen.

Changing these four options to
if ( val.i_int >= 0 )
will allow these options to work correctly.

This should not break anything because the defaults for all of these 
options is already -1, not 0.

Thanks,
Patrick

Christophe Mutricy wrote:
> On Sun, Mar 05, 06 at 01:53 -0800, Patrick Horn wrote:
>   
>> I attached a clean and simple patch to add four new module options that 
>> set the crossbar indicies.
>>
>> --dshow-video-input => p_sys->crossbar_routes[i].VideoInputIndex
>> --dshow-audio-input => p_sys->crossbar_routes[i].AudioInputIndex
>> --dshow-video-output => p_sys->crossbar_routes[i].VideoOutputIndex
>> --dshow-audio-output => p_sys->crossbar_routes[i].AudioOutputIndex
>>     
>
> Applied. Thanks for your contribution.
>
>
> --
> Xtophe
>
>   

-- 
This is the vlc-devel mailing-list, see http://www.videolan.org/vlc/
To unsubscribe, please read http://developers.videolan.org/lists.html



More information about the vlc-devel mailing list