You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: OpusSharp.Core/OpusDecoder.cs
+7-2Lines changed: 7 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -145,8 +145,10 @@ public unsafe int Decode(byte[] input, int inputLength, short[] output, int fram
145
145
/// Decodes an Opus frame.
146
146
/// </summary>
147
147
/// <param name="input">Input in float format (interleaved if 2 channels), with a normal range of +/-1.0. Samples with a range beyond +/-1.0 are supported but will be clipped by decoders using the integer API and should only be used if it is known that the far end supports extended dynamic range. length is frame_size*channels*sizeof(float)</param>
148
-
/// <param name="frame_size">Number of samples per channel in the input signal. This must be an Opus frame size for the encoder's sampling rate. For example, at 48 kHz the permitted values are 120, 240, 480, 960, 1920, and 2880. Passing in a duration of less than 10 ms (480 samples at 48 kHz) will prevent the encoder from using the LPC or hybrid modes.</param>
148
+
/// <param name="inputLength">Number of samples per channel in the input signal. This must be an Opus frame size for the encoder's sampling rate. For example, at 48 kHz the permitted values are 120, 240, 480, 960, 1920, and 2880. Passing in a duration of less than 10 ms (480 samples at 48 kHz) will prevent the encoder from using the LPC or hybrid modes.</param>
149
149
/// <param name="output">Output payload</param>
150
+
/// <param name="frame_size">The number of samples per channel of available space in pcm. If this is less than the maximum packet duration (120 ms; 5760 for 48kHz), this function will not be capable of decoding some packets. In the case of PLC (data==NULL) or FEC (decode_fec=1), then frame_size needs to be exactly the duration of audio that is missing, otherwise the decoder will not be in the optimal state to decode the next incoming packet. For the PLC and FEC cases, frame_size must be a multiple of 2.5 ms.</param>
151
+
/// <param name="decodeFEC">Flag (false or true) to request that any in-band forward error correction data be decoded. If no such data is available, the frame is decoded as if it were lost.</param>
150
152
/// <param name="inputOffset">Offset to start reading in the input.</param>
151
153
/// <param name="outputOffset">Offset to start writing in the output.</param>
152
154
/// <returns>The length of the decoded packet on success or a negative error code (see <see cref="Enums.OpusError"/>) on failure. Note: OpusSharp throws an error if there is a negative error code.</returns>
@@ -210,7 +212,6 @@ public void DecoderCtl(Enums.GenericCtl ctl, int value)
210
212
/// Requests a CTL on the decoder.
211
213
/// </summary>
212
214
/// <param name="ctl">The decoder CTL to request.</param>
213
-
/// <param name="value">The value that is outputted from the CTL.</param>
Copy file name to clipboardExpand all lines: OpusSharp.Core/OpusMSDecoder.cs
+10-2Lines changed: 10 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -76,6 +76,9 @@ public int Pitch
76
76
/// </summary>
77
77
/// <param name="SampleRate">Sample rate to decode at (Hz). This must be one of 8000, 12000, 16000, 24000, or 48000.</param>
78
78
/// <param name="Channels">Number of channels to decode.</param>
79
+
/// <param name="Streams">The total number of streams coded in the input. This must be no more than 255.</param>
80
+
/// <param name="CoupledStreams">Number of streams to decode as coupled (2 channel) streams. This must be no larger than the total number of streams. Additionally, The total number of coded channels (streams + coupled_streams) must be no more than 255.</param>
81
+
/// <param name="mapping">Mapping from coded channels to output channels, as described in Opus Multistream API.</param>
@@ -147,8 +150,10 @@ public unsafe int Decode(byte[] input, int inputLength, short[] output, int fram
147
150
/// Decodes a multistream Opus frame.
148
151
/// </summary>
149
152
/// <param name="input">Input in float format (interleaved if 2 channels), with a normal range of +/-1.0. Samples with a range beyond +/-1.0 are supported but will be clipped by decoders using the integer API and should only be used if it is known that the far end supports extended dynamic range. length is frame_size*channels*sizeof(float)</param>
150
-
/// <param name="frame_size">The number of samples per channel of available space in pcm. If this is less than the maximum packet duration (120 ms; 5760 for 48kHz), this function will not be capable of decoding some packets. In the case of PLC (data==NULL) or FEC (decode_fec=1), then frame_size needs to be exactly the duration of audio that is missing, otherwise the decoder will not be in the optimal state to decode the next incoming packet. For the PLC and FEC cases, frame_size must be a multiple of 2.5 ms.</param>
153
+
/// <param name="inputLength">The number of samples per channel of available space in pcm. If this is less than the maximum packet duration (120 ms; 5760 for 48kHz), this function will not be capable of decoding some packets. In the case of PLC (data==NULL) or FEC (decode_fec=1), then frame_size needs to be exactly the duration of audio that is missing, otherwise the decoder will not be in the optimal state to decode the next incoming packet. For the PLC and FEC cases, frame_size must be a multiple of 2.5 ms.</param>
151
154
/// <param name="output">Output signal, with interleaved samples. This must contain room for frame_size*channels samples.</param>
155
+
/// <param name="frame_size"></param>
156
+
/// <param name="decodeFEC">Flag (false or true) to request that any in-band forward error correction data be decoded. If no such data is available, the frame is decoded as if it were lost.</param>
152
157
/// <param name="inputOffset">Offset to start reading in the input.</param>
153
158
/// <param name="outputOffset">Offset to start writing in the output.</param>
154
159
/// <returns>The length of the decoded packet on success or a negative error code (see <see cref="Enums.OpusError"/>) on failure. Note: OpusSharp throws an error if there is a negative error code.</returns>
@@ -184,7 +189,6 @@ public void DecoderCtl(Enums.DecoderCtl ctl, int value)
184
189
/// Requests a CTL on the multistream decoder.
185
190
/// </summary>
186
191
/// <param name="ctl">The decoder CTL to request.</param>
187
-
/// <param name="value">The value that is outputted from the CTL.</param>
0 commit comments