Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - Redien

Pages: [1]
D / DSFML (a port to the D language)
« on: April 15, 2008, 12:40:51 am »
I've recently picked up on the D language (http://www.digitalmars.com/d/) and wanted to start developing some games for it. But D can only directly link to C object files and not C++ and because of that the only multimedia libraries availiable have C bindings.

Therefore I decided to create a port of the SFML library with the goal of providing an interface as close to the C++ version as possible. I use version 1.2 as the reference since I wanted a stable interface to port so that the interface wouldn't change as I ported it.

Currently I have as good as ported the whole Window interface aswell as the Win32 implementation. (I haven't implemented joystick support yet, but it would be just a matter of converting the C++ code to D.) The interface is almost identical to the one found in C++. The only differences are the use of .'s instead of :'s and the use of modules and imports instead of header files. Which makes the tutorials still apply with some minor changes.

Some parts of the System package are also ported as they are required by the Window package. Cross-platform threads and mutexes are implemented by the D standard library so there's not much need for porting them.

Currently the Win32 implementation of the Window interface is all I need, so I probably won't be adding other packages to the port unless I find them useful in the future.

If anyone's interested in taking a look or maybe port other parts of SFML I'd happily send it over. :)

Graphics / GraphicsDevice.cpp - std::mem_fun
« on: March 25, 2008, 12:18:52 am »
I've been following the progress of SFML for a while now and I really like the simplicity of the interface.

I recently started using STLPort instead of the STL that comes with MinGW and ran into an error when compiling SFML 1.2 regarding std::mem_fun not being found in GraphicsDevice.cpp. I've had no troubles compiling it before so I thought it was weird and looked it up. It seems like mem_fun is supposed to be defined in the STL header 'functional'. So I included it and it compiled.

I just thought you'd like to know if you weren't aware of it already. :)

Pages: [1]