]> git.sesse.net Git - vlc/blobdiff - modules/stream_out/transcode/transcode.h
trascode: reinit audio filters if audio format changes in midstream
[vlc] / modules / stream_out / transcode / transcode.h
index fc8bb4135394aecef1ad1f91bfcc0076893d8b17..00e7a6ddf1cc65faa99a99d8505d9233fc038320 100644 (file)
@@ -25,6 +25,7 @@ struct sout_stream_sys_t
 
     /* Audio */
     vlc_fourcc_t    i_acodec;   /* codec audio (0 if not transcode) */
+    audio_sample_format_t   fmt_audio;
     char            *psz_aenc;
     char            *psz_alang;
     config_chain_t  *p_audio_cfg;
@@ -72,6 +73,8 @@ struct sout_stream_sys_t
     mtime_t         i_master_drift;
 };
 
+struct aout_filters;
+
 struct sout_stream_id_t
 {
     bool            b_transcode;
@@ -82,10 +85,15 @@ struct sout_stream_id_t
     /* Decoder */
     decoder_t       *p_decoder;
 
-    /* Filters */
-    filter_chain_t  *p_f_chain;
-    /* User specified filters */
-    filter_chain_t  *p_uf_chain;
+    union
+    {
+         struct
+         {
+             filter_chain_t  *p_f_chain; /**< Video filters */
+             filter_chain_t  *p_uf_chain; /**< User-specified video filters */
+         };
+         struct aout_filters *p_af_chain; /**< Audio filters */
+    };
 
     /* Encoder */
     encoder_t       *p_encoder;