full removal of SDL_Renderer usage, working spatial triangle rendering, temporary(?) regression of HDPI

This commit is contained in:
2024-07-12 21:10:25 +03:00
parent 34cf504b2b
commit 55d85399e9
12 changed files with 348 additions and 224 deletions

View File

@@ -11,28 +11,20 @@ static void ingame_tick(struct state *state) {
world_drawdef(scn->world);
player_calc(scn->player);
// unfurl_triangle("/assets/title.png",
// (t_fvec3){ 1250, 700, 0 },
// (t_fvec3){ 0, 800, 0 },
// (t_fvec3){ 0, 0, 0 },
// (t_shvec2){ 0, 360 },
// (t_shvec2){ 0, 0 },
// (t_shvec2){ 360, 0 });
unfurl_triangle("/assets/red.png",
(t_fvec3){ 0, 0, 0 },
(t_fvec3){ RENDER_BASE_WIDTH, 0, 0 },
(t_fvec3){ RENDER_BASE_WIDTH, RENDER_BASE_HEIGHT, 0 },
unfurl_triangle("/assets/player/baron-walk.png",
(t_fvec3){ -1, -1, 0 },
(t_fvec3){ 1, -1, 0 },
(t_fvec3){ 1, 1, 0 },
(t_shvec2){ 0, 0 },
(t_shvec2){ 80, 0 },
(t_shvec2){ 80, 80 });
(t_shvec2){ 48, 0 },
(t_shvec2){ 48, 48 });
unfurl_triangle("/assets/red.png",
(t_fvec3){ RENDER_BASE_WIDTH, RENDER_BASE_HEIGHT, 0 },
(t_fvec3){ 0, RENDER_BASE_HEIGHT, 0 },
(t_fvec3){ 0, 0, 0 },
(t_shvec2){ 80, 80 },
(t_shvec2){ 0, 80 },
unfurl_triangle("/assets/player/baron-walk.png",
(t_fvec3){ 1, 1, 0 },
(t_fvec3){ -1, 1, 0 },
(t_fvec3){ -1, -1, 0 },
(t_shvec2){ 48, 48 },
(t_shvec2){ 0, 48 },
(t_shvec2){ 0, 0 });
}