Commit 58794a90 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

Select V4L2 input before standard as per specification

parent eda97b3a
...@@ -1552,6 +1552,14 @@ static int OpenVideoDev( vlc_object_t *p_obj, demux_sys_t *p_sys, bool b_demux ) ...@@ -1552,6 +1552,14 @@ static int OpenVideoDev( vlc_object_t *p_obj, demux_sys_t *p_sys, bool b_demux )
} }
#endif #endif
/* Select input */
if( v4l2_ioctl( i_fd, VIDIOC_S_INPUT, &p_sys->i_selected_input ) < 0 )
{
msg_Err( p_obj, "cannot set input %u: %m", p_sys->i_selected_input );
goto error;
}
msg_Dbg( p_obj, "input set to %u", p_sys->i_selected_input );
/* Select standard */ /* Select standard */
bool bottom_first; bool bottom_first;
const char *stdname = p_sys->psz_standard; const char *stdname = p_sys->psz_standard;
...@@ -1626,15 +1634,6 @@ static int OpenVideoDev( vlc_object_t *p_obj, demux_sys_t *p_sys, bool b_demux ) ...@@ -1626,15 +1634,6 @@ static int OpenVideoDev( vlc_object_t *p_obj, demux_sys_t *p_sys, bool b_demux )
msg_Dbg( p_obj, "tuner audio mode set" ); msg_Dbg( p_obj, "tuner audio mode set" );
} }
/* Select input */
if( v4l2_ioctl( i_fd, VIDIOC_S_INPUT, &p_sys->i_selected_input ) < 0 )
{
msg_Err( p_obj, "cannot set input %u: %m", p_sys->i_selected_input );
goto error;
}
msg_Dbg( p_obj, "input set to %u", p_sys->i_selected_input );
/* Set audio input */ /* Set audio input */
if( p_sys->i_audio > 0 ) if( p_sys->i_audio > 0 )
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment