diff options
author | Max Kellermann <max@duempel.org> | 2013-08-10 18:02:44 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-09-04 18:14:22 +0200 |
commit | 29030b54c98b0aee65fbc10ebf7ba36bed98c02c (patch) | |
tree | 79766830b55ebca38ddbce84d8d548227eedb69e /src/pcm/PcmResample.hxx | |
parent | c9fcc7f14860777458153eb2d13c773ccfa1daa2 (diff) | |
download | mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.tar.gz mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.tar.xz mpd-29030b54c98b0aee65fbc10ebf7ba36bed98c02c.zip |
util/Error: new error passing library
Replaces GLib's GError.
Diffstat (limited to '')
-rw-r--r-- | src/pcm/PcmResample.hxx | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/pcm/PcmResample.hxx b/src/pcm/PcmResample.hxx index db0bbff8d..8a740744a 100644 --- a/src/pcm/PcmResample.hxx +++ b/src/pcm/PcmResample.hxx @@ -22,7 +22,6 @@ #include "check.h" #include "PcmBuffer.hxx" -#include "gerror.h" #include <stdint.h> #include <stddef.h> @@ -31,6 +30,8 @@ #include <samplerate.h> #endif +class Error; + /** * This object is statically allocated (within another struct), and * holds buffer allocations and the state for the resampler. @@ -75,7 +76,7 @@ struct PcmResampler { const float *ResampleFloat(unsigned channels, unsigned src_rate, const float *src_buffer, size_t src_size, unsigned dest_rate, size_t *dest_size_r, - GError **error_r); + Error &error_r); /** * Resamples 16 bit PCM data. @@ -91,7 +92,7 @@ struct PcmResampler { const int16_t *Resample16(unsigned channels, unsigned src_rate, const int16_t *src_buffer, size_t src_size, unsigned dest_rate, size_t *dest_size_r, - GError **error_r); + Error &error_r); /** * Resamples 32 bit PCM data. @@ -107,7 +108,7 @@ struct PcmResampler { const int32_t *Resample32(unsigned channels, unsigned src_rate, const int32_t *src_buffer, size_t src_size, unsigned dest_rate, size_t *dest_size_r, - GError **error_r); + Error &error_r); /** * Resamples 24 bit PCM data. @@ -123,7 +124,7 @@ struct PcmResampler { const int32_t *Resample24(unsigned channels, unsigned src_rate, const int32_t *src_buffer, size_t src_size, unsigned dest_rate, size_t *dest_size_r, - GError **error_r) + Error &error_r) { /* reuse the 32 bit code - the resampler code doesn't care if the upper 8 bits are actually used */ @@ -133,6 +134,6 @@ struct PcmResampler { }; bool -pcm_resample_global_init(GError **error_r); +pcm_resample_global_init(Error &error); #endif |