From 9bbe724dc978c8f6f650bef54678d5588a77428a Mon Sep 17 00:00:00 2001 From: Martin Lucina Date: Wed, 3 Feb 2010 18:30:56 +0100 Subject: Correct RGBA mask used in SDL_CreateRGBSurfaceFrom() This fixes the funky colours :-) --- zmq-camera.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/zmq-camera.c b/zmq-camera.c index 5469808..5123553 100644 --- a/zmq-camera.c +++ b/zmq-camera.c @@ -590,7 +590,10 @@ int main (int argc, char *argv []) image_height, /* Height */ 24, /* Depth */ image_width * 3, /* Scanline pitch */ - 0, 0, 0, 0); /* TODO: RGBA mask */ + 0x000000ff, /* Red */ + 0x0000ff00, /* Green */ + 0x00ff0000, /* Blue */ + 0); /* No alpha */ /* Blit surface to screen. */ SDL_BlitSurface (rgb_surface, NULL, screen, NULL); -- cgit v1.2.3