(use-modules (irrlicht))
-(define device (create-device 'opengl))
+;; Create device
+(define device (create-device 'software '(640 480) 16 #f #f #f))
+(when (not device)
+ (exit #f))
+
(define driver (get-video-driver device))
(define scene-manager (get-scene-manager device))
('opengl ffi-video:EDT_OPENGL)
('count ffi-video:EDT_COUNT)))
(wsize (make-c-struct ffi-core:dimension2d window-size)))
- (ffi:create-device driver wsize bits
- (if fullscreen 1 0)
- (if stencilbuffer 1 0)
- (if vsync 1 0))))
+ (let ((device (ffi:create-device driver wsize bits
+ (if fullscreen 1 0)
+ (if stencilbuffer 1 0)
+ (if vsync 1 0))))
+ (if (null-pointer? device) #f device))))
(define (get-video-driver device)
(ffi:get-video-driver device))