(define-class <irrlicht-device> (<reference-counted>)
(irr-class #:init-value "IrrlichtDevice"))
+(define-method (close-device (device <irrlicht-device>))
+ (let ((closeDevice (get-irrlicht-proc "closeDevice" device)))
+ (closeDevice device)))
+
(define* (create-device #:key
(device-type 'software)
(window-size '(640 480))
(let ((yield (get-irrlicht-proc "yield" device)))
(yield device)))
-(export <irrlicht-device> create-device get-cursor-control get-file-system get-gui-environment
- get-scene-manager get-timer get-video-driver is-window-active? run set-event-receiver!
- set-resizable! set-window-caption! yield-device)
+(export <irrlicht-device> close-device create-device get-cursor-control get-file-system
+ get-gui-environment get-scene-manager get-timer get-video-driver is-window-active? run
+ set-event-receiver! set-resizable! set-window-caption! yield-device)
return scm_from_irr_pointer ("<irrlicht-device>", (void*) device);
}
+SCM
+IrrlichtDevice_closeDevice (SCM device)
+{
+ ((IrrlichtDevice*)scm_to_irr_pointer (device))->closeDevice ();
+ return SCM_UNSPECIFIED;
+}
+
SCM
IrrlichtDevice_getCursorControl (SCM device)
{
init_device (void)
{
DEFINE_GSUBR ("createDevice", 7, 0, 0, irr_createDevice);
+ DEFINE_GSUBR ("IrrlichtDevice_closeDevice", 1, 0, 0, IrrlichtDevice_closeDevice);
DEFINE_GSUBR ("IrrlichtDevice_getCursorControl", 1, 0, 0, IrrlichtDevice_getCursorControl);
DEFINE_GSUBR ("IrrlichtDevice_getFileSystem", 1, 0, 0, IrrlichtDevice_getFileSystem);
DEFINE_GSUBR ("IrrlichtDevice_getGUIEnvironment", 1, 0, 0, IrrlichtDevice_getGUIEnvironment);