summarylogtreecommitdiffstats
path: root/0001-i_sdlsound.c-fix-compilation-with-libsamplerate-0.1..patch
diff options
context:
space:
mode:
Diffstat (limited to '0001-i_sdlsound.c-fix-compilation-with-libsamplerate-0.1..patch')
-rw-r--r--0001-i_sdlsound.c-fix-compilation-with-libsamplerate-0.1..patch53
1 files changed, 0 insertions, 53 deletions
diff --git a/0001-i_sdlsound.c-fix-compilation-with-libsamplerate-0.1..patch b/0001-i_sdlsound.c-fix-compilation-with-libsamplerate-0.1..patch
deleted file mode 100644
index 216bb6d005e0..000000000000
--- a/0001-i_sdlsound.c-fix-compilation-with-libsamplerate-0.1..patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From 7b4e65f16aacb3c00e19817be35c8acba7865fec Mon Sep 17 00:00:00 2001
-From: Fabian Greffrath <fabian@greffrath.com>
-Date: Mon, 24 Oct 2016 15:30:18 +0200
-Subject: [PATCH] i_sdlsound.c: fix compilation with libsamplerate 0.1.9
-
-This new version has const-corrected the data_in field, fixes #788
----
- src/i_sdlsound.c | 8 +++++---
- 1 file changed, 5 insertions(+), 3 deletions(-)
-
-diff --git a/src/i_sdlsound.c b/src/i_sdlsound.c
-index 79a15db..2d7a620 100644
---- a/src/i_sdlsound.c
-+++ b/src/i_sdlsound.c
-@@ -339,6 +339,7 @@ static boolean ExpandSoundData_SRC(sfxinfo_t *sfxinfo,
- int length)
- {
- SRC_DATA src_data;
-+ float *data_in;
- uint32_t i, abuf_index=0, clipped=0;
- // uint32_t alen;
- int retn;
-@@ -346,7 +347,8 @@ static boolean ExpandSoundData_SRC(sfxinfo_t *sfxinfo,
- Mix_Chunk *chunk;
-
- src_data.input_frames = length;
-- src_data.data_in = malloc(length * sizeof(float));
-+ data_in = malloc(length * sizeof(float));
-+ src_data.data_in = data_in;
- src_data.src_ratio = (double)mixer_freq / samplerate;
-
- // We include some extra space here in case of rounding-up.
-@@ -362,7 +364,7 @@ static boolean ExpandSoundData_SRC(sfxinfo_t *sfxinfo,
- // Unclear whether 128 should be interpreted as "zero" or whether a
- // symmetrical range should be assumed. The following assumes a
- // symmetrical range.
-- src_data.data_in[i] = data[i] / 127.5 - 1;
-+ data_in[i] = data[i] / 127.5 - 1;
- }
-
- // Do the sound conversion
-@@ -430,7 +432,7 @@ static boolean ExpandSoundData_SRC(sfxinfo_t *sfxinfo,
- expanded[abuf_index++] = cvtval_i;
- }
-
-- free(src_data.data_in);
-+ free(data_in);
- free(src_data.data_out);
-
- if (clipped > 0)
---
-2.10.1
-