Index: trunk/src/gl/gl_device.cc
===================================================================
--- trunk/src/gl/gl_device.cc	(revision 89)
+++ trunk/src/gl/gl_device.cc	(revision 90)
@@ -11,4 +11,5 @@
 #include "nv/logging.hh"
 #include "nv/lib/sdl12.hh"
+#include "nv/lib/sdl_image.hh"
 
 using namespace nv;
@@ -67,4 +68,14 @@
 }
 
+// this is a temporary function that will be removed once we find a way to 
+// pass binary file data around
+image_data* nv::gl_device::create_image_data( const std::string& filename )
+{
+	load_sdl_image_library();
+	SDL_Surface* image = IMG_Load( filename.c_str() );
+	image_data* data = new image_data( glm::ivec2( image->w, image->h ), image->format->BytesPerPixel, (nv::uint8*)image->pixels );
+	return data;
+}
+
 texture2d* gl_device::create_texture2d( ivec2 size, image_format aformat, datatype adatatype, sampler asampler, void* data /*= nullptr */ )
 {
