summaryrefslogtreecommitdiff
path: root/include/renderwindow.h
blob: 87d89b96190ce5f98c430fd85a9909c798b7787d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#ifndef RENDERWINDOW_H_
#define RENDERWINDOW_H_

#include <SDL3/SDL.h>
#include <dawn/webgpu.h>

typedef struct {
  SDL_Window* window;

  WGPUInstance wgpuInstance;
  WGPUSurface wgpuSurface;
  WGPUAdapter wgpuAdapter;
  WGPUDevice wgpuDevice;
  WGPUSurfaceConfiguration configs;
  WGPUQueue queue;
} RenderWindow;

RenderWindow InitRenderWindow(int width, int height, const char* title);
void QuitRenderWindow(RenderWindow* renderWindow);

#endif // RENDERWINDOW_H_