Changeset 6031419
- Timestamp:
- Dec 12, 2018, 11:25:35 PM (6 years ago)
- Branches:
- feature/autosink, feature/cnn, feature/crepe, fix/ffmpeg5, master
- Children:
- 1ba359c, 7107ed9
- Parents:
- 2e13788
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/io/sink_vorbis.c
r2e13788 r6031419 107 107 float quality_mode = .9; 108 108 109 if (s->samplerate == 0 || s->channels == 0) 110 { 111 AUBIO_ERR("sink_vorbis: vorbis_encode_init_vbr failed\n"); 112 return AUBIO_FAIL; 113 } 109 if (s->samplerate == 0 || s->channels == 0) return AUBIO_FAIL; 114 110 115 111 s->fid = fopen((const char *)s->path, "wb"); … … 248 244 { 249 245 uint_t c, v; 246 uint_t channels = MIN(s->channels, write_data->height); 250 247 float **buffer = vorbis_analysis_buffer(&s->vd, (long)write); 251 248 // fill buffer … … 256 253 return; 257 254 } else { 258 for (c = 0; c < s->channels; c++) {255 for (c = 0; c < channels; c++) { 259 256 for (v = 0; v < write; v++) { 260 257 buffer[c][v] = write_data->data[c][v];
Note: See TracChangeset
for help on using the changeset viewer.