From af121493c84c116b06f2572846535293a827d089 Mon Sep 17 00:00:00 2001 From: Kelly Rauchenberger Date: Sat, 20 Jun 2009 13:56:20 -0400 Subject: Embedded images into executable file --- titlestate.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'titlestate.cpp') diff --git a/titlestate.cpp b/titlestate.cpp index 425e4ca..c011480 100644 --- a/titlestate.cpp +++ b/titlestate.cpp @@ -2,8 +2,12 @@ TitleState::TitleState() { - background = SDL_LoadBMP("title.bmp"); - pointer = SDL_LoadBMP("pointer.bmp"); + SDL_RWops *rw = SDL_RWFromMem(&_binary_title_bmp_start, (int) &_binary_title_bmp_size); + background = SDL_LoadBMP_RW(rw, 1); + + rw = SDL_RWFromMem(&_binary_pointer_bmp_start, (int) &_binary_pointer_bmp_size); + pointer = SDL_LoadBMP_RW(rw, 1); + selection = 0; SDL_WM_SetCaption("Maze Of Life", NULL); -- cgit 1.4.1