comparison src/cdrom/dc/SDL_syscdrom.c @ 1461:11134dc42da8

Updated for Dreamcast KOS June 2005 snapshot: http://cadcdev.sourceforge.net/svn/snapshots/ http://gamedev.allusion.net/softprj/kos/dcsetup.php
author Sam Lantinga <slouken@libsdl.org>
date Thu, 02 Mar 2006 13:16:02 +0000
parents d910939febfa
children 92947e3a18db
comparison
equal deleted inserted replaced
1460:d79e6b0c2c19 1461:11134dc42da8
84 for(i=0;i<cdrom->numtracks;i++) { 84 for(i=0;i<cdrom->numtracks;i++) {
85 unsigned long entry = toc.entry[i]; 85 unsigned long entry = toc.entry[i];
86 cdrom->track[i].id = i+1; 86 cdrom->track[i].id = i+1;
87 cdrom->track[i].type = (TOC_CTRL(toc.entry[i])==TRACK_CDDA)?SDL_AUDIO_TRACK:SDL_DATA_TRACK; 87 cdrom->track[i].type = (TOC_CTRL(toc.entry[i])==TRACK_CDDA)?SDL_AUDIO_TRACK:SDL_DATA_TRACK;
88 cdrom->track[i].offset = TOC_LBA(entry)-150; 88 cdrom->track[i].offset = TOC_LBA(entry)-150;
89 cdrom->track[i].length = TOC_LBA((i+1<toc.last)?toc.entry[i+1]:toc.dunno)-TOC_LBA(entry); 89 cdrom->track[i].length = TOC_LBA((i+1<toc.last)?toc.entry[i+1]:toc.leadout_sector)-TOC_LBA(entry);
90 } 90 }
91 91
92 return 0; 92 return 0;
93 } 93 }
94 94
95 /* Get CD-ROM status */ 95 /* Get CD-ROM status */
96 static CDstatus SDL_SYS_CDStatus(SDL_CD *cdrom, int *position) 96 static CDstatus SDL_SYS_CDStatus(SDL_CD *cdrom, int *position)
97 { 97 {
98 CDstatus status;
99 int ret,dc_status,disc_type; 98 int ret,dc_status,disc_type;
100 99
101 ret = cdrom_get_status(&dc_status,&disc_type); 100 ret = cdrom_get_status(&dc_status,&disc_type);
102 if (ret!=ERR_OK) return CD_ERROR; 101 if (ret!=ERR_OK) return CD_ERROR;
103 102