summaryrefslogtreecommitdiff
path: root/gfx-iso/include/isogfx/app.h
blob: 769af6d524268b6c280d0de627e0104e9170b877 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#pragma once

#include <gfx/app.h>

#include <stdbool.h>

typedef struct IsoGfx    IsoGfx;
typedef struct IsoGfxApp IsoGfxApp;

typedef struct IsoGfxAppState IsoGfxAppState;

typedef struct IsoGfxApp {
  int             pixel_scale; // 0 or 1 for 1:1 scale.
  IsoGfxAppState* state;

  bool (*init)(IsoGfxAppState*, IsoGfx*, int argc, const char** argv);
  void (*shutdown)(IsoGfxAppState*, IsoGfx*);
  void (*update)(IsoGfxAppState*, IsoGfx*, double t, double dt);
  void (*render)(IsoGfxAppState*, IsoGfx*);
} IsoGfxApp;

void iso_run(int argc, const char** argv, IsoGfxApp*);