1
mirror of https://github.com/mpv-player/mpv synced 2025-04-27 11:33:39 +02:00

Try to fix VCD compilation on non-Linux systems.

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@31023 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
reimar 2010-04-05 19:31:55 +00:00
parent 151e497922
commit d62bef6ee5
6 changed files with 26 additions and 1 deletions

@ -99,7 +99,7 @@ static int control(stream_t *stream, int cmd, void *arg) {
mp_vcd_priv_t *vcd = vcd_read_toc(stream->fd);
if (!vcd)
break;
*(unsigned int *)arg = vcd->tochdr.cdth_trk1;
*(unsigned int *)arg = vcd_end_track(vcd);
return STREAM_OK;
}
case STREAM_CTRL_SEEK_TO_CHAPTER:

@ -145,6 +145,11 @@ static mp_vcd_priv_t* vcd_read_toc(int fd){
return vcd;
}
static int vcd_end_track(mp_vcd_priv_t* vcd)
{
return vcd->tochdr.cdth_trk1;
}
static int vcd_read(mp_vcd_priv_t* vcd,char *mem){
#if defined(__linux__) || defined(__bsdi__)
memcpy(vcd->buf,&vcd->entry.cdte_addr.msf,sizeof(struct cdrom_msf));

@ -208,6 +208,11 @@ static mp_vcd_priv_t* vcd_read_toc(int fd)
return vcd;
}
static int vcd_end_track(mp_vcd_priv_t* vcd)
{
return vcd->hdr.lastTrackNumberInLastSessionLSB;
}
static int vcd_read(mp_vcd_priv_t* vcd,char *mem)
{
if (pread(vcd->fd,&vcd->buf,VCD_SECTOR_SIZE,vcd_get_msf(vcd)*VCD_SECTOR_SIZE) != VCD_SECTOR_SIZE)

@ -212,6 +212,11 @@ vcd_read_toc(int fd)
return vcd;
}
static int vcd_end_track(mp_vcd_priv_t* vcd)
{
return vcd->tochdr.ending_track;
}
static int
vcd_read(mp_vcd_priv_t* vcd, char *mem)
{

@ -188,6 +188,11 @@ static mp_vcd_priv_t *vcd_read_toc(int fd)
return vcd;
}
static int vcd_end_track(mp_vcd_priv_t* vcd)
{
return vcd->iLastTrack;
}
static int vcd_read(mp_vcd_priv_t *vcd, char *mem)
{
struct {

@ -132,6 +132,11 @@ static mp_vcd_priv_t* vcd_read_toc(int fd)
return vcd;
}
static int vcd_end_track(mp_vcd_priv_t* vcd)
{
return vcd->toc.LastTrack;
}
static int vcd_read(mp_vcd_priv_t* vcd, char *mem)
{
DWORD dwBytesReturned;