MCPcopy Create free account
hub / github.com/MusicPlayerDaemon/MPD / faad_decoder_decode

Function faad_decoder_decode

src/decoder/plugins/FaadDecoderPlugin.cxx:263–275  ·  view source on GitHub ↗

* Wrapper for NeAACDecDecode() which works around some API * inconsistencies in libfaad. */

Source from the content-addressed store, hash-verified

261 * inconsistencies in libfaad.
262 */
263static const void *
264faad_decoder_decode(NeAACDecHandle decoder, DecoderBuffer &buffer,
265 NeAACDecFrameInfo *frame_info)
266{
267 auto data = FromBytesStrict<const uint8_t>(buffer.Read());
268 if (data.empty())
269 return nullptr;
270
271 return NeAACDecDecode(decoder, frame_info,
272 /* deconst hack, libfaad requires this */
273 const_cast<uint8_t *>(data.data()),
274 data.size());
275}
276
277/**
278 * Determine a song file's total playing time.

Callers 1

faad_stream_decodeFunction · 0.85

Calls 2

emptyMethod · 0.80
ReadMethod · 0.45

Tested by

no test coverage detected