From 57852bd3ae4265cbf75d0df55b6a7c21a7445c78 Mon Sep 17 00:00:00 2001 From: Raimon Zamora Date: Tue, 24 Mar 2026 08:23:11 +0100 Subject: [PATCH] =?UTF-8?q?VERSI=C3=93=201.4.10:=20-=20[NEW]=20surface=5Ft?= =?UTF-8?q?.flags=20-=20[NEW]=20F12=20per=20a=20rec=C3=A0rrega=20de=20surf?= =?UTF-8?q?aces=20en=20calent?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mini.cpp | 57 +++++++++++++++++++++++++++++++++++++++++++++++-------- version.h | 2 +- 2 files changed, 50 insertions(+), 9 deletions(-) diff --git a/mini.cpp b/mini.cpp index 5fb0a20..87889d0 100644 --- a/mini.cpp +++ b/mini.cpp @@ -15,6 +15,10 @@ #define MAX_SURFACES 100 #define MAX_FONTS 5 +#define SURF_NOTHING 0 +#define SURF_EXTERNAL 1 +#define SURF_GENERATED 2 + #ifdef MACOS_BUNDLE #include #endif @@ -28,6 +32,7 @@ struct surface_t { uint8_t *p {nullptr}; uint16_t w, h; uint32_t size; + uint8_t flags {SURF_NOTHING}; }; struct char_t { @@ -282,6 +287,7 @@ uint8_t newsurf(int w, int h) { surfaces[i].h = h; surfaces[i].size = w*h; surfaces[i].p = (uint8_t*)calloc(surfaces[i].size,1); + surfaces[i].flags = SURF_GENERATED; log_msg(LOG_INFO, "Surface %i creada.\n", i); return i; } @@ -315,11 +321,13 @@ uint8_t loadsurf(const char* filename, const bool external) { while (i