(make-c-struct vector3df data))
;; aabbox3df struct
-(define-public aabbox3df
+(define-wrapped-pointer-type aabbox3df
+ aabbox3df?
+ pointer->aabbox3df aabbox3df->pointer
+ (lambda (box port)
+ (format port "#<aabbox3df ~x>"
+ (pointer-address (aabbox3df->pointer box)))))
+
+(export aabbox3df->pointer)
+
+(define aabbox3df-type
(list vector3df vector3df))
-(define-public (aabbox3df->pointer data)
- (make-c-struct aabbox3df data))
+(define-public (make-aabbox3df)
+ (pointer->aabbox3df
+ (make-c-struct aabbox3df-type '((0 0 0) (0 0 0)))))
(define-foreign aabbox3d-add-internal-point
void "irr_core_aabbox3d_addInternalPoint" (list '* '*))
--- /dev/null
+;;; guile-irrlicht --- FFI bindings for Irrlicht Engine
+;;; Copyright (C) 2019 Javier Sancho <jsf@jsancho.org>
+;;;
+;;; This file is part of guile-irrlicht.
+;;;
+;;; Guile-irrlicht is free software; you can redistribute it and/or modify
+;;; it under the terms of the GNU Lesser General Public License as
+;;; published by the Free Software Foundation; either version 3 of the
+;;; License, or (at your option) any later version.
+;;;
+;;; Guile-irrlicht is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+;;; General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU Lesser General Public
+;;; License along with guile-irrlicht. If not, see
+;;; <http://www.gnu.org/licenses/>.
+
+
+(define-module (irrlicht core)
+ #:use-module ((irrlicht bindings core) #:prefix ffi-core:)
+ #:re-export ((ffi-core:make-aabbox3df . make-aabbox3df)))