+++ /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 io)
- #:use-module (ice-9 match)
- #:use-module (system foreign)
- #:use-module ((irrlicht bindings io) #:prefix ffi-io:)
- #:use-module (irrlicht util)
- #:export (add-file-archive!))
-
-(define* (add-file-archive! file-system filename
- #:key
- (ignore-case #t)
- (ignore-paths #t)
- (archive-type 'unknown)
- (password "")
- (ret-archive %null-pointer))
- (let ((type (match archive-type
- ('zip ffi-io:EFAT_ZIP)
- ('gzip ffi-io:EFAT_GZIP)
- ('folder ffi-io:EFAT_FOLDER)
- ('pak ffi-io:EFAT_PAK)
- ('npk ffi-io:EFAT_NPK)
- ('tar ffi-io:EFAT_TAR)
- ('wad ffi-io:EFAT_WAD)
- ('unknown ffi-io:EFAT_UNKNOWN))))
- (ffi-io:add-file-archive file-system
- (string->pointer filename)
- (bool->integer ignore-case)
- (bool->integer ignore-paths)
- type
- (string->pointer password)
- ret-archive)))