diff options
author | David Thompson <dthompson2@worcester.edu> | 2015-12-22 09:00:20 -0500 |
---|---|---|
committer | David Thompson <dthompson2@worcester.edu> | 2015-12-22 09:00:20 -0500 |
commit | 8e8fe4275a0db47e31422324c144b2cebee5df63 (patch) | |
tree | 469fa30d4a5b3bbc5757641d658acdccda0de620 /sdl2/bindings.scm | |
parent | 5db39e02c1714a7390cbb71220107289886f42e8 (diff) |
surface: Add binding for SDL_ConvertSurfaceFormat.
* sdl2/bindings.scm: Add a ton of pixel format constants.
* sdl2/surface.scm: (symbol->sdl-pixel-format, convert-surface-format):
New procedures.
Diffstat (limited to 'sdl2/bindings.scm')
-rw-r--r-- | sdl2/bindings.scm | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/sdl2/bindings.scm b/sdl2/bindings.scm index 1672b0d..79fbf92 100644 --- a/sdl2/bindings.scm +++ b/sdl2/bindings.scm @@ -847,6 +847,48 @@ RETURN-TYPE and accept arguments of ARG-TYPES." ;;; +;;; Pixels +;;; + +(define-public SDL_PIXELFORMAT_UNKNOWN 0) +(define-public SDL_PIXELFORMAT_INDEX1LSB 286261504) +(define-public SDL_PIXELFORMAT_INDEX1MSB 287310080) +(define-public SDL_PIXELFORMAT_INDEX4LSB 303039488) +(define-public SDL_PIXELFORMAT_INDEX4MSB 304088064) +(define-public SDL_PIXELFORMAT_INDEX8 318769153) +(define-public SDL_PIXELFORMAT_RGB332 336660481) +(define-public SDL_PIXELFORMAT_RGB444 353504258) +(define-public SDL_PIXELFORMAT_RGB555 353570562) +(define-public SDL_PIXELFORMAT_BGR555 357764866) +(define-public SDL_PIXELFORMAT_ARGB4444 355602434) +(define-public SDL_PIXELFORMAT_RGBA4444 356651010) +(define-public SDL_PIXELFORMAT_ABGR4444 359796738) +(define-public SDL_PIXELFORMAT_BGRA4444 360845314) +(define-public SDL_PIXELFORMAT_ARGB1555 355667970) +(define-public SDL_PIXELFORMAT_RGBA5551 356782082) +(define-public SDL_PIXELFORMAT_ABGR1555 359862274) +(define-public SDL_PIXELFORMAT_BGRA5551 360976386) +(define-public SDL_PIXELFORMAT_RGB565 353701890) +(define-public SDL_PIXELFORMAT_BGR565 357896194) +(define-public SDL_PIXELFORMAT_RGB24 386930691) +(define-public SDL_PIXELFORMAT_BGR24 390076419) +(define-public SDL_PIXELFORMAT_RGB888 370546692) +(define-public SDL_PIXELFORMAT_RGBX8888 371595268) +(define-public SDL_PIXELFORMAT_BGR888 374740996) +(define-public SDL_PIXELFORMAT_BGRX8888 375789572) +(define-public SDL_PIXELFORMAT_ARGB8888 372645892) +(define-public SDL_PIXELFORMAT_RGBA8888 373694468) +(define-public SDL_PIXELFORMAT_ABGR8888 376840196) +(define-public SDL_PIXELFORMAT_BGRA8888 377888772) +(define-public SDL_PIXELFORMAT_ARGB2101010 372711428) +(define-public SDL_PIXELFORMAT_YV12 842094169) +(define-public SDL_PIXELFORMAT_IYUV 1448433993) +(define-public SDL_PIXELFORMAT_YUY2 844715353) +(define-public SDL_PIXELFORMAT_UYVY 1498831189) +(define-public SDL_PIXELFORMAT_YVYU 1431918169) + + +;;; ;;; Surface ;;; @@ -856,6 +898,9 @@ RETURN-TYPE and accept arguments of ARG-TYPES." (define-foreign sdl-load-bmp-rw '* "SDL_LoadBMP_RW" (list '* int)) +(define-foreign sdl-convert-surface-format + '* "SDL_ConvertSurfaceFormat" (list '* uint32 uint32)) + ;;; ;;; Audio |