Jump to content
  • Advertisement


Sign in to follow this  
  • entries
  • comments
  • views

Stuff i'm working on

Sign in to follow this  
Will F


Spent part of today writing a C++ class that takes care of SDL_Surface which i'm calling CImage. Nothing too exciting, makes loading static and animation images a bit easier, and it takes care of memory management. Also got a demo program (showing how to use color keys for transparency, and also a basic 2D animation technique) for it nearly finished - i'll put the source up in my webspace and a link to it here in the next day or two when I get the time to finish it.

I'm also working on CImageGL which takes care of loading SDL_Surfaces and using them as OpenGL textures. Will be nice to be able to use SDL_image to load my textures without having to rely on something like libpng being installed on someone's computer or writing my own image loader. Got a prototype of the class working, just need to iron out a few wrinkles and it'll be done. It's also a bit easier to code as it doesn't need to have as many functions as CImage. I'll put it up when I get it done.

I'd like to eventually put a wrapper around more of the library, some things like SDL_Color could be really useful, maybe a class to draw geometric shapes too. But in the mean time i'm more interested in getting the GUI finished on my main project.

I suppose someone else probably has already written a c++ wrapper around SDL, a quick look around with google only came up with SDLmm, which looks like it hasn't been updated in 4 years. There's also a c++ wrapper in in the book Focus On SDL, but getting it to compile on linux hasn't worked so far (I haven't put much effort into figuring out what's wrong). Oh well at least it's something I don't mind reinventing the wheel for.
Sign in to follow this  


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!