src/render/SDL_sysrender.h
changeset 6528 e978048ced60
parent 6414 df50b0d6c1c3
child 6530 ba5de88eab60
     1.1 --- a/src/render/SDL_sysrender.h	Mon Oct 01 00:56:58 2012 -0700
     1.2 +++ b/src/render/SDL_sysrender.h	Mon Oct 01 20:59:33 2012 -0700
     1.3 @@ -31,6 +31,20 @@
     1.4  
     1.5  typedef struct SDL_RenderDriver SDL_RenderDriver;
     1.6  
     1.7 +typedef struct
     1.8 +{
     1.9 +    float x;
    1.10 +    float y;
    1.11 +} SDL_FPoint;
    1.12 +
    1.13 +typedef struct
    1.14 +{
    1.15 +    float x;
    1.16 +    float y;
    1.17 +    float w;
    1.18 +    float h;
    1.19 +} SDL_FRect;
    1.20 +
    1.21  /* Define the SDL texture structure */
    1.22  struct SDL_Texture
    1.23  {
    1.24 @@ -80,17 +94,17 @@
    1.25      int (*SetRenderTarget) (SDL_Renderer * renderer, SDL_Texture * texture);
    1.26      int (*UpdateViewport) (SDL_Renderer * renderer);
    1.27      int (*RenderClear) (SDL_Renderer * renderer);
    1.28 -    int (*RenderDrawPoints) (SDL_Renderer * renderer, const SDL_Point * points,
    1.29 +    int (*RenderDrawPoints) (SDL_Renderer * renderer, const SDL_FPoint * points,
    1.30                               int count);
    1.31 -    int (*RenderDrawLines) (SDL_Renderer * renderer, const SDL_Point * points,
    1.32 +    int (*RenderDrawLines) (SDL_Renderer * renderer, const SDL_FPoint * points,
    1.33                              int count);
    1.34 -    int (*RenderFillRects) (SDL_Renderer * renderer, const SDL_Rect * rects,
    1.35 +    int (*RenderFillRects) (SDL_Renderer * renderer, const SDL_FRect * rects,
    1.36                              int count);
    1.37      int (*RenderCopy) (SDL_Renderer * renderer, SDL_Texture * texture,
    1.38 -                       const SDL_Rect * srcrect, const SDL_Rect * dstrect);
    1.39 +                       const SDL_Rect * srcrect, const SDL_FRect * dstrect);
    1.40      int (*RenderCopyEx) (SDL_Renderer * renderer, SDL_Texture * texture,
    1.41 -                       const SDL_Rect * srcquad, const SDL_Rect * dstrect,
    1.42 -                       const double angle, const SDL_Point *center, const SDL_RendererFlip flip);
    1.43 +                       const SDL_Rect * srcquad, const SDL_FRect * dstrect,
    1.44 +                       const double angle, const SDL_FPoint *center, const SDL_RendererFlip flip);
    1.45      int (*RenderReadPixels) (SDL_Renderer * renderer, const SDL_Rect * rect,
    1.46                               Uint32 format, void * pixels, int pitch);
    1.47      void (*RenderPresent) (SDL_Renderer * renderer);
    1.48 @@ -113,6 +127,10 @@
    1.49      SDL_Rect viewport;
    1.50      SDL_Rect viewport_backup;
    1.51  
    1.52 +    /* The render output coordinate scale */
    1.53 +    SDL_FPoint scale;
    1.54 +    SDL_FPoint scale_backup;
    1.55 +
    1.56      /* The list of textures */
    1.57      SDL_Texture *textures;
    1.58      SDL_Texture *target;