ClanLib  2.3.7
List of all members
CL_CDDrive Class Reference

CD drive audio interface. More...

#include <cd_drive.h>

Public Member Functions

Construction
 CL_CDDrive ()
 Constructs a null instance. More...
 
virtual ~CL_CDDrive ()
 
Operations
bool play_tracks (int track, int end_track=0)
 Play from track 'track' til track 'end_track'. More...
 
bool play_frames (int frame, int end_frame=0)
 Play from frame 'frame' to 'end_frame'. More...
 
bool play_track (int track)
 Play track 'track'. Returns true if successful. More...
 
void stop ()
 Stop playing. More...
 
void pause ()
 Pause the playback. More...
 
void resume ()
 Resume the playback. More...
 

Attributes

bool is_null () const
 Returns true if this object is invalid. More...
 
void throw_if_null () const
 Throw an exception if this object is invalid. More...
 
CL_String8 get_drive_path ()
 Get the path of the CD drive. More...
 
CL_String8 get_cd_name ()
 Get the name of the CD. More...
 
int get_num_tracks ()
 Get the number of tracks available on the cd. More...
 
bool is_playing ()
 Returns true if the CD drive is playing. More...
 
int get_cur_track ()
 Returns the current track. More...
 
int get_cur_frame ()
 Returns the current frame on the track. More...
 
static std::vector< CL_CDDrive > & get_drives ()
 Returns the amount of CD drives available on the system. More...
 

Detailed Description

CD drive audio interface.

Use this class to control the CDROM drive in your computer.

Constructor & Destructor Documentation

CL_CDDrive::CL_CDDrive ( )

Constructs a null instance.

Use get_drives() instead

virtual CL_CDDrive::~CL_CDDrive ( )
virtual

Member Function Documentation

CL_String8 CL_CDDrive::get_cd_name ( )

Get the name of the CD.

int CL_CDDrive::get_cur_frame ( )

Returns the current frame on the track.

int CL_CDDrive::get_cur_track ( )

Returns the current track.

CL_String8 CL_CDDrive::get_drive_path ( )

Get the path of the CD drive.

static std::vector<CL_CDDrive>& CL_CDDrive::get_drives ( )
static

Returns the amount of CD drives available on the system.

int CL_CDDrive::get_num_tracks ( )

Get the number of tracks available on the cd.

bool CL_CDDrive::is_null ( ) const
inline

Returns true if this object is invalid.

bool CL_CDDrive::is_playing ( )

Returns true if the CD drive is playing.

void CL_CDDrive::pause ( )

Pause the playback.

bool CL_CDDrive::play_frames ( int  frame,
int  end_frame = 0 
)

Play from frame 'frame' to 'end_frame'.

Parameters
frameBegin frame.
end_frameEnd frame.
bool CL_CDDrive::play_track ( int  track)

Play track 'track'. Returns true if successful.

bool CL_CDDrive::play_tracks ( int  track,
int  end_track = 0 
)

Play from track 'track' til track 'end_track'.

Parameters
trackBegin track.
end_trackEnd track.
void CL_CDDrive::resume ( )

Resume the playback.

void CL_CDDrive::stop ( )

Stop playing.

void CL_CDDrive::throw_if_null ( ) const

Throw an exception if this object is invalid.


The documentation for this class was generated from the following file: