tentative code to check that we can read cue markers vis libsndfile
This commit is contained in:
parent
297760885c
commit
8fc8cbf4af
@ -395,6 +395,21 @@ SndFileSource::open ()
|
||||
}
|
||||
}
|
||||
#endif
|
||||
if (!writable()) {
|
||||
cerr << "Check for cues with " << _sndfile << endl;
|
||||
uint32_t cc;
|
||||
if (sf_command (_sndfile, SFC_GET_CUE_COUNT, &cc, sizeof (cc)) == SF_TRUE) {
|
||||
cerr << "cc is " << cc << endl;
|
||||
}
|
||||
|
||||
SF_CUES cues;
|
||||
if (sf_command (_sndfile, SFC_GET_CUE, &cues, sizeof (SF_CUES)) == SF_TRUE) {
|
||||
cerr << "Found " << cues.cue_count << " cues !\n";
|
||||
for (size_t n = 0; n < cues.cue_count; ++n) {
|
||||
_cue_markers.push_back (CueMarker (string_compose (X_("cue %1"), n+1), cues.cue_points[n].sample_offset));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!_broadcast_info) {
|
||||
_broadcast_info = new BroadcastInfo;
|
||||
|
Loading…
Reference in New Issue
Block a user