From 186775d58551ca361c97ab0ec4fd9154042bdfc8 Mon Sep 17 00:00:00 2001 From: Raimon Zamora Date: Fri, 6 Feb 2026 12:10:28 +0100 Subject: [PATCH] No se, alguns canvis --- source/jail_audio.cpp | 4 ++-- source/jdraw.cpp | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/source/jail_audio.cpp b/source/jail_audio.cpp index 0944eca..6a6c627 100644 --- a/source/jail_audio.cpp +++ b/source/jail_audio.cpp @@ -89,7 +89,7 @@ Uint32 JA_UpdateCallback(void *userdata, SDL_TimerID timerID, Uint32 interval) { if (current_music->times != 0) { - if (SDL_GetAudioStreamAvailable(current_music->stream) < (current_music->length/2)) + if (SDL_GetAudioStreamAvailable(current_music->stream) < int(current_music->length/2)) SDL_PutAudioStreamData(current_music->stream, current_music->buffer, current_music->length); if (current_music->times>0) current_music->times--; } @@ -106,7 +106,7 @@ Uint32 JA_UpdateCallback(void *userdata, SDL_TimerID timerID, Uint32 interval) { if (channels[i].times != 0) { - if (SDL_GetAudioStreamAvailable(channels[i].stream) < (channels[i].sound->length/2)) + if (SDL_GetAudioStreamAvailable(channels[i].stream) < int(channels[i].sound->length/2)) SDL_PutAudioStreamData(channels[i].stream, channels[i].sound->buffer, channels[i].sound->length); if (channels[i].times>0) channels[i].times--; } diff --git a/source/jdraw.cpp b/source/jdraw.cpp index e9b10b2..89aba2a 100644 --- a/source/jdraw.cpp +++ b/source/jdraw.cpp @@ -93,13 +93,11 @@ namespace draw sdl_renderer = SDL_CreateRenderer(sdl_window, nullptr); sdl_texture = SDL_CreateTexture(sdl_renderer, SDL_PIXELFORMAT_ARGB8888, SDL_TEXTUREACCESS_STREAMING, screen_width, screen_height); - char *driver_name; const int num_render_drivers = SDL_GetNumRenderDrivers(); printf("Available renderers:\n"); for (int i=0; i