[MPlayer-cvslog] r37460 - in trunk/stream: stream.h stream_cue.c

ib subversion at mplayerhq.hu
Tue Aug 25 11:30:42 CEST 2015


Author: ib
Date: Tue Aug 25 11:30:41 2015
New Revision: 37460

Log:
Cosmetic: Remove all references to Video CDs from the identifiers.

Now that the cue stream driver supports both audio and video images,
don't reference to video CDs only, but name generically.

Modified:
   trunk/stream/stream.h
   trunk/stream/stream_cue.c

Modified: trunk/stream/stream.h
==============================================================================
--- trunk/stream/stream.h	Tue Aug 25 11:27:54 2015	(r37459)
+++ trunk/stream/stream.h	Tue Aug 25 11:30:41 2015	(r37460)
@@ -40,7 +40,7 @@
 #define STREAMTYPE_DVDNAV 9    // we cannot safely "seek" in this...
 #define STREAMTYPE_CDDA 10     // raw audio CD reader
 #define STREAMTYPE_SMB 11      // smb:// url, using libsmbclient (samba)
-#define STREAMTYPE_VCDBINCUE 12      // vcd directly from bin/cue files
+#define STREAMTYPE_BINCUE 12   // cd/vcd directly from bin/cue files
 #define STREAMTYPE_DVB 13
 #define STREAMTYPE_VSTREAM 14
 #define STREAMTYPE_SDP 15

Modified: trunk/stream/stream_cue.c
==============================================================================
--- trunk/stream/stream_cue.c	Tue Aug 25 11:27:54 2015	(r37459)
+++ trunk/stream/stream_cue.c	Tue Aug 25 11:30:41 2015	(r37460)
@@ -1,5 +1,5 @@
 /*
- * VideoCD BinCue
+ * AudioCD/VideoCD BinCue
  *
  * This file is part of MPlayer.
  *
@@ -475,7 +475,7 @@ static int cue_read_toc_entry(int track)
   return 0;
 }
 
-static int cue_vcd_get_track_end (int track){
+static int cue_get_track_end (int track){
   int sector = cue_msf_2_sector(tracks[track].minute, tracks[track].second,
                                 tracks[track].frame);
 
@@ -488,19 +488,19 @@ static int seek(stream_t *s, int64_t new
   return 1;
 }
 
-static int cue_vcd_seek_to_track (stream_t *stream, int track){
+static int cue_seek_to_track (stream_t *stream, int track){
   int pos;
   if (cue_read_toc_entry (track))
     return -1;
 
   pos = tracks[track-1].sector_data_length * cue_get_msf();
   stream->start_pos = pos;
-  stream->end_pos = cue_vcd_get_track_end(track);
+  stream->end_pos = cue_get_track_end(track);
   seek(stream, pos);
   return pos;
 }
 
-static void cue_vcd_read_toc(void){
+static void cue_read_toc(void){
   int i;
   for (i = 0; i < nTracks; ++i) {
 
@@ -515,7 +515,7 @@ static void cue_vcd_read_toc(void){
   }
 }
 
-static int cue_vcd_read(stream_t *stream, char *mem, int size) {
+static int cue_read(stream_t *stream, char *mem, int size) {
   unsigned long position, offset;
   int fd_bin = stream->fd;
   int track = cue_current_pos.track - 1;
@@ -567,7 +567,7 @@ static int control(stream_t *stream, int
     {
       int r;
       unsigned int track = *(unsigned int *)arg + 1;
-      r = cue_vcd_seek_to_track(stream, track);
+      r = cue_seek_to_track(stream, track);
       if (r >= 0) {
         return STREAM_OK;
       }
@@ -604,8 +604,8 @@ static int open_s(stream_t *stream,int m
   f = cue_read_cue(filename);
   if(f < 0)
     goto err_out;
-  cue_vcd_read_toc();
-  ret=cue_vcd_seek_to_track(stream, track);
+  cue_read_toc();
+  ret=cue_seek_to_track(stream, track);
   if(ret<0){
     mp_msg(MSGT_OPEN,MSGL_ERR,MSGTR_ErrTrackSelect " (seek)\n");
     goto err_out;
@@ -614,10 +614,10 @@ static int open_s(stream_t *stream,int m
          filename, track, ret, (int)stream->end_pos);
 
   stream->fd = f;
-  stream->type = STREAMTYPE_VCDBINCUE;
+  stream->type = STREAMTYPE_BINCUE;
   stream->sector_size = tracks[track-1].sector_data_length;
   stream->flags = STREAM_READ | MP_STREAM_SEEK_FW;
-  stream->fill_buffer = cue_vcd_read;
+  stream->fill_buffer = cue_read;
   stream->seek = seek;
   stream->control = control;
 


More information about the MPlayer-cvslog mailing list