[vlc-devel] Re: ps.c and VCD's use

Gildas Bazin gbazin at netcourrier.com
Thu Jul 24 01:29:16 CEST 2003


On Wednesday 23 July 2003 05:33, R. Bernstein wrote:
> Found a solution to my problem. Not elegant, but it works.
>  > ... The Chapter Up/Down buttons don't have any effect.
>  > These buttons probably need trigger a call VCDSeek somehow and I don't 
see
>  > how that cause and effect is supposed to happen. Clues? 
> 
> What I noticed is that the only thing I can guarentee is that i_part
> in the selected area changes. So I save i_part (or the current entry)
> internally and compare with the selected area i_part ON EACH READ. If
> i_part changes with respect to what I've saved, I do an internal
> "seek" accordingly. It would be more elegant to say have a callback
> from the button press so a test on each read doesn't have to be done.
> 

Afaik you don't have to do that because you know when the user changes the 
normal flow of the reading (seek, chapter/title change).

I suppose you already had a look at modules/access/dvdplay/access.c ?

The inportant functions here are:

    p_input->pf_read = dvdplay_Read;
    p_input->pf_seek = dvdplay_Seek;
    p_input->pf_set_area = dvdplay_SetArea;

pf_set_area should be called on each chapter or title change so you should 
be able to track the changes you want.

> A remaining open problem is how to set a VCD configuration variable. 
> 

What do you mean exactly by VCD configuration variables ?
Do you mean the "chapter" and "title" variables that are used by the new 
interfaces to get/set the chapter/title value ?
The wxWindows/MacOSX interfaces use these kind of 'variables' to build their 
navigation menu.

(look for things like var_Create( p_input, "chapter", VLC_VAR_INTEGER | 
VLC_VAR_HASCHOICE ); in src/input/input_programs.c
or var_Change( p_input, "chapter", VLC_VAR_SETVALUE, &val, NULL );
in modules/dvdplay/access.c)

Hope this helps,

--
Gildas

-- 
This is the vlc-devel mailing-list, see http://www.videolan.org/vlc/
To unsubscribe, please read http://developers.videolan.org/lists.html
If you are in trouble, please contact <postmaster at videolan.org>



More information about the vlc-devel mailing list