Menu

[r760]: / trunk / lispbuilder-sdl / base / rwops.lisp  Maximize  Restore  History

Download this file

20 lines (15 with data), 653 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
;; SDL (Simple Media Layer) library using CFFI for foreign function interfacing...
;; (C)2006 Justin Heyes-Jones <justinhj@gmail.com> and Luke Crook <luke@balooga.com>
;; Thanks to Frank Buss and Surendra Singh
;; see COPYING for license
;; This file contains some useful functions for using SDL from Common lisp
;; using sdl.lisp (the CFFI wrapper)
(in-package #:lispbuilder-sdl-base)
(defun create-RWops-from-file (filename)
(let ((file-path (namestring filename)))
(if (and (stringp file-path) (probe-file file-path))
(let ((rwops (sdl-cffi::sdl-RW-From-File file-path "rb")))
(if (is-valid-ptr rwops)
rwops
nil))
nil)))
Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.