How do you read/write audio files using the libsndfile C++ wrapper?

LeeG picture LeeG · Jul 14, 2013 · Viewed 13.3k times · Source

libsndfile is a C library for reading and writing WAV files, and it also includes a C++ wrapper, which I'd like to use.

However, although the C API documentation is very thorough, I cannot figure out how to use the C++ wrapper to read audio files (though there are examples on the web about writing).

Is there any actual documentation or examples using this API? Or should I just give up on using this wrapper, and instead use the C API directly?