Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- //open the audio file
- infile = sf_open(name_of_file, SFM_READ, &sfinfo);
- //get information of audio file
- cout << "Samplerate = " << sfinfo.samplerate << endl;
- cout << "Channels = " << sfinfo.channels << endl;
- //...
- //read until the end file
- while(sf_seek(infile, 0, SEEK_CUR) < sfinfo.frames)
- {
- //Reading N samples
- sf_readf_double(infile, samples, N);
- //...
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement