]> git.sesse.net Git - vlc/blobdiff - modules/access/vcdx/demux.c
Removes trailing spaces. Removes tabs.
[vlc] / modules / access / vcdx / demux.c
index 386598800a0edff102b58941c29d9ff7ea5aed15..8382d79148c35716e234fb42c3fc768d0b91626f 100644 (file)
@@ -1,10 +1,10 @@
 /*****************************************************************************
  * demux.c: demux functions for dvdplay.
  *****************************************************************************
- * Copyright (C) 1998-2001 VideoLAN
- * $Id: demux.c,v 1.2 2003/11/09 00:52:32 rocky Exp $
+ * Copyright (C) 1998-2001 the VideoLAN team
+ * $Id$
  *
- * Author: Stéphane Borel <stef@via.ecp.fr>
+ * Author: Stéphane Borel <stef@via.ecp.fr>
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
  *****************************************************************************/
 
 /*****************************************************************************
  * Preamble
  *****************************************************************************/
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
 
 #include <vlc/vlc.h>
-#include <vlc/input.h>
-#include <vlc/intf.h>
-
-#include "../../demux/mpeg/system.h"
+#include <vlc_input.h>
+#include <vlc_access.h>
+#include <vlc_interface.h>
 
 #ifdef HAVE_UNISTD_H
 #   include <unistd.h>
@@ -41,7 +37,6 @@
 #include <fcntl.h>
 #include <sys/types.h>
 #include <sys/stat.h>
-#include <string.h>
 #include <errno.h>
 
 #ifdef STRNCASECMP_IN_STRINGS_H
@@ -49,6 +44,7 @@
 #endif
 
 #include "vcd.h"
+#include "vcdplayer.h"
 #include "intf.h"
 
 /* how many packets vcdx_Demux will read in each loop */
@@ -71,16 +67,16 @@ struct demux_sys_t
 };
 
 /*****************************************************************************
- * InitVCD: initializes structures
+ * VCDInit: initializes structures
  *****************************************************************************/
-int E_(InitVCD) ( vlc_object_t *p_this )
+int E_(VCDInit) ( vlc_object_t *p_this )
 {
     input_thread_t *p_input = (input_thread_t *)p_this;
-    vcd_data_t *    p_vcd = (vcd_data_t *)p_input->p_access_data;
+    vcd_data_t *    p_vcd = (vcd_data_t *)p_input->p_sys;
     demux_sys_t *   p_demux;
 
-    printf("++++ InitVCD CALLED\n");
-    
+    printf("++++ VCDInit CALLED\n");
 
     if( p_input->stream.i_method != INPUT_METHOD_VCD )
     {
@@ -94,7 +90,7 @@ int E_(InitVCD) ( vlc_object_t *p_this )
     }
 
     p_input->p_private = (void*)&p_demux->mpeg;
-    p_demux->p_module = module_Need( p_input, "mpeg-system", NULL );
+    p_demux->p_module = module_Need( p_input, "mpeg-system", NULL, 0 );
     if( p_demux->p_module == NULL )
     {
         free( p_input->p_demux_data );
@@ -114,9 +110,9 @@ int E_(InitVCD) ( vlc_object_t *p_this )
 }
 
 /*****************************************************************************
- * EndVCD: frees unused data
+ * VCDEnd: frees unused data
  *****************************************************************************/
-void E_(EndVCD) ( vlc_object_t *p_this )
+void E_(VCDEnd) ( vlc_object_t *p_this )
 {
     input_thread_t *p_input = (input_thread_t *)p_this;
     vcd_data_t *    p_vcd = p_input->p_demux_data->p_vcd;
@@ -177,7 +173,7 @@ static int Demux( input_thread_t * p_input )
         pgrm_descriptor_t * p_pgrm;
 
         /* when we receive still_time flag, we have to pause immediately */
-        input_SetStatus( p_input, INPUT_STATUS_PAUSE );
+        var_SetInteger( p_input, "state", PAUSE_S );
 
         vcdIntfStillTime( p_vcd->p_intf, p_vcd->i_still_time );
         p_vcd->i_still_time = 0;