Update resampler drivers to be in sync with Mupen64 - don't

use logging functions here
This commit is contained in:
twinaphex 2015-02-05 19:40:46 +01:00
parent 4ffbadd49c
commit e75e6ed1be
3 changed files with 1 additions and 39 deletions

View File

@ -23,14 +23,6 @@
#include <xmmintrin.h>
#endif
#if !defined(RESAMPLER_TEST) && defined(RARCH_INTERNAL)
#include "../../general.h"
#else
/* FIXME - variadic macros not supported for MSVC 2003 */
#define RARCH_LOG(...) fprintf(stderr, __VA_ARGS__)
#endif
/* Since SSE and NEON don't provide support for trigonometric functions
* we approximate those with polynoms
*
@ -208,7 +200,6 @@ static void *resampler_CC_init(const struct resampler_config *config,
".set pop\n");
RARCH_LOG("\nConvoluted Cosine resampler (VFPU): \n");
return (void*)-1;
}
#else
@ -572,19 +563,15 @@ static void *resampler_CC_init(const struct resampler_config *config,
re->buffer[i].r = 0.0;
}
RARCH_LOG("Convoluted Cosine resampler (" CC_RESAMPLER_IDENT ") - precision = %i : ", CC_RESAMPLER_PRECISION);
/* Variations of data->ratio around 0.75 are safer
* than around 1.0 for both up/downsampler. */
if (bandwidth_mod < 0.75)
{
RARCH_LOG("CC_downsample @%f \n", bandwidth_mod);
re->process = resampler_CC_downsample;
re->distance = 0.0;
}
else
{
RARCH_LOG("CC_upsample @%f \n", bandwidth_mod);
re->process = resampler_CC_upsample;
re->distance = 2.0;
}

View File

@ -19,13 +19,6 @@
#include <stdlib.h>
#include <stdint.h>
#if !defined(RESAMPLER_TEST) && defined(RARCH_INTERNAL)
#include "../../general.h"
#else
/* FIXME - variadic macros not supported for MSVC 2003 */
#define RARCH_LOG(...) fprintf(stderr, __VA_ARGS__)
#endif
typedef struct rarch_nearest_resampler
{
float fraction;
@ -75,8 +68,6 @@ static void *resampler_nearest_init(const struct resampler_config *config,
re->fraction = 0;
RARCH_LOG("\nNearest resampler : \n");
return re;
}

View File

@ -22,12 +22,6 @@
#include <string.h>
#include <compat/posix_string.h>
#if !defined(RESAMPLER_TEST) && defined(RARCH_INTERNAL)
#include "../../general.h"
#else
#define RARCH_LOG(...) fprintf(stderr, __VA_ARGS__)
#endif
#ifdef __SSE__
#include <xmmintrin.h>
#endif
@ -528,21 +522,11 @@ static void *resampler_sinc_new(const struct resampler_config *config,
init_sinc_table(re, cutoff, re->phase_table,
1 << PHASE_BITS, re->taps, SINC_COEFF_LERP);
#if defined(__AVX__) && ENABLE_AVX
RARCH_LOG("Sinc resampler [AVX]\n");
#elif defined(__SSE__)
RARCH_LOG("Sinc resampler [SSE]\n");
#elif defined(__ARM_NEON__)
#if defined(__ARM_NEON__)
process_sinc_func = mask & RESAMPLER_SIMD_NEON
? process_sinc_neon : process_sinc_C;
RARCH_LOG("Sinc resampler [%s]\n",
mask & RESAMPLER_SIMD_NEON ? "NEON" : "C");
#else
RARCH_LOG("Sinc resampler [C]\n");
#endif
RARCH_LOG("SINC params (%u phase bits, %u taps).\n",
PHASE_BITS, re->taps);
return re;
error: