1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
|
/*
* GStreamer
* Copyright (c) 2010, Texas Instruments Incorporated
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation
* version 2.1 of the License.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
#include "gstducati.h"
#include "gstducatih264dec.h"
/* #include "gstducatimpeg4dec.h" */
#include "gstducatimpeg2dec.h"
/* #include "gstducativc1dec.h" */
/* #include "gstducativp6dec.h" */
/* #include "gstducativp7dec.h" */
/* #include "gstducatirvdec.h" */
/* #include "gstducatih264enc.h" */
/* #include "gstducatimpeg4enc.h" */
GST_DEBUG_CATEGORY (gst_ducati_debug);
#ifndef GST_DISABLE_GST_DEBUG
void
gst_ducati_log_extended_error_info (int error)
{
GST_ERROR ("Error %s%s%s%s%s%s%s%x",
XDM_ISFATALERROR (error) ? "[fatal] " : "",
XDM_ISUNSUPPORTEDPARAM (error) ? "[unsupported param] " : "",
XDM_ISUNSUPPORTEDINPUT (error) ? "[unsupported input] " : "",
XDM_ISCORRUPTEDHEADER (error) ? "[corrupted header] " : "",
XDM_ISCORRUPTEDDATA (error) ? "[corrupted data] " : "",
XDM_ISINSUFFICIENTDATA (error) ? "[insufficient data] " : "",
XDM_ISAPPLIEDCONCEALMENT (error) ? "[applied concealment] " : "", error);
}
#endif
static gboolean
plugin_init (GstPlugin * plugin)
{
GST_DEBUG_CATEGORY_INIT (gst_ducati_debug, "ducati", 0, "ducati");
/* TODO .. find some way to reasonably detect if the corresponding
* codecs are actually available..
*/
return gst_element_register (plugin, "ducatih264dec", GST_RANK_PRIMARY,
GST_TYPE_DUCATIH264DEC) &&
gst_element_register (plugin, "ducatimpeg2dec", GST_RANK_PRIMARY,
GST_TYPE_DUCATIMPEG2DEC)
/* gst_element_register (plugin, "ducatimpeg4dec", GST_RANK_PRIMARY, */
/* GST_TYPE_DUCATIMPEG4DEC) && */
/* gst_element_register (plugin, "ducativc1dec", GST_RANK_PRIMARY, */
/* GST_TYPE_DUCATIVC1DEC) && */
/* gst_element_register (plugin, "ducativp6dec", GST_RANK_PRIMARY, */
/* GST_TYPE_DUCATIVP6DEC) && */
/* gst_element_register (plugin, "ducativp7dec", GST_RANK_PRIMARY, */
/* GST_TYPE_DUCATIVP7DEC) && */
/* gst_element_register (plugin, "ducatirvdec", GST_RANK_PRIMARY, */
/* GST_TYPE_DUCATIRVDEC) */
/* && */
/* gst_element_register (plugin, "ducatih264enc", GST_RANK_PRIMARY + 1, */
/* GST_TYPE_DUCATIH264ENC) && */
/* gst_element_register (plugin, "ducatimpeg4enc", GST_RANK_PRIMARY + 1, */
/* GST_TYPE_DUCATIMPEG4ENC) */
;
}
/* PACKAGE: this is usually set by autotools depending on some _INIT macro
* in configure.ac and then written into and defined in config.h, but we can
* just set it ourselves here in case someone doesn't use autotools to
* compile this code. GST_PLUGIN_DEFINE needs PACKAGE to be defined.
*/
#ifndef PACKAGE
# define PACKAGE "ducati"
#endif
GST_PLUGIN_DEFINE (GST_VERSION_MAJOR, GST_VERSION_MINOR, ducati,
"Hardware accelerated codecs for OMAP4",
plugin_init, VERSION, "LGPL", "GStreamer", "http://gstreamer.net/")
|