2003-06-29 19:46:12 +00:00
|
|
|
#ifdef HAVE_CONFIG_H
|
|
|
|
#include "config.h"
|
|
|
|
#endif
|
2001-12-22 23:27:31 +00:00
|
|
|
#include "mulaw-encode.h"
|
|
|
|
#include "mulaw-decode.h"
|
|
|
|
|
2008-12-13 15:34:01 +00:00
|
|
|
GstStaticPadTemplate mulaw_dec_src_factory = GST_STATIC_PAD_TEMPLATE ("src",
|
|
|
|
GST_PAD_SRC,
|
|
|
|
GST_PAD_ALWAYS,
|
|
|
|
GST_STATIC_CAPS ("audio/x-raw-int, "
|
|
|
|
"rate = (int) [ 8000, 192000 ], "
|
|
|
|
"channels = (int) [ 1, 2 ], "
|
|
|
|
"endianness = (int) BYTE_ORDER, "
|
|
|
|
"width = (int) 16, " "width = (int) 16, " "signed = (boolean) True")
|
|
|
|
);
|
|
|
|
|
|
|
|
GstStaticPadTemplate mulaw_dec_sink_factory = GST_STATIC_PAD_TEMPLATE ("sink",
|
|
|
|
GST_PAD_SINK,
|
|
|
|
GST_PAD_ALWAYS,
|
|
|
|
GST_STATIC_CAPS ("audio/x-mulaw, "
|
|
|
|
"rate = [ 8000 , 192000 ], " "channels = [ 1 , 2 ]")
|
|
|
|
);
|
|
|
|
|
|
|
|
GstStaticPadTemplate mulaw_enc_sink_factory = GST_STATIC_PAD_TEMPLATE ("sink",
|
|
|
|
GST_PAD_SINK,
|
|
|
|
GST_PAD_ALWAYS,
|
|
|
|
GST_STATIC_CAPS ("audio/x-raw-int, "
|
|
|
|
"rate = (int) [ 8000, 192000 ], "
|
|
|
|
"channels = (int) [ 1, 2 ], "
|
|
|
|
"endianness = (int) BYTE_ORDER, "
|
|
|
|
"width = (int) 16, " "width = (int) 16, " "signed = (boolean) True")
|
|
|
|
);
|
|
|
|
|
|
|
|
GstStaticPadTemplate mulaw_enc_src_factory = GST_STATIC_PAD_TEMPLATE ("src",
|
|
|
|
GST_PAD_SRC,
|
|
|
|
GST_PAD_ALWAYS,
|
|
|
|
GST_STATIC_CAPS ("audio/x-mulaw, "
|
|
|
|
"rate = [ 8000 , 192000 ], " "channels = [ 1 , 2 ]")
|
|
|
|
);
|
2001-12-22 23:27:31 +00:00
|
|
|
|
|
|
|
static gboolean
|
2004-03-14 22:34:33 +00:00
|
|
|
plugin_init (GstPlugin * plugin)
|
2001-12-22 23:27:31 +00:00
|
|
|
{
|
2003-11-02 18:13:24 +00:00
|
|
|
if (!gst_element_register (plugin, "mulawenc",
|
2004-03-15 19:32:27 +00:00
|
|
|
GST_RANK_NONE, GST_TYPE_MULAWENC) ||
|
2003-11-02 18:13:24 +00:00
|
|
|
!gst_element_register (plugin, "mulawdec",
|
2004-03-15 19:32:27 +00:00
|
|
|
GST_RANK_PRIMARY, GST_TYPE_MULAWDEC))
|
2003-11-02 18:13:24 +00:00
|
|
|
return FALSE;
|
2001-12-22 23:27:31 +00:00
|
|
|
|
|
|
|
return TRUE;
|
|
|
|
}
|
|
|
|
|
2004-03-14 22:34:33 +00:00
|
|
|
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
|
|
|
|
GST_VERSION_MINOR,
|
|
|
|
"mulaw",
|
|
|
|
"MuLaw audio conversion routines",
|
2005-11-14 02:13:35 +00:00
|
|
|
plugin_init, VERSION, GST_LICENSE, GST_PACKAGE_NAME, GST_PACKAGE_ORIGIN)
|