Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

sdl_cdopen(3) [opensolaris man page]

SDL_CDOpen(3)							 SDL API Reference						     SDL_CDOpen(3)

NAME
SDL_CDOpen - Opens a CD-ROM drive for access. SYNOPSIS
#include "SDL.h" SDL_CD *SDL_CDOpen(int drive); DESCRIPTION
Opens a CD-ROM drive for access. It returns a SDL_CD structure on success, or NULL if the drive was invalid or busy. This newly opened CD- ROM becomes the default CD used when other CD functions are passed a NULL CD-ROM handle. Drives are numbered starting with 0. Drive 0 is the system default CD-ROM. EXAMPLES
SDL_CD *cdrom; int cur_track; int min, sec, frame; SDL_Init(SDL_INIT_CDROM); atexit(SDL_Quit); /* Check for CD drives */ if(!SDL_CDNumDrives()){ /* None found */ fprintf(stderr, "No CDROM devices available "); exit(-1); } /* Open the default drive */ cdrom=SDL_CDOpen(0); /* Did if open? Check if cdrom is NULL */ if(!cdrom){ fprintf(stderr, "Couldn't open drive: %s ", SDL_GetError()); exit(-1); } /* Print Volume info */ printf("Name: %s ", SDL_CDName(0)); printf("Tracks: %d ", cdrom->numtracks); for(cur_track=0;cur_track < cdrom->numtracks; cur_track++){ FRAMES_TO_MSF(cdrom->track[cur_track].length, &min, &sec, &frame); printf(" Track %d: Length %d:%d ", cur_track, min, sec); } SDL_CDClose(cdrom); SEE ALSO
SDL_CD, SDL_CDtrack, SDL_CDClose SDL
Tue 11 Sep 2001, 22:58 SDL_CDOpen(3)

Check Out this Related Man Page

SDL_CDOpen(3)							 SDL API Reference						     SDL_CDOpen(3)

NAME
SDL_CDOpen- Opens a CD-ROM drive for access. SYNOPSIS
#include "SDL.h" SDL_CD *SDL_CDOpen(int drive); DESCRIPTION
Opens a CD-ROM drive for access. It returns a SDL_CD structure on success, or NULL if the drive was invalid or busy. This newly opened CD- ROM becomes the default CD used when other CD functions are passed a NULL CD-ROM handle. Drives are numbered starting with 0. Drive 0 is the system default CD-ROM. EXAMPLES
SDL_CD *cdrom; int cur_track; int min, sec, frame; SDL_Init(SDL_INIT_CDROM); atexit(SDL_Quit); /* Check for CD drives */ if(!SDL_CDNumDrives()){ /* None found */ fprintf(stderr, "No CDROM devices available "); exit(-1); } /* Open the default drive */ cdrom=SDL_CDOpen(0); /* Did if open? Check if cdrom is NULL */ if(!cdrom){ fprintf(stderr, "Couldn't open drive: %s ", SDL_GetError()); exit(-1); } /* Print Volume info */ printf("Name: %s ", SDL_CDName(0)); printf("Tracks: %d ", cdrom->numtracks); for(cur_track=0;cur_track < cdrom->numtracks; cur_track++){ FRAMES_TO_MSF(cdrom->track[cur_track].length, &min, &sec, &frame); printf(" Track %d: Length %d:%d ", cur_track, min, sec); } SDL_CDClose(cdrom); SEE ALSO
SDL_CD, SDL_CDtrack, SDL_CDClose SDL
Tue 11 Sep 2001, 22:58 SDL_CDOpen(3)
Man Page

15 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Stupid Question?

I have a SparcStation 10 and it came with an external CD Rom Drive. I am trying to install Solaris 2.6 Server on this machine from the Cd Rom. At the OK> prompt I type "boot cdrom - browser" and I get an error: scsi device not found:error = -1 or something to that effect. Does anyone have any... (9 Replies)
Discussion started by: jskillet
9 Replies

2. UNIX for Advanced & Expert Users

Using CD drive remotely !

hi, could anyone tell me that how can i use a remote CD drive for installing solaris , cause my local Drive has peroblem. tell me the steps one by one. Rgrds, nikk:confused: (6 Replies)
Discussion started by: nikk
6 Replies

3. UNIX for Dummies Questions & Answers

Cdrom Problem!!!

Hi everybody: I have Solaris 8 installed on my little Enterprise 3500 and, for a cruel fate of the destiny, Im the admin.... Here is the problem: a week ago I took out a CD from the CDROM drive in an abnormal way. I inserted a clip in the little hole in the front of the drive because the button... (8 Replies)
Discussion started by: piltrafa
8 Replies

4. UNIX for Dummies Questions & Answers

New Drive problems

Sun Ultra 80 ... had to connect an additional drive. connect it according to hardware manual The problem is when i try to power on the system , it dosent start, .. like the system is dead. :( So i remove the new drive and voila ... power starts up . Can anyone pinpoint wats goin on here. ... (7 Replies)
Discussion started by: DPAI
7 Replies

5. UNIX for Dummies Questions & Answers

Can't open CDROM drive

Hi all, Thru the installation i get the message to insert oracle CD 2 into cdrom drive but does not come up. with eject cdrom i get the device is busy. what i have to do to open the cdrom drive and continue the installation? plz explain to complete the installation thanks grep (7 Replies)
Discussion started by: grep
7 Replies

6. UNIX for Dummies Questions & Answers

cdrom problems..

im running suse 8.1 and im having problems with my cdrom drives. i have one pextor12/10/32 cd burner, and one 8x generic ATAPI cdrom. i have the cdburner in /etc/fstab as /dev/cdrecorder and it mounts to /media/cdrecorder/ i have the cdrom in fstab as /dev/cdrom and it mounts to: (you guessed it)... (10 Replies)
Discussion started by: norsk hedensk
10 Replies

7. Programming

cd inserted event

:confused: i am programming in c and i need to start a procedure automatically when a cd is inserted. Anyone knows how can i do it? thanx (9 Replies)
Discussion started by: massimo_ratti
9 Replies

8. SuSE

mandrake problem

ihave mandrake 9.2 (will upgrade soon to 10) but anyways, i can't get the Hard drive or the CD-ROM or Floppy to show up on the desktop. can anyone help me out? (11 Replies)
Discussion started by: linux_newbe
11 Replies

9. UNIX for Advanced & Expert Users

CD Drive is busy

one problem which seems simple but i've faced many times is when i've used cd & want to eject, however i'm not in /dev/cdrom/... in any of my Xterms but it gives the message that the the CD drive is busy. the only thing i could do is /etc/init.d/volmgt stop & eject the CD manually but it doesn't... (6 Replies)
Discussion started by: nikk
6 Replies

10. Solaris

Ultra 2 CDROM Problem

I have a Ultra 2 running solaris9, I'm trying to do a boot cdrom to install Solaris 10. During the boot, the system can't find the CDROM drive. It shows up during a probe-scsi-all. Also, when booted to Solaris 9 I place a CD in the drive it takes almost 10 minutes before the CD is readable on the... (6 Replies)
Discussion started by: stocksj
6 Replies

11. Solaris

not able to boot from cdrom

Hi all am trying to boot the system from cdrom in single user mode , however when i am giving command boot cdrom -s i am getting below error Boot Device: /pci@1f,0/pci@1,1/ide@3/cdrom@2,0: f file and args: Can't read disk label Can't open disk label package can,t open boot device ... (17 Replies)
Discussion started by: kumarmani
17 Replies

12. OS X (Apple)

Failed Drive

I am trying to recover data off a drive that failed in my iMac. Apple returned the drive to me and I purchased a hard drive enclosure. I have been doing research on prices for data recovery services, way too expensive. I seen some links using Unix DD commands in the terminal none of which worked.... (6 Replies)
Discussion started by: KJ1906
6 Replies

13. Filesystems, Disks and Memory

"modprobe -r cdrom" error.

hello all, i used modprobe -r usb-storage its working properly but when i use the same command with cdrom module as modprobe -r cdrom it is giving error as Fatal error:module cdrom in use, but i dont have any thing in rom and not using it. thanx. (9 Replies)
Discussion started by: zius_oram
9 Replies

14. Solaris

Solaris 9 Reset Password - boot cdrom -s not working

Boot device : /pci@1f,4000/scsi@3/disk@0,0:a File and args: -s cdrom SunOS Release 5.9 Version Generic_118558-11 64-bit (6 Replies)
Discussion started by: agummad
6 Replies

15. UNIX for Beginners Questions & Answers

Cannot boot cdrom -s

Good Afternoon, I'm trying to boot from cdrom so I: bash-2.05# init 0 {1} ok boot cdrom -s and I get: Rebooting with command: boot cdrom -s Boot Device: /pci@1e,600000/ide@d/cdrom@2,0:f File and args: -s Can't read disk label. Can't open disk label package Evaluating: Can't open boot... (13 Replies)
Discussion started by: Stellaman1977
13 Replies