#:use-module (irrlicht scene)
#:use-module (irrlicht video)
#:duplicates (merge-generics)
- #:re-export (add-animated-mesh-scene-node!
+ #:re-export (;; classes
+ <animated-mesh>
+ <animated-mesh-scene-node>
+ <attribute-exchanging-object>
+ <box3d>
+ <camera-scene-node>
+ <cursor-control>
+ <event>
+ <event-receiver>
+ <file-archive>
+ <file-system>
+ <gui-element>
+ <gui-environment>
+ <gui-static-text>
+ <irrlicht-device>
+ <key-map>
+ <material>
+ <mesh>
+ <mesh-scene-node>
+ <reference-counted>
+ <scene-manager>
+ <scene-node>
+ <scene-node-animator>
+ <texture>
+ <vertex3d>
+ <video-driver>
+ ;; methods
+ add-animated-mesh-scene-node!
add-animator!
add-camera-scene-node!
add-camera-scene-node-fps!
(define (make-box3d)
(let ((aabbox3d_make (get-irrlicht-proc "aabbox3d_make")))
- (make <box3d> #:irr-pointer (aabbox3d_make))))
+ (aabbox3d_make)))
(define-method (reset-box3d! (box3d <box3d>) init-value)
(let ((reset (get-irrlicht-proc "aabbox3d_reset")))
receiver))
(let* ((createDevice (get-irrlicht-proc "createDevice"))
- (device-pointer (createDevice device-type window-size bits fullscreen stencilbuffer
- vsync receiver)))
- (cond ((null-pointer? device-pointer)
+ (device (createDevice device-type window-size bits fullscreen stencilbuffer
+ vsync receiver)))
+ (cond ((null-object? device)
(error "In procedure create-device: Device cannot be created"))
(else
- (make <irrlicht-device> #:irr-pointer device-pointer)))))
+ device))))
(define-method (get-cursor-control (device <irrlicht-device>))
(let ((getCursorControl (get-irrlicht-proc "getCursorControl" device)))
- (make <cursor-control>
- #:irr-pointer (getCursorControl device))))
+ (getCursorControl device)))
(define-method (get-file-system (device <irrlicht-device>))
(let ((getFileSystem (get-irrlicht-proc "getFileSystem" device)))
- (make <file-system>
- #:irr-pointer (getFileSystem device))))
+ (getFileSystem device)))
(define-method (get-gui-environment (device <irrlicht-device>))
(let ((getGUIEnvironment (get-irrlicht-proc "getGUIEnvironment" device)))
- (make <gui-environment>
- #:irr-pointer (getGUIEnvironment device))))
+ (getGUIEnvironment device)))
(define-method (get-scene-manager (device <irrlicht-device>))
- (make <scene-manager>
- #:irr-pointer ((get-irrlicht-proc "getSceneManager" device) device)))
+ (let ((getSceneManager (get-irrlicht-proc "getSceneManager" device)))
+ (getSceneManager device)))
(define-method (get-video-driver (device <irrlicht-device>))
- (make <video-driver>
- #:irr-pointer ((get-irrlicht-proc "getVideoDriver" device) device)))
+ (let ((getVideoDriver (get-irrlicht-proc "getVideoDriver" device)))
+ (getVideoDriver device)))
(define-method (is-window-active? (device <irrlicht-device>))
(let ((isWindowActive (get-irrlicht-proc "isWindowActive" device)))
(let ((yield (get-irrlicht-proc "yield" device)))
(yield device)))
-(export create-device get-cursor-control get-file-system get-gui-environment get-scene-manager
- get-video-driver is-window-active? run set-window-caption! yield-device)
+(export <irrlicht-device> create-device get-cursor-control get-file-system get-gui-environment
+ get-scene-manager get-video-driver is-window-active? run set-window-caption! yield-device)
#:use-module (system foreign)
#:use-module (irrlicht base)
#:export (get-irrlicht-proc
- null-pointer?))
+ null-object?))
;; We use a hash table to store foreign irrlicht methods related with their
;; classes
(else
proc))))
-(define (null-pointer? pointer)
- (eq? pointer %null-pointer))
+(define (null-object? object)
+ (eq? (irr-pointer object) %null-pointer))
(parent (make <gui-element>))
(id -1)
(fill-background #f))
- (make <gui-static-text>
- #:irr-pointer
- ((get-irrlicht-proc "addStaticText" gui-environment parent)
- gui-environment
- text
- rectangle
- border
- word-wrap
- parent
- id
- fill-background))))
+ (let ((addStaticText (get-irrlicht-proc "addStaticText" gui-environment parent)))
+ (addStaticText gui-environment text rectangle border word-wrap parent
+ id fill-background))))
(define-method (draw-all (gui-environment <gui-environment>))
((get-irrlicht-proc "drawAll" gui-environment)
(let* ((addAnimatedMeshSceneNode (get-irrlicht-proc "addAnimatedMeshSceneNode"
scene-manager
parent))
- (node-pointer (addAnimatedMeshSceneNode scene-manager mesh parent id position
- rotation scale also-add-if-mesh-pointer-zero)))
- (cond ((null-pointer? node-pointer)
+ (node (addAnimatedMeshSceneNode scene-manager mesh parent id position
+ rotation scale also-add-if-mesh-pointer-zero)))
+ (cond ((null-object? node)
(error "In procedure add-animated-mesh-scene-node!: Scene node cannot be created"))
(else
- (make <animated-mesh-scene-node> #:irr-pointer node-pointer))))))
+ node)))))
(define-method (add-camera-scene-node! (scene-manager <scene-manager>) . rest)
(let-keywords rest #f
(lookat '(0 0 100))
(id -1)
(make-active #t))
- (make <camera-scene-node>
- #:irr-pointer
- ((get-irrlicht-proc "addCameraSceneNode" scene-manager parent)
- scene-manager
- parent
- position
- lookat
- id
- make-active))))
+ (let ((addCameraSceneNode (get-irrlicht-proc "addCameraSceneNode" scene-manager parent)))
+ (addCameraSceneNode scene-manager parent position lookat id make-active))))
(define-method (add-camera-scene-node-fps! (scene-manager <scene-manager>) . rest)
(let-keywords rest #f
(make-active #t))
(let ((addCameraSceneNodeFPS (get-irrlicht-proc "addCameraSceneNodeFPS"
scene-manager parent)))
- (make <camera-scene-node>
- #:irr-pointer
- (addCameraSceneNodeFPS scene-manager #:parent parent #:rotate-speed rotate-speed
- #:move-speed move-speed #:id id #:key-map-array key-map-array
- #:key-map-size key-map-size
- #:no-vertical-movement no-vertical-movement
- #:jump-speed jump-speed #:invert-mouse invert-mouse
- #:make-active make-active)))))
+ (addCameraSceneNodeFPS scene-manager #:parent parent #:rotate-speed rotate-speed
+ #:move-speed move-speed #:id id #:key-map-array key-map-array
+ #:key-map-size key-map-size
+ #:no-vertical-movement no-vertical-movement
+ #:jump-speed jump-speed #:invert-mouse invert-mouse
+ #:make-active make-active))))
(define-method (add-custom-scene-node! (scene-manager <scene-manager>) proc-render
proc-get-bounding-box proc-get-material-count
(rotation '(0 0 0))
(scale '(1 1 1)))
(let ((addCustomSceneNode (get-irrlicht-proc "addCustomSceneNode" scene-manager parent)))
- (make <scene-node>
- #:irr-pointer
- (addCustomSceneNode scene-manager proc-render proc-get-bounding-box proc-get-material-count
- proc-get-material parent id position rotation scale)))))
+ (addCustomSceneNode scene-manager proc-render proc-get-bounding-box proc-get-material-count
+ proc-get-material parent id position rotation scale))))
(define-method (add-octree-scene-node! (scene-manager <scene-manager>)
(mesh <animated-mesh>)
(minimal-polys-per-node 512)
(also-add-if-mesh-pointer-zero #f))
(let ((addOctreeSceneNode (get-irrlicht-proc "addOctreeSceneNode" scene-manager parent mesh)))
- (make <mesh-scene-node>
- #:irr-pointer
- (addOctreeSceneNode scene-manager mesh parent id minimal-polys-per-node
- also-add-if-mesh-pointer-zero)))))
+ (addOctreeSceneNode scene-manager mesh parent id minimal-polys-per-node
+ also-add-if-mesh-pointer-zero))))
(define-method (add-octree-scene-node! (scene-manager <scene-manager>)
(mesh <mesh>)
(minimal-polys-per-node 256)
(also-add-if-mesh-pointer-zero #f))
(let ((addOctreeSceneNode (get-irrlicht-proc "addOctreeSceneNode" scene-manager parent mesh)))
- (make <mesh-scene-node>
- #:irr-pointer
- (addOctreeSceneNode scene-manager mesh parent id minimal-polys-per-node
- also-add-if-mesh-pointer-zero)))))
+ (addOctreeSceneNode scene-manager mesh parent id minimal-polys-per-node
+ also-add-if-mesh-pointer-zero))))
(define-method (create-rotation-animator (scene-manager <scene-manager>) rotation-speed)
(let ((createRotationAnimator (get-irrlicht-proc "createRotationAnimator" scene-manager)))
- (make <scene-node-animator>
- #:irr-pointer
- (createRotationAnimator scene-manager rotation-speed))))
+ (createRotationAnimator scene-manager rotation-speed)))
(define-method (draw-all (scene-manager <scene-manager>))
((get-irrlicht-proc "drawAll" scene-manager)
(define-method (get-mesh (scene-manager <scene-manager>) filename)
(let* ((getMesh (get-irrlicht-proc "getMesh" scene-manager))
- (mesh-pointer (getMesh scene-manager filename)))
- (cond ((null-pointer? mesh-pointer)
+ (mesh (getMesh scene-manager filename)))
+ (cond ((null-object? mesh)
(error "In procedure get-mesh: Mesh cannot be created"))
(else
- (make <animated-mesh> #:irr-pointer mesh-pointer)))))
+ mesh))))
(define-method (get-root-scene-node (scene-manager <scene-manager>))
(let ((getRootSceneNode (get-irrlicht-proc "getRootSceneNode" scene-manager)))
- (make <scene-node> #:irr-pointer (getRootSceneNode scene-manager))))
+ (getRootSceneNode scene-manager)))
(export <scene-manager> add-animated-mesh-scene-node! add-camera-scene-node!
add-camera-scene-node-fps! add-custom-scene-node! add-octree-scene-node!
(normalize-normals #f)
(use-mip-maps #t))
(let ((SMaterial_make (get-irrlicht-proc "SMaterial_make")))
- (make <material>
- #:irr-pointer
- (SMaterial_make #:material-type material-type #:ambient-color ambient-color
- #:diffuse-color diffuse-color #:emissive-color emissive-color
- #:specular-color specular-color #:shininess shininess
- #:material-type-param material-type-param
- #:material-type-param-2 material-type-param-2
- #:thickness thickness #:z-buffer z-buffer #:anti-aliasing anti-aliasing
- #:color-mask color-mask #:color-material color-material
- #:blend-operation blend-operation
- #:polygon-offset-factor polygon-offset-factor
- #:polygon-offset-direction polygon-offset-direction
- #:wireframe wireframe #:point-cloud point-cloud
- #:gouraud-shading gouraud-shading #:lighting lighting
- #:z-write-enable z-write-enable #:backface-culling backface-culling
- #:frontface-culling frontface-culling #:fog-enable fog-enable
- #:normalize-normals normalize-normals #:use-mip-maps use-mip-maps))))
+ (SMaterial_make #:material-type material-type #:ambient-color ambient-color
+ #:diffuse-color diffuse-color #:emissive-color emissive-color
+ #:specular-color specular-color #:shininess shininess
+ #:material-type-param material-type-param
+ #:material-type-param-2 material-type-param-2
+ #:thickness thickness #:z-buffer z-buffer #:anti-aliasing anti-aliasing
+ #:color-mask color-mask #:color-material color-material
+ #:blend-operation blend-operation
+ #:polygon-offset-factor polygon-offset-factor
+ #:polygon-offset-direction polygon-offset-direction
+ #:wireframe wireframe #:point-cloud point-cloud
+ #:gouraud-shading gouraud-shading #:lighting lighting
+ #:z-write-enable z-write-enable #:backface-culling backface-culling
+ #:frontface-culling frontface-culling #:fog-enable fog-enable
+ #:normalize-normals normalize-normals #:use-mip-maps use-mip-maps)))
(export <material> make-material)
(getName video-driver)))
(define-method (get-texture (video-driver <video-driver>) filename)
- (make <texture>
- #:irr-pointer
- ((get-irrlicht-proc "getTexture" video-driver)
- video-driver
- filename)))
+ (let ((getTexture (get-irrlicht-proc "getTexture" video-driver)))
+ (getTexture video-driver filename)))
(define-method (set-material! (video-driver <video-driver>) (material <material>))
(let ((setMaterial (get-irrlicht-proc "setMaterial" video-driver)))
(define (make-vertex3d position normal color tcoords)
(let ((S3DVertex_make (get-irrlicht-proc "S3DVertex_make")))
- (make <vertex3d>
- #:irr-pointer
- (S3DVertex_make position normal color tcoords))))
+ (S3DVertex_make position normal color tcoords)))
(export <vertex3d> get-position make-vertex3d)
aabbox3d_make ()
{
core::aabbox3df* aabbox = new core::aabbox3df ();
- return scm_from_pointer ((void*)aabbox, NULL);
+ return scm_from_irr_pointer ("<box3d>", (void*) aabbox);
}
SCM
scm_to_bool (stencilbuffer),
scm_to_bool (vsync),
(IEventReceiver*)scm_to_irr_pointer (receiver));
- return scm_from_pointer ((void*)device, NULL);
+ return scm_from_irr_pointer ("<irrlicht-device>", (void*) device);
}
SCM
{
gui::ICursorControl* cursor_control =
((IrrlichtDevice*)scm_to_irr_pointer (device))->getCursorControl ();
- return scm_from_pointer ((void*)cursor_control, NULL);
+ return scm_from_irr_pointer ("<cursor-control>", (void*) cursor_control);
}
SCM
{
io::IFileSystem* file_system =
((IrrlichtDevice*)scm_to_irr_pointer (device))->getFileSystem ();
- return scm_from_pointer ((void*)file_system, NULL);
+ return scm_from_irr_pointer ("<file-system>", (void*) file_system);
}
SCM
{
gui::IGUIEnvironment* gui_env =
((IrrlichtDevice*)scm_to_irr_pointer (device))->getGUIEnvironment ();
- return scm_from_pointer ((void*)gui_env, NULL);
+ return scm_from_irr_pointer ("<gui-environment>", (void*) gui_env);
}
SCM
{
scene::ISceneManager* manager =
((IrrlichtDevice*)scm_to_irr_pointer (device))->getSceneManager ();
- return scm_from_pointer ((void*)manager, NULL);
+ return scm_from_irr_pointer ("<scene-manager>", (void*) manager);
}
SCM
{
ITimer* timer =
((IrrlichtDevice*)scm_to_irr_pointer (device))->getTimer ();
- return scm_from_pointer ((void*)timer, NULL);
+ return scm_from_irr_pointer ("<timer>", (void*) timer);
}
SCM
{
video::IVideoDriver* driver =
((IrrlichtDevice*)scm_to_irr_pointer (device))->getVideoDriver ();
- return scm_from_pointer ((void*)driver, NULL);
+ return scm_from_irr_pointer ("<video-driver>", (void*) driver);
}
SCM
virtual bool OnEvent (const SEvent& event)
{
- SCM wrapped_event = scm_from_irr_pointer ("irrlicht irr", "<event>", (void*) &event);
+ SCM wrapped_event = scm_from_irr_pointer ("<event>", (void*) &event);
return scm_to_bool (scm_call_1 (scm_on_event, wrapped_event));
}
};
CustomReceiver* receiver = new CustomReceiver (proc_on_event);
- return scm_from_irr_pointer ("irrlicht irr", "<event-receiver>", (void*) receiver);
+ return scm_from_irr_pointer ("<event-receiver>", (void*) receiver);
}
SCM
{
gui::IGUIElement* caller =
((SEvent*)scm_to_irr_pointer (event))->GUIEvent.Caller;
- return scm_from_pointer ((void*)caller, NULL);
+ return scm_from_irr_pointer ("<gui-element>", (void*) caller);
}
SCM
free (wtext);
free (wtooltiptext);
- return scm_from_pointer ((void*)button, NULL);
+ return scm_from_irr_pointer ("<gui-button>", (void*) button);
}
template <typename TParent>
scm_to_int32 (id));
free (wtext);
- return scm_from_pointer ((void*)editbox, NULL);
+ return scm_from_irr_pointer ("<gui-editbox>", (void*) editbox);
}
template <typename TParent>
wtext);
free (wtext);
- return scm_from_pointer ((void*) new_image, NULL);
+ return scm_from_irr_pointer ("<gui-image>", (void*) new_image);
}
template <typename TParent>
(TParent)scm_to_irr_pointer (parent),
scm_to_int32 (id),
scm_to_bool (draw_background));
- return scm_from_pointer ((void*)listbox, NULL);
+ return scm_from_irr_pointer ("<gui-listbox>", (void*) listbox);
}
template <typename TParent>
scm_to_rect_s32 (rectangle),
(TParent)scm_to_irr_pointer (parent),
scm_to_int32 (id));
- return scm_from_pointer ((void*)scrollbar, NULL);
+ return scm_from_irr_pointer ("<gui-scrollbar>", (void*) scrollbar);
}
template <typename TParent>
scm_to_bool (fill_background));
free (wtext);
- return scm_from_pointer ((void*)static_text, NULL);
+ return scm_from_irr_pointer ("<gui-static-text>", (void*) static_text);
}
template <typename TParent>
scm_to_int32 (id));
free (wtext);
- return scm_from_pointer ((void*)window, NULL);
+ return scm_from_irr_pointer ("<gui-window>", (void*) window);
}
SCM
{
gui::IGUIFont* font =
((gui::IGUIEnvironment*)scm_to_irr_pointer (gui_environment))->getBuiltInFont ();
- return scm_from_pointer ((void*)font, NULL);
+ return scm_from_irr_pointer ("<gui-font>", (void*) font);
}
SCM
gui::IGUIFont* font =
((gui::IGUIEnvironment*)scm_to_irr_pointer (gui_environment))->getFont (cfilename);
free (cfilename);
- return scm_from_pointer ((void*)font, NULL);
+ return scm_from_irr_pointer ("<gui-font>", (void*) font);
}
SCM
{
gui::IGUISkin* skin =
((gui::IGUIEnvironment*)scm_to_irr_pointer (gui_environment))->getSkin ();
- return scm_from_pointer ((void*)skin, NULL);
+ return scm_from_irr_pointer ("<gui-skin>", (void*) skin);
}
void
{
gui::IGUISkin* skin = (gui::IGUISkin*) scm_to_irr_pointer (gui_skin);
gui::IGUIFont* font = skin->getFont (scm_to_default_font (which));
- return scm_from_pointer ((void*) font, NULL);
+ return scm_from_irr_pointer ("<gui-font>", (void*) font);
}
SCM
free (wtext);
free (wtooltiptext);
- return scm_from_pointer ((void*) button, NULL);
+ return scm_from_irr_pointer ("<gui-button>", (void*) button);
}
void
#include "gsubr.h"
#include "material.h"
#include "material-types.h"
+#include "wrapped.h"
using namespace irr;
material->FogEnable = scm_to_bool (fog_enable);
material->NormalizeNormals = scm_to_bool (normalize_normals);
material->UseMipMaps = scm_to_bool (use_mip_maps);
- return scm_from_pointer ((void*) material, NULL);
+ return scm_from_irr_pointer ("<material>", (void*) material);
}
void
scm_to_vector3df (rotation),
scm_to_vector3df (scale),
scm_to_bool (also_add_if_mesh_pointer_zero));
- return scm_from_pointer ((void*) node, NULL);
+ return scm_from_irr_pointer ("<animated-mesh-scene-node>", (void*) node);
}
template <typename TParent>
scm_to_vector3df (lookat),
scm_to_int32 (id),
scm_to_bool (make_active));
- return scm_from_pointer ((void*) camera, NULL);
+ return scm_from_irr_pointer ("<camera-scene-node>", (void*) camera);
}
template <typename TParent>
scm_to_double (jump_speed),
scm_to_bool (invert_mouse),
scm_to_bool (make_active));
- return scm_from_pointer ((void*) camera, NULL);
+ return scm_from_irr_pointer ("<camera-scene-node>", (void*) camera);
}
template <typename TParent>
scm_to_vector3df (position),
scm_to_vector3df (rotation),
scm_to_vector3df (scale));
- return scm_from_pointer ((void*) node, NULL);
+ return scm_from_irr_pointer ("<mesh-scene-node>", (void*) node);
}
template <typename TParent>
proc_get_bounding_box,
proc_get_material_count,
proc_get_material);
- return scm_from_pointer ((void*) node, NULL);
+ return scm_from_irr_pointer ("<scene-node>", (void*) node);
}
template <typename TParent, typename TMesh>
scm_to_int32 (id),
scm_to_int32 (minimal_polys_per_node),
scm_to_bool (also_add_if_mesh_pointer_zero));
- return scm_from_pointer ((void*) node, NULL);
+ return scm_from_irr_pointer ("<mesh-scene-node>", (void*) node);
}
template <typename TParent>
scm_to_vector3df (position),
scm_to_vector3df (rotation),
scm_to_vector3df (scale));
- return scm_from_pointer ((void*) node, NULL);
+ return scm_from_irr_pointer ("<mesh-scene-node>", (void*) node);
}
SCM
scm_to_vector3df (direction),
scm_to_double (start_position),
scm_to_double (radius_ellipsoid));
- return scm_from_pointer ((void*) anim, NULL);
+ return scm_from_irr_pointer ("<scene-node-animator>", (void*) anim);
}
SCM
scm_to_uint32 (time_for_way),
scm_to_bool (loop),
scm_to_bool (pingpong));
- return scm_from_pointer ((void*) anim, NULL);
+ return scm_from_irr_pointer ("<scene-node-animator>", (void*) anim);
}
SCM
scene::ISceneManager* smgr = (scene::ISceneManager*) scm_to_irr_pointer (scene_manager);
scene::ISceneNodeAnimator* anim =
smgr->createRotationAnimator (scm_to_vector3df (rotation_speed));
- return scm_from_pointer ((void*) anim, NULL);
+ return scm_from_irr_pointer ("<scene-node-animator>", (void*) anim);
}
SCM
scene::ISceneManager* smgr = (scene::ISceneManager*) scm_to_irr_pointer (scene_manager);
scene::IAnimatedMesh* mesh = smgr->getMesh(cfilename);
free (cfilename);
- return scm_from_pointer ((void*) mesh, NULL);
+ return scm_from_irr_pointer ("<animated-mesh>", (void*) mesh);
}
SCM
ISceneManager_getRootSceneNode (SCM scene_manager)
{
scene::ISceneManager* smgr = (scene::ISceneManager*) scm_to_irr_pointer (scene_manager);
- return scm_from_pointer ((void*) smgr->getRootSceneNode (), NULL);
+ return scm_from_irr_pointer ("<scene-node>", (void*) smgr->getRootSceneNode ());
}
void
scm_to_vector3df (normal),
scm_to_color (color),
scm_to_vector2df (tcoords));
- return scm_from_pointer ((void*) vertex, NULL);
+ return scm_from_irr_pointer ("<vertex3d>", (void*) vertex);
}
SCM
video::IVideoDriver* driver = (video::IVideoDriver*) scm_to_irr_pointer (video_driver);
video::ITexture* texture = driver->getTexture (cfilename);
free (cfilename);
- return scm_from_pointer ((void*) texture, NULL);
+ return scm_from_irr_pointer ("<texture>", (void*) texture);
}
SCM
<http://www.gnu.org/licenses/>.
*/
+#include <irrlicht/irrlicht.h>
#include <libguile.h>
#include "wrapped.h"
+using namespace irr;
+
/* Make a GOOPS instance from a C++ object pointer */
SCM
-scm_from_irr_pointer (const char* module, const char* class_name, void* pointer)
+scm_from_irr_pointer (const char* class_name, void* pointer)
{
- SCM scm_class = scm_variable_ref (scm_c_public_lookup (module, class_name));
+ SCM scm_class = scm_variable_ref (scm_c_public_lookup ("irrlicht", class_name));
SCM k_pointer = scm_from_utf8_keyword ("irr-pointer");
SCM scm_pointer = scm_from_pointer (pointer, NULL);
return scm_make (scm_list_3 (scm_class, k_pointer, scm_pointer));
#ifndef __GUILE_IRRLICHT_WRAPPED_H_INCLUDED__
#define __GUILE_IRRLICHT_WRAPPED_H_INCLUDED__
+#include <irrlicht/irrlicht.h>
#include <libguile.h>
+using namespace irr;
+
SCM
-scm_from_irr_pointer (const char* module, const char* class_name, void* pointer);
+scm_from_irr_pointer (const char* class_name, void* pointer);
void*
scm_to_irr_pointer (SCM obj);