Skip to content

Commit

Permalink
Update local-toolkit sdl version
Browse files Browse the repository at this point in the history
  • Loading branch information
Hugh Sanderson committed Jan 12, 2025
1 parent a677cad commit 9ba291c
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 7 deletions.
7 changes: 6 additions & 1 deletion project/src/audio/SDLSound.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,11 @@ enum { STEREO_SAMPLES = 2 };
unsigned int sSoundPos = 0;
double sMusicT0 = 0;
double sLastMusicUpdate = 0;
#ifdef NME_SDL3
double sMusicFrequency = 0.0;
#else
double sMusicFrequency = 44100;
#endif
bool sSoundPaused = false;

void onChannelDone(int inChannel)
Expand Down Expand Up @@ -365,10 +369,11 @@ class SDLSoundChannel : public SoundChannel
void initSpec()
{
Mix_QuerySpec(&mFrequency, &mFormat, &mChannels);

if (mFrequency!=44100)
ELOG("Warning - Frequency mismatch %d",mFrequency);
#ifdef NME_SDL3
if (mFormat!=SDL_AUDIO_F32)
if (mFormat!=SDL_AUDIO_S16)
#else
if (mFormat!=32784)
#endif
Expand Down
2 changes: 1 addition & 1 deletion project/toolkit/sdl-mixer/SDL_mixer
Submodule SDL_mixer updated 116 files
2 changes: 1 addition & 1 deletion project/toolkit/sdl/SDL
Submodule SDL updated 1483 files
16 changes: 12 additions & 4 deletions project/toolkit/sdl/files.xml
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@

<file name="${NME_LIBSDL}src/cpuinfo/SDL_cpuinfo.c" />
<file name="${NME_LIBSDL}src/file/SDL_iostream.c" />
<file name="${NME_LIBSDL}src/file/SDL_asyncio.c" />
<file name="${NME_LIBSDL}src/dynapi/SDL_dynapi.c" />
<file name="${NME_LIBSDL}src/events/SDL_clipboardevents.c" />
<file name="${NME_LIBSDL}src/events/SDL_displayevents.c" />
Expand All @@ -145,7 +146,6 @@
<file name="${NME_LIBSDL}src/events/SDL_pen.c" />
<file name="${NME_LIBSDL}src/events/SDL_categories.c" />
<file name="${NME_LIBSDL}src/haptic/SDL_haptic.c" />
<file name="${NME_LIBSDL}src/joystick/steam/SDL_steamcontroller.c" />
<file name="${NME_LIBSDL}src/joystick/SDL_gamepad.c" />
<file name="${NME_LIBSDL}src/joystick/SDL_joystick.c" />
<file name="${NME_LIBSDL}src/libm/e_atan2.c" />
Expand Down Expand Up @@ -188,6 +188,7 @@
<file name="${NME_LIBSDL}/src/stdlib/SDL_stdlib.c" />
<file name="${NME_LIBSDL}/src/stdlib/SDL_string.c" />
<file name="${NME_LIBSDL}/src/stdlib/SDL_strtokr.c" />
<file name="${NME_LIBSDL}/src/stdlib/SDL_murmur3.c" />

<file name="${NME_LIBSDL}src/thread/SDL_thread.c" />
<file name="${NME_LIBSDL}src/timer/SDL_timer.c" />
Expand Down Expand Up @@ -248,9 +249,9 @@
<file name="${NME_LIBSDL}src/misc/SDL_url.c" />

<file name="${NME_LIBSDL}src/gpu/SDL_gpu.c" />
<file name="${NME_LIBSDL}src/render/sdlgpu/SDL_render_gpu.c" />
<file name="${NME_LIBSDL}src/render/sdlgpu/SDL_shaders_gpu.c" />
<file name="${NME_LIBSDL}src/render/sdlgpu/SDL_pipeline_gpu.c" />
<file name="${NME_LIBSDL}src/render/gpu/SDL_render_gpu.c" />
<file name="${NME_LIBSDL}src/render/gpu/SDL_shaders_gpu.c" />
<file name="${NME_LIBSDL}src/render/gpu/SDL_pipeline_gpu.c" />
<file name="${NME_LIBSDL}src/storage/SDL_storage.c" />
<file name="${NME_LIBSDL}src/storage/generic/SDL_genericstorage.c" />
<file name="${NME_LIBSDL}src/SDL_properties.c" />
Expand All @@ -266,6 +267,9 @@
<file name="${NME_LIBSDL}src/main/SDL_main_callbacks.c" />
<file name="${NME_LIBSDL}src/main/generic/SDL_sysmain_callbacks.c" />
<file name="${NME_LIBSDL}src/dialog/SDL_dialog_utils.c" />
<file name="${NME_LIBSDL}src/dialog/SDL_dialog.c" />
<file name="${NME_LIBSDL}src/process/SDL_process.c" />
<file name="${NME_LIBSDL}src/tray/SDL_tray_utils.c" />


<section unless="windows">
Expand All @@ -280,6 +284,8 @@
<file name="${NME_LIBSDL}src/filesystem/posix/SDL_sysfsops.c" />
<file name="${NME_LIBSDL}src/time/unix/SDL_systime.c" />
<file name="${NME_LIBSDL}src/locale/unix/SDL_syslocale.c" />
<file name="${NME_LIBSDL}src/process/posix/SDL_posixprocess.c" />
<file name="${NME_LIBSDL}/src/file/generic/SDL_asyncio_generic.c" />

</section>

Expand Down Expand Up @@ -314,6 +320,7 @@
<file name="${NME_LIBSDL}src/joystick/hidapi/SDL_hidapi_stadia.c" />
<file name="${NME_LIBSDL}src/joystick/hidapi/SDL_hidapi_steamdeck.c" />
<file name="${NME_LIBSDL}src/joystick/hidapi/SDL_hidapi_wii.c" />
<file name="${NME_LIBSDL}src/joystick/hidapi/SDL_hidapi_steam_hori.c" />

</section>

Expand Down Expand Up @@ -564,6 +571,7 @@
<file name="${NME_LIBSDL}src/misc/macos/SDL_sysurl.m" />
<file name="${NME_LIBSDL}src/power/macos/SDL_syspower.c" />
<file name="${NME_LIBSDL}src/camera/coremedia/SDL_camera_coremedia.m" />
<file name="${NME_LIBSDL}src/tray/cocoa/SDL_tray.m" />

</section>

Expand Down

0 comments on commit 9ba291c

Please sign in to comment.