star-sim

Barnes-Hut gravity simulation.
git clone git://git.amin.space/star-sim.git
Log | Files | Refs | README | LICENSE

platform_sdl.h (367B)


      1 #ifndef PLATFORM_SDL_H
      2 
      3 #include <SDL2/SDL.h>
      4 
      5 struct SDLOffscreenBuffer
      6 {
      7     // NOTE(amin): pixels are always 32-bits wide. Memory order: BB GG RR XX.
      8     SDL_Texture *texture;
      9     void *memory;
     10     unsigned int width;
     11     unsigned int height;
     12     unsigned int pitch;
     13 };
     14 
     15 struct SDLWindowDimension
     16 {
     17     int width;
     18     int height;
     19 };
     20 
     21 #define PLATFORM_SDL_H
     22 #endif