Changeset 4ed4b1f for src/io/sink.h
- Timestamp:
- Feb 23, 2014, 5:07:57 PM (10 years ago)
- Branches:
- feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
- Children:
- 2eccf22
- Parents:
- c21553d
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/io/sink.h
rc21553d r4ed4b1f 1 1 /* 2 Copyright (C) 2012-201 3Paul Brossier <piem@aubio.org>2 Copyright (C) 2012-2014 Paul Brossier <piem@aubio.org> 3 3 4 4 This file is part of aubio. … … 26 26 Media sink to write blocks of consecutive audio samples to file. 27 27 28 To read from file, use ::aubio_source_t. 29 28 30 \example io/test-sink.c 29 31 … … 48 50 Creates a new sink object. 49 51 52 If samplerate is set to 0, the creation of the file will be delayed until 53 both ::aubio_sink_preset_samplerate and ::aubio_sink_preset_channels have 54 been called. 55 50 56 */ 51 57 aubio_sink_t * new_aubio_sink(char_t * uri, uint_t samplerate); 58 59 /** 60 61 preset sink samplerate 62 63 \param s sink, created with ::new_aubio_sink 64 \param samplerate samplerate to preset the sink to, in Hz 65 66 \return 0 on success, 1 on error 67 68 Preset the samplerate of the sink. The file should have been created using a 69 samplerate of 0. 70 71 The file will be opened only when both samplerate and channels have been set. 72 73 */ 74 uint_t aubio_sink_preset_samplerate(aubio_sink_t *s, uint_t samplerate); 75 76 /** 77 78 preset sink channels 79 80 \param s sink, created with ::new_aubio_sink 81 \param channels number of channels to preset the sink to 82 83 \return 0 on success, 1 on error 84 85 Preset the samplerate of the sink. The file should have been created using a 86 samplerate of 0. 87 88 The file will be opened only when both samplerate and channels have been set. 89 90 */ 91 uint_t aubio_sink_preset_channels(aubio_sink_t *s, uint_t channels); 92 93 /** 94 95 get samplerate of sink object 96 97 \param s sink object, created with ::new_aubio_sink 98 \return samplerate, in Hz 99 100 */ 101 uint_t aubio_sink_get_samplerate(aubio_sink_t *s); 102 103 /** 104 105 get channels of sink object 106 107 \param s sink object, created with ::new_aubio_sink 108 \return number of channels 109 110 */ 111 uint_t aubio_sink_get_channels(aubio_sink_t *s); 52 112 53 113 /** … … 61 121 */ 62 122 void aubio_sink_do(aubio_sink_t * s, fvec_t * write_data, uint_t write); 123 124 /** 125 126 write polyphonic vector of length hop_size to sink 127 128 \param s sink, created with ::new_aubio_sink 129 \param write_data ::fmat_t samples to write to sink 130 \param write number of frames to write 131 132 */ 133 void aubio_sink_do_multi(aubio_sink_t * s, fmat_t * write_data, uint_t write); 63 134 64 135 /**
Note: See TracChangeset
for help on using the changeset viewer.