aboutsummaryrefslogtreecommitdiffstats
path: root/src/decoder/FlacCommon.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-07-29 08:10:10 +0200
committerMax Kellermann <max@duempel.org>2013-07-30 08:31:02 +0200
commitc75cb67c4406648314ce2a15daf8b632374d7913 (patch)
tree5e27b73f2c90e878631bfac5b60070505b094717 /src/decoder/FlacCommon.cxx
parentcd1bb2bafa2653e5d4c7c9abf6f464bcdec693c5 (diff)
downloadmpd-c75cb67c4406648314ce2a15daf8b632374d7913.tar.gz
mpd-c75cb67c4406648314ce2a15daf8b632374d7913.tar.xz
mpd-c75cb67c4406648314ce2a15daf8b632374d7913.zip
pcm_buffer: convert to C++
Diffstat (limited to '')
-rw-r--r--src/decoder/FlacCommon.cxx5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/decoder/FlacCommon.cxx b/src/decoder/FlacCommon.cxx
index 07a377055..74a0347f2 100644
--- a/src/decoder/FlacCommon.cxx
+++ b/src/decoder/FlacCommon.cxx
@@ -39,13 +39,10 @@ flac_data::flac_data(struct decoder *_decoder,
decoder(_decoder), input_stream(_input_stream),
tag(nullptr)
{
- pcm_buffer_init(&buffer);
}
flac_data::~flac_data()
{
- pcm_buffer_deinit(&buffer);
-
if (tag != nullptr)
tag_free(tag);
}
@@ -178,7 +175,7 @@ flac_common_write(struct flac_data *data, const FLAC__Frame * frame,
return FLAC__STREAM_DECODER_WRITE_STATUS_ABORT;
size_t buffer_size = frame->header.blocksize * data->frame_size;
- buffer = pcm_buffer_get(&data->buffer, buffer_size);
+ buffer = data->buffer.Get(buffer_size);
flac_convert(buffer, frame->header.channels,
(enum sample_format)data->audio_format.format, buf,