From 0882f153d46c4d3278a10f96c342081ceed02658 Mon Sep 17 00:00:00 2001 From: SuperUserNameMan <9801802+SuperUserNameMan@users.noreply.github.com> Date: Tue, 23 Jul 2024 17:55:57 +0200 Subject: [PATCH] `raylib.h` : add flags to control the texture font linear filtering - part 1 When in `FLAT_RESCALE_CONTENT` mode, the default "nearest pixel" filter of the texture font is ugly sometimes. So this change adds `FLAG_RESCALE_CONTENT_LINEAR` and `FLAG_TEXT_LINEAR_FILTER` to offer more control. `FLAG_TEXT_LINEAR_FILTER` can also be used to disable the linear filtering of `FLAG_WINDOW_HIGHDPI`. --- src/raylib.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/raylib.h b/src/raylib.h index 4b6c07f1c..201fc00c1 100644 --- a/src/raylib.h +++ b/src/raylib.h @@ -549,7 +549,9 @@ typedef enum { FLAG_INTERLACED_HINT = 0x00010000, // Set to try enabling interlaced video format (for V3D) // Experimental WIP flags : - FLAG_RESCALE_CONTENT = 0x10000000 // (GLFW desktop platform) Set to rescale the content of the window when the window is resized or fullscreened + FLAG_RESCALE_CONTENT = 0x10000000, // Set to rescale the content of the window when the window is resized or fullscreened + FLAG_TEXT_LINEAR_FILTER = 0x20000000, // Set to force the linear texture filter of the text font + FLAG_RESCALE_CONTENT_LINEAR = 0x30000000 // Set both bits of `FLAG_RESCALE_CONTENT` and `FLAG_TEXT_LINEAR_FILTER` } ConfigFlags; // Trace log level