mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-06 08:54:05 +00:00
winepulse: Include mult.c in pulse.c.
Originally meant to address the fact that mult_alaw_sample() and mult_ulaw_sample() were exported without being hidden, but this file is only used from pulse.c, and is relatively quite simple, so just make them static and use the preprocessor instead of linking.
This commit is contained in:
parent
e5eeca3843
commit
b8e912f795
|
@ -6,5 +6,4 @@ UNIX_CFLAGS = $(PULSE_CFLAGS)
|
|||
|
||||
C_SRCS = \
|
||||
mmdevdrv.c \
|
||||
mult.c \
|
||||
pulse.c
|
||||
|
|
|
@ -20,11 +20,6 @@
|
|||
|
||||
#include <windef.h>
|
||||
|
||||
#if 0
|
||||
#pragma makedep unix
|
||||
#endif
|
||||
|
||||
|
||||
/**********************************************************************
|
||||
* A-law and u-law sample manipulation functions
|
||||
* Multiply with the given volume (vol must be between 0...1 inclusive)
|
||||
|
@ -32,7 +27,7 @@
|
|||
* These were taken from PulseAudio's sources but adjusted to directly
|
||||
* fit our usage (since we use floats directly) so they should be exact.
|
||||
*/
|
||||
UINT8 mult_alaw_sample(UINT8 sample, float vol)
|
||||
static UINT8 mult_alaw_sample(UINT8 sample, float vol)
|
||||
{
|
||||
static const float decode_to_13bits_float[1 << 8] =
|
||||
{
|
||||
|
@ -708,7 +703,7 @@ UINT8 mult_alaw_sample(UINT8 sample, float vol)
|
|||
return encode[(int)(vol * decode_to_13bits_float[sample]) + ARRAY_SIZE(encode) / 2];
|
||||
}
|
||||
|
||||
UINT8 mult_ulaw_sample(UINT8 sample, float vol)
|
||||
static UINT8 mult_ulaw_sample(UINT8 sample, float vol)
|
||||
{
|
||||
static const float decode_to_14bits_float[1 << 8] =
|
||||
{
|
|
@ -44,6 +44,8 @@
|
|||
|
||||
#include "../mmdevapi/unixlib.h"
|
||||
|
||||
#include "mult.h"
|
||||
|
||||
WINE_DEFAULT_DEBUG_CHANNEL(pulse);
|
||||
|
||||
enum phys_device_bus_type {
|
||||
|
@ -117,9 +119,6 @@ static const REFERENCE_TIME DefaultPeriod = 100000;
|
|||
static pthread_mutex_t pulse_mutex;
|
||||
static pthread_cond_t pulse_cond = PTHREAD_COND_INITIALIZER;
|
||||
|
||||
UINT8 mult_alaw_sample(UINT8, float);
|
||||
UINT8 mult_ulaw_sample(UINT8, float);
|
||||
|
||||
static void pulse_lock(void)
|
||||
{
|
||||
pthread_mutex_lock(&pulse_mutex);
|
||||
|
|
Loading…
Reference in a new issue