]> git.jsancho.org Git - guile-irrlicht.git/commitdiff
More options
authorJavier Sancho <jsf@jsancho.org>
Thu, 3 Oct 2019 08:58:56 +0000 (10:58 +0200)
committerJavier Sancho <jsf@jsancho.org>
Thu, 3 Oct 2019 08:58:56 +0000 (10:58 +0200)
irrlicht.scm
irrlicht/bindings.scm

index 8c5178001bdd8384238219fd8347165c7cb95974..39c8ca4383823e8a90d8b42ccfc1b980cfd309b2 100644 (file)
 
 (define* (create-device #:optional
                         (device-type 'software)
-                        (window-size '(640 480)))
+                        (window-size '(640 480))
+                        (bits 16)
+                        (fullscreen #f)
+                        (stencilbuffer #f)
+                        (vsync #f))
   (let ((driver (match device-type
                        ('null ffi-video:EDT_NULL)
                        ('software ffi-video:EDT_SOFTWARE)
@@ -38,4 +42,7 @@
                        ('opengl ffi-video:EDT_OPENGL)
                        ('count ffi-video:EDT_COUNT)))
         (wsize (make-c-struct ffi-core:dimension2d window-size)))
-    (ffi:create-device driver wsize)))
+    (ffi:create-device driver wsize bits
+                       (if fullscreen 1 0)
+                       (if stencilbuffer 1 0)
+                       (if vsync 1 0))))
index d2647ffc4a1f3cdf24d734e060d8c906f603f402..f17557f6099e090ee0c2e7fd1856a13d03483203 100644 (file)
@@ -28,4 +28,4 @@
   (pointer->procedure
    int
    (dynamic-func "irr_createDevice" cirr)
-   (list int '*)))
+   (list int '* uint32 int int int)))