drop vsync for desktop + TEXTURE_WRAP_CLAMP for chunks

isolation
Dominik Madarász 2022-09-29 15:02:40 +02:00
parent f9b00b3b12
commit 86b57bd3a1
4 changed files with 4 additions and 2 deletions

View File

@ -67,7 +67,7 @@ void platform_create_window(const char *title) {
#endif #endif
InitWindow(screenWidth, screenHeight, title); InitWindow(screenWidth, screenHeight, title);
SetWindowState(/*FLAG_WINDOW_UNDECORATED|*/FLAG_WINDOW_MAXIMIZED|FLAG_WINDOW_RESIZABLE|FLAG_MSAA_4X_HINT|FLAG_VSYNC_HINT); SetWindowState(/*FLAG_WINDOW_UNDECORATED|*/FLAG_WINDOW_MAXIMIZED|FLAG_WINDOW_RESIZABLE|FLAG_MSAA_4X_HINT/* |FLAG_VSYNC_HINT */);
#if !defined(PLATFORM_WEB) #if !defined(PLATFORM_WEB)
screenWidth = (uint16_t)GetScreenWidth(); screenWidth = (uint16_t)GetScreenWidth();

View File

@ -112,6 +112,7 @@ void blocks_build_chunk_tex(uint64_t id, block_id *chunk_blocks, void *raw_view)
} }
} }
EndTextureMode(); EndTextureMode();
SetTextureWrap(canvas.texture, TEXTURE_WRAP_CLAMP);
blocks__chunk_tbl_set(&baked_chunks, id, canvas); blocks__chunk_tbl_set(&baked_chunks, id, canvas);
} }

View File

@ -93,6 +93,8 @@ void platform_render() {
profile (PROF_RENDER) { profile (PROF_RENDER) {
renderer_draw(); renderer_draw();
} }
debug_draw();
} }
EndDrawing(); EndDrawing();

View File

@ -44,7 +44,6 @@ void DEBUG_draw_entities(uint64_t key, entity_view * data) {
case EKIND_PLAYER: { case EKIND_PLAYER: {
float x = data->x; float x = data->x;
float y = data->y; float y = data->y;
float health = (data->hp / data->max_hp);
DrawCircleEco(x, y, size, ColorAlpha(YELLOW, data->tran_time)); DrawCircleEco(x, y, size, ColorAlpha(YELLOW, data->tran_time));
}break; }break;
default:break; default:break;