Guard CVideo::draw_texture with an ifdef.

This commit is contained in:
Boldizsár Lipka 2014-07-08 18:30:29 +02:00
parent a39bfabe58
commit 51aeb482a6
2 changed files with 6 additions and 1 deletions

View file

@ -387,11 +387,12 @@ void CVideo::blit_surface(int x, int y, surface surf, SDL_Rect* srcrect, SDL_Rec
const clip_rect_setter clip_setter(target, clip_rect, clip_rect != NULL);
sdl_blit(surf,srcrect,target,&dst);
}
#ifdef SDL_GPU
void CVideo::draw_texture(sdl::ttexture &texture, int x, int y)
{
texture.draw(*render_target, x, y);
}
#endif
void CVideo::make_fake()
{

View file

@ -25,10 +25,12 @@
#endif
struct surface;
#ifdef SDL_GPU
namespace sdl
{
struct ttexture;
}
#endif
//possible flags when setting video modes
#define FULL_SCREEN SDL_FULLSCREEN
@ -79,7 +81,9 @@ class CVideo : private boost::noncopyable {
//blits a surface with black as alpha
void blit_surface(int x, int y, surface surf, SDL_Rect* srcrect=NULL, SDL_Rect* clip_rect=NULL);
#ifdef SDL_GPU
void draw_texture(sdl::ttexture &texture, int x, int y);
#endif
void flip();
surface& getSurface();