Index: trunk/src/gl/gl_device.cc
===================================================================
--- trunk/src/gl/gl_device.cc	(revision 439)
+++ trunk/src/gl/gl_device.cc	(revision 461)
@@ -51,6 +51,13 @@
 	}
 	// TODO: BGR vs RGB, single channel
-	assert( image->format->BytesPerPixel > 2 );
-	image_format format(image->format->BytesPerPixel == 3 ? RGB : RGBA, UBYTE );
+	pixel_format pformat = RGBA;
+	switch ( image->format->BytesPerPixel )
+	{
+	case 4: pformat = RGBA; break;
+	case 3: pformat = RGB; break;
+	case 1: pformat = RED; break;
+	default: NV_ASSERT( false, "BytesPerPixel != 4,3 or 1!" );
+	}
+	image_format format( pformat, UBYTE );
 	image_data* data = new image_data( format, ivec2( image->w, image->h ), static_cast<nv::uint8*>( image->pixels ) );
 	return data;
Index: trunk/src/gl/gl_enum.cc
===================================================================
--- trunk/src/gl/gl_enum.cc	(revision 439)
+++ trunk/src/gl/gl_enum.cc	(revision 461)
@@ -184,4 +184,5 @@
 	case BGR     : return GL_BGR;
 	case BGRA    : return GL_BGRA;
+	case RED     : return GL_RED;
 	NV_RETURN_COVERED_DEFAULT( 0 );
 	}
@@ -200,4 +201,6 @@
 	case BGR     : return GL_RGB8;
 	case BGRA    : return GL_RGBA8;
+	case RED     : return 0x8040; // GL_LUMINANCE8; // TODO: change to GL_R8!
+
 	NV_RETURN_COVERED_DEFAULT( 0 );
 	}
