diff options
Diffstat (limited to 'encoders')
-rw-r--r-- | encoders/lame_encoder.cpp | 8 | ||||
-rw-r--r-- | encoders/lame_encoder.h | 2 |
2 files changed, 4 insertions, 6 deletions
diff --git a/encoders/lame_encoder.cpp b/encoders/lame_encoder.cpp index 4cbfc9c..125ee5e 100644 --- a/encoders/lame_encoder.cpp +++ b/encoders/lame_encoder.cpp @@ -15,12 +15,10 @@ EncoderLame::~EncoderLame() { lame_close(gfp); } -size_t EncoderLame::encode(uint8_t *input, size_t input_size, uint8_t *output, size_t output_size) { - size_t size = lame_encode_buffer_interleaved(gfp, (short*)input, input_size / 4, output, output_size); - return size; +size_t EncoderLame::encode(const uint8_t *input, size_t input_size, uint8_t *output, size_t output_size) { + return lame_encode_buffer_interleaved(gfp, (short*)input, input_size / 4, output, output_size); } size_t EncoderLame::flush(uint8_t *output, size_t output_size) { - size_t size = lame_encode_flush(gfp, output, output_size); - return size; + return lame_encode_flush(gfp, output, output_size); } diff --git a/encoders/lame_encoder.h b/encoders/lame_encoder.h index 47f9666..1843361 100644 --- a/encoders/lame_encoder.h +++ b/encoders/lame_encoder.h @@ -12,7 +12,7 @@ class EncoderLame : public EncoderBase { public: EncoderLame(); ~EncoderLame(); - size_t encode(uint8_t *input, size_t input_size, uint8_t *output, size_t output_size); + size_t encode(const uint8_t *input, size_t input_size, uint8_t *output, size_t output_size); size_t flush(uint8_t *output, size_t output_size); }; |