]> git.sesse.net Git - ffmpeg/blobdiff - libswresample/audioconvert.h
Merge remote-tracking branch 'shariman/wmall'
[ffmpeg] / libswresample / audioconvert.h
index e5fd4dfd80a518e590caf81366c61745291f8360..6d09271b358150ed21121870336b5eb09690f5f1 100644 (file)
@@ -33,8 +33,8 @@
 #include "libavutil/cpu.h"
 #include "libavutil/audioconvert.h"
 
-struct AVAudioConvert;
-typedef struct AVAudioConvert AVAudioConvert;
+struct AudioConvert;
+typedef struct AudioConvert AudioConvert;
 
 /**
  * Create an audio sample format converter context
@@ -42,17 +42,20 @@ typedef struct AVAudioConvert AVAudioConvert;
  * @param in_fmt Input sample format
  * @param channels Number of channels
  * @param flags See AV_CPU_FLAG_xx
+ * @param ch_map list of the channels id to pick from the source stream, NULL
+ *               if all channels must be selected
  * @return NULL on error
  */
-AVAudioConvert *swr_audio_convert_alloc(enum AVSampleFormat out_fmt,
-                                        enum AVSampleFormat in_fmt,
-                                        int channels, int flags);
+AudioConvert *swri_audio_convert_alloc(enum AVSampleFormat out_fmt,
+                                       enum AVSampleFormat in_fmt,
+                                       int channels, const int *ch_map,
+                                       int flags);
 
 /**
  * Free audio sample format converter context.
  * and set the pointer to NULL
  */
-void swr_audio_convert_free(AVAudioConvert **ctx);
+void swri_audio_convert_free(AudioConvert **ctx);
 
 /**
  * Convert between audio sample formats
@@ -60,6 +63,6 @@ void swr_audio_convert_free(AVAudioConvert **ctx);
  * @param[in] in array of input buffers for each channel
  * @param len length of audio frame size (measured in samples)
  */
-int swr_audio_convert(AVAudioConvert *ctx, AudioData *out, AudioData *in, int len);
+int swri_audio_convert(AudioConvert *ctx, AudioData *out, AudioData *in, int len);
 
-#endif /* AVCODEC_AUDIOCONVERT_H */
+#endif /* AUDIOCONVERT_H */