* NEW: Remove libsdl_image dependency, now Image class relies completly on the 
  gb.image.io component to load images.

Less dependencies is always better.


git-svn-id: svn://localhost/gambas/trunk@3011 867c0c6c-44f3-4631-809d-bfa615b0a4ec
This commit is contained in:
Laurent Carlier 2010-06-16 13:05:35 +00:00
parent 0b2beb5985
commit 102dd5720b
4 changed files with 8 additions and 8 deletions

View File

@ -33,8 +33,8 @@ GB_COMPONENT(
[SDL],
[src],
[GB_FIND(SDL_opengl.h SDL.h SDL_image.h SDL_ttf.h, `sdl-config --prefix`, include/SDL)],
[GB_FIND(libSDL_image.$SHLIBEXT libSDL_ttf.$SHLIBEXT libGLEW.$SHLIBEXT, /usr /usr/X11R6 /usr/local `sdl-config --prefix`, lib)],
[$X_LIBS -lSDL_image -lSDL_ttf -lGLU -lGLEW],
[GB_FIND(libSDL_ttf.$SHLIBEXT libGLEW.$SHLIBEXT, /usr /usr/X11R6 /usr/local `sdl-config --prefix`, lib)],
[$X_LIBS -lSDL_ttf -lGLU -lGLEW],
[$SDL_CFLAGS])
AC_OUTPUT( \

View File

@ -91,7 +91,7 @@ CIMAGE *CIMAGE_create(SDLsurface *image)
}
/***************************************************************************/
/*
BEGIN_METHOD(CIMAGE_load, GB_STRING path)
char *addr;
@ -113,14 +113,14 @@ BEGIN_METHOD(CIMAGE_load, GB_STRING path)
GB.Error("Unable to load image");
END_METHOD
*/
/***************************************************************************/
GB_DESC CImage[] =
{
GB_DECLARE("Image", sizeof(CIMAGE)),
GB_STATIC_METHOD("Load", "Image", CIMAGE_load, "(Path)s"),
//GB_STATIC_METHOD("Load", "Image", CIMAGE_load, "(Path)s"),
GB_END_DECLARE
};

View File

@ -161,7 +161,7 @@ void SDLsurface::Create(int Width, int Height, int Depth)
}
hTexture->ToLoad();
}
/*
void SDLsurface::LoadFromMem(char *addr, long len)
{
SDL_Surface *surface = IMG_Load_RW(SDL_RWFromMem(addr, len), true);
@ -180,7 +180,7 @@ void SDLsurface::LoadFromMem(char *addr, long len)
std::cout << "SDLsurface::LoadFromMem : alpha layer detected" << std::endl;
#endif
}
*/
int SDLsurface::GetWidth()
{
if (hSurface)

View File

@ -37,7 +37,7 @@ public:
~SDLsurface();
void Create(int Width, int Height, int Depth = 0);
void LoadFromMem(char* addr, long len);
// void LoadFromMem(char* addr, long len);
int GetWidth(void );
int GetHeight(void );