[svn-commits] file: trunk r78338 - /trunk/main/frame.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Tue Aug 7 10:40:43 CDT 2007


Author: file
Date: Tue Aug  7 10:40:43 2007
New Revision: 78338

URL: http://svn.digium.com/view/asterisk?view=rev&rev=78338
Log:
(closes issue #10225)
Reported by: klaus3000
Clean up AST_FORMAT_LIST list. It may have mattered in the old days to have undefined entries but these days it does not.

Modified:
    trunk/main/frame.c

Modified: trunk/main/frame.c
URL: http://svn.digium.com/view/asterisk/trunk/main/frame.c?view=diff&rev=78338&r1=78337&r2=78338
==============================================================================
--- trunk/main/frame.c (original)
+++ trunk/main/frame.c Tue Aug  7 10:40:43 2007
@@ -103,39 +103,30 @@
 };
 
 /*! \brief Definition of supported media formats (codecs) */
-static struct ast_format_list AST_FORMAT_LIST[] = {					/*!< Bit number: comment  - Bit numbers are hard coded in show_codec() */
-	{ 1, AST_FORMAT_G723_1 , "g723" , "G.723.1", 20, 30, 300, 30, 30 },	/*!<  1 */
-	{ 1, AST_FORMAT_GSM, "gsm" , "GSM", 33, 20, 300, 20, 20 },		/*!<  2: codec_gsm.c */
-	{ 1, AST_FORMAT_ULAW, "ulaw", "G.711 u-law", 80, 10, 150, 10, 20 },	/*!<  3: codec_ulaw.c */
-	{ 1, AST_FORMAT_ALAW, "alaw", "G.711 A-law", 80, 10, 150, 10, 20 },	/*!<  4: codec_alaw.c */
-	{ 1, AST_FORMAT_G726, "g726", "G.726 RFC3551", 40, 10, 300, 10, 20 },	/*!<  5: codec_g726.c */
-	{ 1, AST_FORMAT_ADPCM, "adpcm" , "ADPCM", 40, 10, 300, 10, 20 },	/*!<  6: codec_adpcm.c */
-	{ 1, AST_FORMAT_SLINEAR, "slin", "16 bit Signed Linear PCM", 160, 10, 70, 10, 20, AST_SMOOTHER_FLAG_BE },	/*!< 7 */
-	{ 1, AST_FORMAT_LPC10, "lpc10", "LPC10", 7, 20, 20, 20, 20 },		/*!<  8: codec_lpc10.c */ 
-	{ 1, AST_FORMAT_G729A, "g729", "G.729A", 10, 10, 230, 10, 20, AST_SMOOTHER_FLAG_G729 },	/*!<  9: Binary commercial distribution */
-	{ 1, AST_FORMAT_SPEEX, "speex", "SpeeX", 10, 10, 60, 10, 20 },		/*!< 10: codec_speex.c */
-	{ 1, AST_FORMAT_ILBC, "ilbc", "iLBC", 50, 30, 30, 30, 30 },		/*!< 11: codec_ilbc.c */ /* inc=30ms - workaround */
-	{ 1, AST_FORMAT_G726_AAL2, "g726aal2", "G.726 AAL2", 40, 10, 300, 10, 20 },	/*!<  12: codec_g726.c */
-	{ 1, AST_FORMAT_G722, "g722", "G722"},					/*!< 13 */
-	{ 0, 0, "nothing", "undefined" },
-	{ 0, 0, "nothing", "undefined" },
-	{ 0, 0, "nothing", "undefined" },
-	{ 0, 0, "nothing", "undefined" },
+static struct ast_format_list AST_FORMAT_LIST[] = {
+	{ 1, AST_FORMAT_G723_1 , "g723" , "G.723.1", 20, 30, 300, 30, 30 },	                                  /*!< G723.1 */
+	{ 1, AST_FORMAT_GSM, "gsm" , "GSM", 33, 20, 300, 20, 20 },		                                  /*!< codec_gsm.c */
+	{ 1, AST_FORMAT_ULAW, "ulaw", "G.711 u-law", 80, 10, 150, 10, 20 },	                                  /*!< codec_ulaw.c */
+	{ 1, AST_FORMAT_ALAW, "alaw", "G.711 A-law", 80, 10, 150, 10, 20 },	                                  /*!< codec_alaw.c */
+	{ 1, AST_FORMAT_G726, "g726", "G.726 RFC3551", 40, 10, 300, 10, 20 },	                                  /*!< codec_g726.c */
+	{ 1, AST_FORMAT_ADPCM, "adpcm" , "ADPCM", 40, 10, 300, 10, 20 },	                                  /*!< codec_adpcm.c */
+	{ 1, AST_FORMAT_SLINEAR, "slin", "16 bit Signed Linear PCM", 160, 10, 70, 10, 20, AST_SMOOTHER_FLAG_BE }, /*!< Signed linear */
+	{ 1, AST_FORMAT_LPC10, "lpc10", "LPC10", 7, 20, 20, 20, 20 },		                                  /*!< codec_lpc10.c */ 
+	{ 1, AST_FORMAT_G729A, "g729", "G.729A", 10, 10, 230, 10, 20, AST_SMOOTHER_FLAG_G729 },	                  /*!< Binary commercial distribution */
+	{ 1, AST_FORMAT_SPEEX, "speex", "SpeeX", 10, 10, 60, 10, 20 },		                                  /*!< codec_speex.c */
+	{ 1, AST_FORMAT_ILBC, "ilbc", "iLBC", 50, 30, 30, 30, 30 },		                                  /*!< codec_ilbc.c */ /* inc=30ms - workaround */
+	{ 1, AST_FORMAT_G726_AAL2, "g726aal2", "G.726 AAL2", 40, 10, 300, 10, 20 },	                          /*!< codec_g726.c */
+	{ 1, AST_FORMAT_G722, "g722", "G722"},					                                  /*!< G722 Passthrough */
 	{ 0, AST_FORMAT_MAX_AUDIO, "maxaudio", "Maximum audio format" },	
-	{ 1, AST_FORMAT_JPEG, "jpeg", "JPEG image"},	/*!< 17: See format_jpeg.c */
-	{ 1, AST_FORMAT_PNG, "png", "PNG image"},	/*!< 18: Image format */
-	{ 1, AST_FORMAT_H261, "h261", "H.261 Video" },	/*!< 19: H.261 Video Passthrough */
-	{ 1, AST_FORMAT_H263, "h263", "H.263 Video" },	/*!< 20: H.263 Passthrough support, see format_h263.c */
-	{ 1, AST_FORMAT_H263_PLUS, "h263p", "H.263+ Video" },	/*!< 21: H.263plus passthrough support See format_h263.c */
-	{ 1, AST_FORMAT_H264, "h264", "H.264 Video" },	/*!< 22: Passthrough support, see format_h263.c */
-	{ 1, AST_FORMAT_MP4_VIDEO, "mpeg4", "MPEG4 Video" }, /*!< Passthrough support for MPEG4 */
-	{ 0, 0, "nothing", "undefined" },
-	{ 0, 0, "nothing", "undefined" },
-	{ 0, 0, "nothing", "undefined" },
+	{ 1, AST_FORMAT_JPEG, "jpeg", "JPEG image"},	                                                          /*!< See format_jpeg.c */
+	{ 1, AST_FORMAT_PNG, "png", "PNG image"},	                                                          /*!< PNG Image format */
+	{ 1, AST_FORMAT_H261, "h261", "H.261 Video" },	                                                          /*!< H.261 Video Passthrough */
+	{ 1, AST_FORMAT_H263, "h263", "H.263 Video" },	                                                          /*!< H.263 Passthrough support, see format_h263.c */
+	{ 1, AST_FORMAT_H263_PLUS, "h263p", "H.263+ Video" },	                                                  /*!< H.263plus passthrough support See format_h263.c */
+	{ 1, AST_FORMAT_H264, "h264", "H.264 Video" },	                                                          /*!< Passthrough support, see format_h263.c */
+	{ 1, AST_FORMAT_MP4_VIDEO, "mpeg4", "MPEG4 Video" },                                                      /*!< Passthrough support for MPEG4 */
 	{ 0, AST_FORMAT_MAX_VIDEO, "maxvideo", "Maximum video format" },
-	{ 1, AST_FORMAT_T140, "t140", "Passthrough T.140 Realtime Text" },
-	{ 0, 0, "nothing", "undefined" },
-	{ 0, 0, "nothing", "undefined" },
+	{ 1, AST_FORMAT_T140, "t140", "Passthrough T.140 Realtime Text" },                                        /*!< Passthrough support for T.140 Realtime Text */
 	{ 0, AST_FORMAT_MAX_TEXT, "maxtext", "Maximum text format" },
 };
 




More information about the svn-commits mailing list