include/SDL_stdinc.h
changeset 4492 bff93336121e
parent 3697 f7b03b6838cb
child 4729 1f7ad083fd3c
child 4755 436183eb30c8
     1.1 --- a/include/SDL_stdinc.h	Wed Jul 07 21:35:44 2010 -0700
     1.2 +++ b/include/SDL_stdinc.h	Wed Jul 07 21:36:09 2010 -0700
     1.3 @@ -101,6 +101,13 @@
     1.4  #endif
     1.5  /*@}*//*Cast operators*/
     1.6  
     1.7 +/* Define a four character code as a Uint32 */
     1.8 +#define SDL_FOURCC(A, B, C, D) \
     1.9 +    ((SDL_static_cast(Uint32, SDL_static_cast(Uint8, (A))) << 0) | \
    1.10 +     (SDL_static_cast(Uint32, SDL_static_cast(Uint8, (B))) << 8) | \
    1.11 +     (SDL_static_cast(Uint32, SDL_static_cast(Uint8, (C))) << 16) | \
    1.12 +     (SDL_static_cast(Uint32, SDL_static_cast(Uint8, (D))) << 24))
    1.13 +
    1.14  /**
    1.15   *  \name Basic data types
    1.16   */