YARP
Yet Another Robot Platform
SoundFileMp3.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2006-2021 Istituto Italiano di Tecnologia (IIT)
3 * SPDX-FileCopyrightText: 2006-2010 RobotCub Consortium
4 * SPDX-License-Identifier: BSD-3-Clause
5 */
6
7#ifndef YARP_SIG_SOUNDFILE_MP3_H
8#define YARP_SIG_SOUNDFILE_MP3_H
9
10#include <yarp/sig/Sound.h>
11
12namespace yarp::sig::file {
19bool YARP_sig_API read_mp3_bytestream(Sound& data, const char* bytestream, size_t streamsize);
20
27bool YARP_sig_API read_mp3_file(Sound& data, const char* filename);
28
36bool YARP_sig_API write_mp3_file(const Sound& data, const char* filename, size_t bitrate = 64000);
37} // namespace yarp::sig::file
38
39#endif // YARP_SIG_SOUNDFILE_MP3_H
bool write_mp3_file(const Sound &data, const char *filename, size_t bitrate=64000)
Write a sound to a mp3 file.
bool read_mp3_file(Sound &data, const char *filename)
Read a sound from a .mp3 audio file.
bool read_mp3_bytestream(Sound &data, const char *bytestream, size_t streamsize)
Read a sound from a byte array.
#define YARP_sig_API
Definition: api.h:18