[vlc-commits] Support G.723.1

Jean-Baptiste Kempf git at videolan.org
Sun Oct 28 00:38:46 CEST 2012


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Sun Oct 28 00:29:45 2012 +0200| [85de56923384b7afadd162a97073cbb3f04be39c] | committer: Jean-Baptiste Kempf

Support G.723.1

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=85de56923384b7afadd162a97073cbb3f04be39c
---

 include/vlc_codecs.h |    3 +++
 include/vlc_fourcc.h |    2 ++
 modules/demux/wav.c  |    1 +
 src/misc/fourcc.c    |    4 ++++
 4 files changed, 10 insertions(+)

diff --git a/include/vlc_codecs.h b/include/vlc_codecs.h
index b4877f1..dee85f4 100644
--- a/include/vlc_codecs.h
+++ b/include/vlc_codecs.h
@@ -285,6 +285,8 @@ ATTR_PACKED
 #define WAVE_FORMAT_VORB_2PLUS          0x6770
 #define WAVE_FORMAT_VORB_3PLUS          0x6771
 
+#define WAVE_FORMAT_G723_1              0xa100
+
 #define WAVE_FORMAT_SPEEX               0xa109 /* Speex audio */
 #define WAVE_FORMAT_FLAC                0xf1ac /* Xiph Flac */
 
@@ -353,6 +355,7 @@ wave_format_tag_to_fourcc[] =
     { WAVE_FORMAT_TRUESPEECH, VLC_CODEC_TRUESPEECH,             "Truespeech" },
     { WAVE_FORMAT_GSM610,     VLC_CODEC_GSM_MS,                 "Microsoft WAV GSM" },
     { WAVE_FORMAT_G726,       VLC_CODEC_ADPCM_G726,             "G.726 ADPCM" },
+    { WAVE_FORMAT_G723_1,     VLC_CODEC_G723_1,                 "G.723.1" },
     { WAVE_FORMAT_MPEGLAYER3, VLC_CODEC_MPGA,                   "Mpeg Audio" },
     { WAVE_FORMAT_MPEG,       VLC_CODEC_MPGA,                   "Mpeg Audio" },
     { WAVE_FORMAT_AMR_NB,     VLC_CODEC_AMR_NB,                 "AMR NB" },
diff --git a/include/vlc_fourcc.h b/include/vlc_fourcc.h
index fd7b9ec..796d016 100644
--- a/include/vlc_fourcc.h
+++ b/include/vlc_fourcc.h
@@ -281,6 +281,8 @@
 #define VLC_CODEC_ADPCM_IMA_AMV VLC_FOURCC('i','m','a','v')
 #define VLC_CODEC_ADPCM_IMA_QT  VLC_FOURCC('i','m','a','4')
 #define VLC_CODEC_ADPCM_YAMAHA VLC_FOURCC('m','s',0x00,0x20)
+#define VLC_CODEC_G723_1 VLC_FOURCC('g','7','2', 0x31)
+#define VLC_CODEC_G729 VLC_FOURCC('g','7','2','9')
 #define VLC_CODEC_VMDAUDIO  VLC_FOURCC('v','m','d','a')
 #define VLC_CODEC_AMR_NB    VLC_FOURCC('s','a','m','r')
 #define VLC_CODEC_AMR_WB    VLC_FOURCC('s','a','w','b')
diff --git a/modules/demux/wav.c b/modules/demux/wav.c
index 2e8b95f..6acf631 100644
--- a/modules/demux/wav.c
+++ b/modules/demux/wav.c
@@ -343,6 +343,7 @@ static int Open( vlc_object_t * p_this )
     case VLC_CODEC_ADPCM_G726:
     case VLC_CODEC_TRUESPEECH:
     case VLC_CODEC_ATRAC3:
+    case VLC_CODEC_G723_1:
         if( FrameInfo_MSGSM( &p_sys->i_frame_size, &p_sys->i_frame_samples,
                              &p_sys->fmt ) )
             goto error;
diff --git a/src/misc/fourcc.c b/src/misc/fourcc.c
index 1a9022a..4594cba 100644
--- a/src/misc/fourcc.c
+++ b/src/misc/fourcc.c
@@ -1239,6 +1239,10 @@ static const staticentry_t p_list_audio[] = {
     B(VLC_CODEC_RALF, "RealAudio Lossless"),
         A("LSD:"),
 
+    /* G.723.1 */
+    B(VLC_CODEC_G723_1, "G.723.1 Audio"),
+        A("g72\x31"),
+
     /* PCM */
     B(VLC_CODEC_S8, "PCM S8"),
         A("s8  "),



More information about the vlc-commits mailing list