From 3d008961c095cf8d41d2c61d13d446c98c892136 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Tue, 11 Aug 2009 17:10:44 +0200 Subject: sample-util: move volume code to separate file Move the volume code into a separate file with the reference C implementations. Add a function to retrieve the volume function and one to install a new one. --- src/pulsecore/sample-util.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src/pulsecore/sample-util.h') diff --git a/src/pulsecore/sample-util.h b/src/pulsecore/sample-util.h index 6a306c11..278b88b0 100644 --- a/src/pulsecore/sample-util.h +++ b/src/pulsecore/sample-util.h @@ -86,6 +86,12 @@ void pa_memchunk_dump_to_file(pa_memchunk *c, const char *fn); void pa_memchunk_sine(pa_memchunk *c, pa_mempool *pool, unsigned rate, unsigned freq); +typedef void (*pa_do_volume_func_t) (void *samples, void *volumes, unsigned channels, unsigned length); + +pa_do_volume_func_t pa_get_volume_func(pa_sample_format_t f); +void pa_set_volume_func(pa_sample_format_t f, pa_do_volume_func_t func); + + #define PA_CHANNEL_POSITION_MASK_LEFT \ (PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_FRONT_LEFT) \ | PA_CHANNEL_POSITION_MASK(PA_CHANNEL_POSITION_REAR_LEFT) \ -- cgit