PageRenderTime 20ms CodeModel.GetById 18ms app.highlight 0ms RepoModel.GetById 1ms app.codeStats 0ms

/src/Core/CDROM.xs

http://github.com/PerlGameDev/SDL
Unknown | 29 lines | 22 code | 7 blank | 0 comment | 0 complexity | b4c530dfc8534cccc5ff6936bf1c9f24 MD5 | raw file
 1#include "EXTERN.h"
 2#include "perl.h"
 3#include "XSUB.h"
 4#include "ppport.h"
 5
 6#ifndef aTHX_
 7#define aTHX_
 8#endif
 9
10#include <SDL.h>
11
12MODULE = SDL::CDROM 	PACKAGE = SDL::CDROM    PREFIX = cd_
13
14int
15cd_num_drives()
16	CODE:
17		RETVAL = SDL_CDNumDrives();
18	OUTPUT:
19		RETVAL
20
21char *
22cd_name( drive )
23	int drive
24	CODE:
25		RETVAL = strdup(SDL_CDName(drive));
26	OUTPUT:
27		RETVAL
28
29