summaryrefslogtreecommitdiff
path: root/src/post
diff options
context:
space:
mode:
Diffstat (limited to 'src/post')
-rw-r--r--src/post/Makefile.am3
-rw-r--r--src/post/audio/Makefile.am8
-rw-r--r--src/post/audio/audio_filters.c16
-rw-r--r--src/post/audio/audio_filters.h2
-rw-r--r--src/post/audio/stretch.c31
-rw-r--r--src/post/audio/upmix.c29
-rw-r--r--src/post/audio/upmix_mono.c27
-rw-r--r--src/post/audio/volnorm.c29
-rw-r--r--src/post/deinterlace/Makefile.am9
-rw-r--r--src/post/deinterlace/deinterlace.c2
-rw-r--r--src/post/deinterlace/plugins/Makefile.am50
-rw-r--r--src/post/deinterlace/plugins/greedy.c4
-rw-r--r--src/post/deinterlace/plugins/greedy2frame.c4
-rw-r--r--src/post/deinterlace/plugins/greedy2frame_template.c2
-rw-r--r--src/post/deinterlace/plugins/greedyh.asm1
-rw-r--r--src/post/deinterlace/plugins/kdetv_greedyh.c4
-rw-r--r--src/post/deinterlace/plugins/kdetv_tomsmocomp.c4
-rw-r--r--src/post/deinterlace/plugins/linearblend.c4
-rw-r--r--src/post/deinterlace/plugins/tomsmocomp/TomsMoCompAll.inc2
-rw-r--r--src/post/deinterlace/plugins/vfir.c4
-rw-r--r--src/post/deinterlace/speedy.c4
-rw-r--r--src/post/deinterlace/xine_plugin.c30
-rw-r--r--src/post/goom/Makefile.am47
-rwxr-xr-x[-rw-r--r--]src/post/goom/gfontlib.c0
-rwxr-xr-x[-rw-r--r--]src/post/goom/gfontlib.h0
-rwxr-xr-x[-rw-r--r--]src/post/goom/gfontrle.c0
-rw-r--r--src/post/goom/goom_core.c2
-rwxr-xr-x[-rw-r--r--]src/post/goom/mathtools.h0
-rw-r--r--src/post/goom/mmx.h4
-rwxr-xr-x[-rw-r--r--]src/post/goom/surf3d.c0
-rwxr-xr-x[-rw-r--r--]src/post/goom/surf3d.h0
-rwxr-xr-x[-rw-r--r--]src/post/goom/tentacle3d.c0
-rwxr-xr-x[-rw-r--r--]src/post/goom/tentacle3d.h0
-rwxr-xr-x[-rw-r--r--]src/post/goom/v3d.h0
-rw-r--r--src/post/goom/xine_goom.c24
-rw-r--r--src/post/mosaico/Makefile.am7
-rw-r--r--src/post/mosaico/mosaico.c31
-rw-r--r--src/post/mosaico/switch.c31
-rw-r--r--src/post/planar/Makefile.am44
-rw-r--r--src/post/planar/boxblur.c33
-rw-r--r--src/post/planar/denoise3d.c33
-rw-r--r--src/post/planar/eq.c33
-rw-r--r--src/post/planar/eq2.c33
-rw-r--r--src/post/planar/expand.c31
-rw-r--r--src/post/planar/fill.c30
-rw-r--r--src/post/planar/invert.c31
-rw-r--r--src/post/planar/noise.c37
-rw-r--r--src/post/planar/planar.c26
-rw-r--r--src/post/planar/pp.c59
-rw-r--r--src/post/planar/unsharp.c32
-rw-r--r--src/post/visualizations/Makefile.am9
-rw-r--r--src/post/visualizations/fft.c12
-rw-r--r--src/post/visualizations/fft.h1
-rw-r--r--src/post/visualizations/fftgraph.c29
-rw-r--r--src/post/visualizations/fftscope.c29
-rw-r--r--src/post/visualizations/fooviz.c31
-rw-r--r--src/post/visualizations/oscope.c29
-rw-r--r--src/post/visualizations/visualizations.c10
-rw-r--r--src/post/visualizations/visualizations.h2
59 files changed, 298 insertions, 691 deletions
diff --git a/src/post/Makefile.am b/src/post/Makefile.am
index 8408c3f3a..6c28b41f7 100644
--- a/src/post/Makefile.am
+++ b/src/post/Makefile.am
@@ -1,4 +1,3 @@
include $(top_srcdir)/misc/Makefile.common
-SUBDIRS = \
- planar goom visualizations mosaico deinterlace audio
+SUBDIRS = planar goom visualizations mosaico deinterlace audio
diff --git a/src/post/audio/Makefile.am b/src/post/audio/Makefile.am
index 41a364d0d..c2df5c21d 100644
--- a/src/post/audio/Makefile.am
+++ b/src/post/audio/Makefile.am
@@ -1,12 +1,12 @@
include $(top_srcdir)/misc/Makefile.common
+AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG)
+AM_LDFLAGS = $(xineplug_ldflags)
+
noinst_HEADERS = dsp.h filter.h window.h audio_filters.h
xinepost_LTLIBRARIES = xineplug_post_audio_filters.la
xineplug_post_audio_filters_la_SOURCES = \
upmix.c upmix_mono.c filter.c window.c stretch.c volnorm.c audio_filters.c
-xineplug_post_audio_filters_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) $(LTLIBINTL) -lm
-xineplug_post_audio_filters_la_CFLAGS = $(VISIBILITY_FLAG)
-xineplug_post_audio_filters_la_LDFLAGS = -avoid-version -module
-
+xineplug_post_audio_filters_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -lm
diff --git a/src/post/audio/audio_filters.c b/src/post/audio/audio_filters.c
index 8200db51b..517591b71 100644
--- a/src/post/audio/audio_filters.c
+++ b/src/post/audio/audio_filters.c
@@ -21,9 +21,9 @@
*/
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "audio_filters.h"
@@ -36,9 +36,9 @@ static const post_info_t volnorm_special_info = { XINE_POST_TYPE_AUDIO_FILTER
const plugin_info_t xine_plugin_info[] EXPORTED = {
/* type, API, "name", version, special_info, init_function */
- { PLUGIN_POST, 9, "upmix", XINE_VERSION_CODE, &upmix_special_info, &upmix_init_plugin },
- { PLUGIN_POST, 9, "upmix_mono", XINE_VERSION_CODE, &upmix_mono_special_info, &upmix_mono_init_plugin },
- { PLUGIN_POST, 9, "stretch", XINE_VERSION_CODE, &stretch_special_info, &stretch_init_plugin },
- { PLUGIN_POST, 9, "volnorm", XINE_VERSION_CODE, &volnorm_special_info, &volnorm_init_plugin },
- { PLUGIN_NONE, 0, "", 0, NULL, NULL }
+ { PLUGIN_POST, 10, "upmix", XINE_VERSION_CODE, &upmix_special_info, &upmix_init_plugin },
+ { PLUGIN_POST, 10, "upmix_mono", XINE_VERSION_CODE, &upmix_mono_special_info, &upmix_mono_init_plugin },
+ { PLUGIN_POST, 10, "stretch", XINE_VERSION_CODE, &stretch_special_info, &stretch_init_plugin },
+ { PLUGIN_POST, 10, "volnorm", XINE_VERSION_CODE, &volnorm_special_info, &volnorm_init_plugin },
+ { PLUGIN_NONE, 0, "", 0, NULL, NULL }
};
diff --git a/src/post/audio/audio_filters.h b/src/post/audio/audio_filters.h
index 6c064945a..8a0202751 100644
--- a/src/post/audio/audio_filters.h
+++ b/src/post/audio/audio_filters.h
@@ -20,7 +20,7 @@
* catalog for audio filter plugins
*/
-#include "xine_internal.h"
+#include <xine/xine_internal.h>
void *upmix_init_plugin(xine_t *xine, void *data);
diff --git a/src/post/audio/stretch.c b/src/post/audio/stretch.c
index 8be58d8c5..37952cd56 100644
--- a/src/post/audio/stretch.c
+++ b/src/post/audio/stretch.c
@@ -22,11 +22,11 @@
#include <stdio.h>
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "dsp.h"
-#include "resample.h"
+#include <xine/resample.h>
#include "audio_filters.h"
@@ -659,33 +659,18 @@ static post_plugin_t *stretch_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *stretch_get_identifier(post_class_t *class_gen)
-{
- return "stretch";
-}
-
-static char *stretch_get_description(post_class_t *class_gen)
-{
- return "Time stretch by a given factor, optionally preserving pitch";
-}
-
-static void stretch_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
/* plugin class initialization function */
void *stretch_init_plugin(xine_t *xine, void *data)
{
- post_class_stretch_t *class = (post_class_stretch_t *)malloc(sizeof(post_class_stretch_t));
+ post_class_stretch_t *class = (post_class_stretch_t *)xine_xmalloc(sizeof(post_class_stretch_t));
if (!class)
return NULL;
class->post_class.open_plugin = stretch_open_plugin;
- class->post_class.get_identifier = stretch_get_identifier;
- class->post_class.get_description = stretch_get_description;
- class->post_class.dispose = stretch_class_dispose;
+ class->post_class.identifier = "stretch";
+ class->post_class.description = N_("Time stretch by a given factor, optionally preserving pitch");
+ class->post_class.dispose = default_post_class_dispose;
class->xine = xine;
diff --git a/src/post/audio/upmix.c b/src/post/audio/upmix.c
index 725439c1f..3e5c2e65b 100644
--- a/src/post/audio/upmix.c
+++ b/src/post/audio/upmix.c
@@ -26,9 +26,9 @@
#include <stdio.h>
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "dsp.h"
#include "audio_filters.h"
@@ -414,33 +414,18 @@ static post_plugin_t *upmix_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *upmix_get_identifier(post_class_t *class_gen)
-{
- return "upmix";
-}
-
-static char *upmix_get_description(post_class_t *class_gen)
-{
- return "upmix";
-}
-
-static void upmix_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
/* plugin class initialization function */
void *upmix_init_plugin(xine_t *xine, void *data)
{
- post_class_upmix_t *class = (post_class_upmix_t *)malloc(sizeof(post_class_upmix_t));
+ post_class_upmix_t *class = (post_class_upmix_t *)xine_xmalloc(sizeof(post_class_upmix_t));
if (!class)
return NULL;
class->post_class.open_plugin = upmix_open_plugin;
- class->post_class.get_identifier = upmix_get_identifier;
- class->post_class.get_description = upmix_get_description;
- class->post_class.dispose = upmix_class_dispose;
+ class->post_class.identifier = "upmix";
+ class->post_class.description = N_("upmix");
+ class->post_class.dispose = default_post_class_dispose;
class->xine = xine;
diff --git a/src/post/audio/upmix_mono.c b/src/post/audio/upmix_mono.c
index 2d3429788..193989586 100644
--- a/src/post/audio/upmix_mono.c
+++ b/src/post/audio/upmix_mono.c
@@ -31,8 +31,8 @@
#define LOG
*/
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "audio_filters.h"
@@ -329,33 +329,18 @@ static post_plugin_t *upmix_mono_open_plugin(post_class_t *class_gen, int inputs
return &this->post;
}
-static char *upmix_mono_get_identifier(post_class_t *class_gen)
-{
- return "upmix_mono";
-}
-
-static char *upmix_mono_get_description(post_class_t *class_gen)
-{
- return "converts Mono into Stereo";
-}
-
-static void upmix_mono_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
/* plugin class initialization function */
void *upmix_mono_init_plugin(xine_t *xine, void *data)
{
- post_class_upmix_mono_t *class = (post_class_upmix_mono_t *)malloc(sizeof(post_class_upmix_mono_t));
+ post_class_upmix_mono_t *class = (post_class_upmix_mono_t *)xine_xmalloc(sizeof(post_class_upmix_mono_t));
if (!class)
return NULL;
class->post_class.open_plugin = upmix_mono_open_plugin;
- class->post_class.get_identifier = upmix_mono_get_identifier;
- class->post_class.get_description = upmix_mono_get_description;
- class->post_class.dispose = upmix_mono_class_dispose;
+ class->post_class.identifier = "upmix_mono";
+ class->post_class.description = N_("converts Mono into Stereo");
+ class->post_class.dispose = default_post_class_dispose;
class->xine = xine;
diff --git a/src/post/audio/volnorm.c b/src/post/audio/volnorm.c
index 4fdb7dbfc..9ea774564 100644
--- a/src/post/audio/volnorm.c
+++ b/src/post/audio/volnorm.c
@@ -25,9 +25,9 @@
#include <stdio.h>
#include <math.h>
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "dsp.h"
#include "audio_filters.h"
@@ -446,33 +446,18 @@ static post_plugin_t *volnorm_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *volnorm_get_identifier(post_class_t *class_gen)
-{
- return "volnorm";
-}
-
-static char *volnorm_get_description(post_class_t *class_gen)
-{
- return "Normalize volume";
-}
-
-static void volnorm_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
/* plugin class initialization function */
void *volnorm_init_plugin(xine_t *xine, void *data)
{
- post_class_volnorm_t *class = (post_class_volnorm_t *)malloc(sizeof(post_class_volnorm_t));
+ post_class_volnorm_t *class = (post_class_volnorm_t *)xine_xmalloc(sizeof(post_class_volnorm_t));
if (!class)
return NULL;
class->post_class.open_plugin = volnorm_open_plugin;
- class->post_class.get_identifier = volnorm_get_identifier;
- class->post_class.get_description = volnorm_get_description;
- class->post_class.dispose = volnorm_class_dispose;
+ class->post_class.identifier = "volnorm";
+ class->post_class.description = N_("Normalize volume");
+ class->post_class.dispose = default_post_class_dispose;
class->xine = xine;
diff --git a/src/post/deinterlace/Makefile.am b/src/post/deinterlace/Makefile.am
index d382a2e98..1a90b72bf 100644
--- a/src/post/deinterlace/Makefile.am
+++ b/src/post/deinterlace/Makefile.am
@@ -1,8 +1,9 @@
include $(top_srcdir)/misc/Makefile.common
-SUBDIRS = plugins
+AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG)
+AM_LDFLAGS = $(xineplug_ldflags) $(IMPURE_TEXT_LDFLAGS)
-EXTRA_DIST =
+SUBDIRS = plugins
xinepost_LTLIBRARIES = xineplug_post_tvtime.la
@@ -11,8 +12,4 @@ xineplug_post_tvtime_la_SOURCES = xine_plugin.c \
xineplug_post_tvtime_la_LIBADD = $(XINE_LIB) $(LTLIBINTL) \
$(top_builddir)/src/post/deinterlace/plugins/libdeinterlaceplugins.la
-xineplug_post_tvtime_la_CFLAGS = $(VISIBILITY_FLAG)
-xineplug_post_tvtime_la_LDFLAGS = -avoid-version -module \
- @IMPURE_TEXT_LDFLAGS@
-
noinst_HEADERS = deinterlace.h pulldown.h speedtools.h speedy.h tvtime.h
diff --git a/src/post/deinterlace/deinterlace.c b/src/post/deinterlace/deinterlace.c
index 8e4a3bb00..5c0356c55 100644
--- a/src/post/deinterlace/deinterlace.c
+++ b/src/post/deinterlace/deinterlace.c
@@ -31,7 +31,7 @@
*/
#include "deinterlace.h"
-#include "xine_internal.h"
+#include <xine/xine_internal.h>
typedef struct methodlist_item_s methodlist_item_t;
diff --git a/src/post/deinterlace/plugins/Makefile.am b/src/post/deinterlace/plugins/Makefile.am
index 5f0997eb8..4348d87e2 100644
--- a/src/post/deinterlace/plugins/Makefile.am
+++ b/src/post/deinterlace/plugins/Makefile.am
@@ -17,6 +17,11 @@ include $(top_srcdir)/misc/Makefile.common
# along with this program; if not, write to the Free Software
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+# libpostproc is here so we can use their nice mangle.h
+AM_CFLAGS = $(VISIBILITY_FLAG)
+AM_CPPFLAGS = -I$(top_srcdir)/src/post/deinterlace \
+ -I$(top_srcdir)/src/xine-utils
+
EXTRA_DIST = greedy2frame_template.c greedyh.asm \
tomsmocomp/SearchLoop0A.inc tomsmocomp/SearchLoopBottom.inc \
tomsmocomp/SearchLoopEdgeA.inc tomsmocomp/SearchLoopEdgeA8.inc \
@@ -28,27 +33,26 @@ EXTRA_DIST = greedy2frame_template.c greedyh.asm \
tomsmocomp/TomsMoCompAll2.inc tomsmocomp/WierdBob.inc \
tomsmocomp/tomsmocompmacros.h x86-64_macros.inc
-# libpostproc is here so we can use their nice mangle.h
-AM_CFLAGS = -I$(top_srcdir)/src/post/deinterlace \
- -I$(top_srcdir)/src/xine-utils
-
-# Avoid "can't find register" failures with -O0, -O2, -O3 (gcc 4.0)
-libdeinterlaceplugins_la-kdetv_greedyh.o libdeinterlaceplugins_la-kdetv_greedyh.lo: CFLAGS=$(shell echo @CFLAGS@ | sed -e 's/$$/ -O1/')
-
-noinst_LTLIBRARIES = libdeinterlaceplugins.la
-
-libdeinterlaceplugins_la_SOURCES = \
- double.c \
- greedy.c \
- linear.c \
- linearblend.c \
- vfir.c \
- weave.c \
- greedy2frame.c \
- scalerbob.c \
- kdetv_greedyh.c \
- kdetv_tomsmocomp.c
-libdeinterlaceplugins_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS)
-libdeinterlaceplugins_la_LDFLAGS = -avoid-version -module
-
noinst_HEADERS = plugins.h greedyhmacros.h
+
+if DEBUG_BUILD
+debug_sources = greedy2frame.c
+nodebug_sources =
+else
+debug_sources =
+nodebug_sources = greedy2frame.c
+endif
+
+# per-object CFLAGS -- drop optimization on kdetv_greedyh.c so that gcc
+# doesn't run out of general registers trying to compile it.
+
+noinst_LTLIBRARIES = libdeinterlacepluginsO1.la libdeinterlaceplugins.la
+libdeinterlacepluginsO1_la_SOURCES = kdetv_greedyh.c $(debug_sources)
+libdeinterlacepluginsO1_la_CFLAGS = $(O1_CFLAGS) $(AM_CFLAGS)
+
+libdeinterlaceplugins_la_SOURCES = double.c greedy.c linear.c linearblend.c \
+ vfir.c weave.c scalerbob.c kdetv_tomsmocomp.c \
+ $(nodebug_sources)
+libdeinterlaceplugins_la_LIBADD = $(XINE_LIB) libdeinterlacepluginsO1.la
+libdeinterlaceplugins_la_CFLAGS = $(DEFAULT_OCFLAGS) $(AM_CFLAGS)
+libdeinterlaceplugins_la_LDFLAGS = $(AM_LDFLAGS) $(xineplug_ldflags)
diff --git a/src/post/deinterlace/plugins/greedy.c b/src/post/deinterlace/plugins/greedy.c
index b5fcad3e5..fc8013a6d 100644
--- a/src/post/deinterlace/plugins/greedy.c
+++ b/src/post/deinterlace/plugins/greedy.c
@@ -32,8 +32,8 @@
#include <stdint.h>
#endif
-#include "attributes.h"
-#include "xineutils.h"
+#include <xine/attributes.h>
+#include <xine/xineutils.h>
#include "deinterlace.h"
#include "speedtools.h"
#include "speedy.h"
diff --git a/src/post/deinterlace/plugins/greedy2frame.c b/src/post/deinterlace/plugins/greedy2frame.c
index 57e3228ac..af27d76ee 100644
--- a/src/post/deinterlace/plugins/greedy2frame.c
+++ b/src/post/deinterlace/plugins/greedy2frame.c
@@ -31,8 +31,8 @@
#include <stdint.h>
#endif
-#include "attributes.h"
-#include "xineutils.h"
+#include <xine/attributes.h>
+#include <xine/xineutils.h>
#include "deinterlace.h"
#include "speedtools.h"
#include "speedy.h"
diff --git a/src/post/deinterlace/plugins/greedy2frame_template.c b/src/post/deinterlace/plugins/greedy2frame_template.c
index 1067e2cb8..0d9ab6769 100644
--- a/src/post/deinterlace/plugins/greedy2frame_template.c
+++ b/src/post/deinterlace/plugins/greedy2frame_template.c
@@ -100,8 +100,6 @@
static int64_t qwGreedyTwoFrameThreshold;
#endif
-#include <mangle.h>
-
#if defined(IS_SSE)
static void DeinterlaceGreedy2Frame_SSE(uint8_t *output, int outstride,
deinterlace_frame_data_t *data,
diff --git a/src/post/deinterlace/plugins/greedyh.asm b/src/post/deinterlace/plugins/greedyh.asm
index 11b28ca76..c96bfbf2c 100644
--- a/src/post/deinterlace/plugins/greedyh.asm
+++ b/src/post/deinterlace/plugins/greedyh.asm
@@ -17,7 +17,6 @@
/////////////////////////////////////////////////////////////////////////////
#include "x86-64_macros.inc"
-#include <mangle.h>
#if !defined(MASKS_DEFINED)
#define MASKS_DEFINED
diff --git a/src/post/deinterlace/plugins/kdetv_greedyh.c b/src/post/deinterlace/plugins/kdetv_greedyh.c
index 5ec48e4a2..2207772ca 100644
--- a/src/post/deinterlace/plugins/kdetv_greedyh.c
+++ b/src/post/deinterlace/plugins/kdetv_greedyh.c
@@ -31,8 +31,8 @@
#include <stdint.h>
#endif
-#include "attributes.h"
-#include "xineutils.h"
+#include <xine/attributes.h>
+#include <xine/xineutils.h>
#include "deinterlace.h"
#include "speedtools.h"
#include "speedy.h"
diff --git a/src/post/deinterlace/plugins/kdetv_tomsmocomp.c b/src/post/deinterlace/plugins/kdetv_tomsmocomp.c
index ae0fa0363..0f87b913f 100644
--- a/src/post/deinterlace/plugins/kdetv_tomsmocomp.c
+++ b/src/post/deinterlace/plugins/kdetv_tomsmocomp.c
@@ -31,8 +31,8 @@
#include <stdint.h>
#endif
-#include "attributes.h"
-#include "xineutils.h"
+#include <xine/attributes.h>
+#include <xine/xineutils.h>
#include "deinterlace.h"
#include "speedtools.h"
#include "speedy.h"
diff --git a/src/post/deinterlace/plugins/linearblend.c b/src/post/deinterlace/plugins/linearblend.c
index 96e56063f..4664a4969 100644
--- a/src/post/deinterlace/plugins/linearblend.c
+++ b/src/post/deinterlace/plugins/linearblend.c
@@ -31,8 +31,8 @@
#include <stdint.h>
#endif
-#include "attributes.h"
-#include "xineutils.h"
+#include <xine/attributes.h>
+#include <xine/xineutils.h>
#include "speedtools.h"
#include "speedy.h"
#include "deinterlace.h"
diff --git a/src/post/deinterlace/plugins/tomsmocomp/TomsMoCompAll.inc b/src/post/deinterlace/plugins/tomsmocomp/TomsMoCompAll.inc
index 5870d77be..3af46d8fa 100644
--- a/src/post/deinterlace/plugins/tomsmocomp/TomsMoCompAll.inc
+++ b/src/post/deinterlace/plugins/tomsmocomp/TomsMoCompAll.inc
@@ -21,8 +21,6 @@
// See www.eff.org for details
/////////////////////////////////////////////////////////////////////////////
-#include <mangle.h>
-
#if !defined(MASKS_DEFINED)
#define MASKS_DEFINED
static const int64_t __attribute__((__used__)) Max_Mov = 0x0404040404040404ull;
diff --git a/src/post/deinterlace/plugins/vfir.c b/src/post/deinterlace/plugins/vfir.c
index e66d7c789..d66c92952 100644
--- a/src/post/deinterlace/plugins/vfir.c
+++ b/src/post/deinterlace/plugins/vfir.c
@@ -34,8 +34,8 @@
#include <stdint.h>
#endif
-#include "attributes.h"
-#include "xineutils.h"
+#include <xine/attributes.h>
+#include <xine/xineutils.h>
#include "speedy.h"
#include "deinterlace.h"
#include "plugins.h"
diff --git a/src/post/deinterlace/speedy.c b/src/post/deinterlace/speedy.c
index a980780d7..d93b56c7b 100644
--- a/src/post/deinterlace/speedy.c
+++ b/src/post/deinterlace/speedy.c
@@ -62,8 +62,8 @@
#include <stdint.h>
#endif
-#include "attributes.h"
-#include "xineutils.h"
+#include <xine/attributes.h>
+#include <xine/xineutils.h>
#include "speedtools.h"
#include "speedy.h"
diff --git a/src/post/deinterlace/xine_plugin.c b/src/post/deinterlace/xine_plugin.c
index 8115198af..a51712338 100644
--- a/src/post/deinterlace/xine_plugin.c
+++ b/src/post/deinterlace/xine_plugin.c
@@ -27,10 +27,10 @@
#define LOG
*/
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
-#include "xine_buffer.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
+#include <xine/xine_buffer.h>
#include <pthread.h>
#include "tvtime.h"
@@ -47,7 +47,7 @@ static const post_info_t deinterlace_special_info = { XINE_POST_TYPE_VIDEO_FILTE
const plugin_info_t xine_plugin_info[] EXPORTED = {
/* type, API, "name", version, special_info, init_function */
- { PLUGIN_POST | PLUGIN_MUST_PRELOAD, 9, "tvtime", XINE_VERSION_CODE, &deinterlace_special_info, &deinterlace_init_plugin },
+ { PLUGIN_POST | PLUGIN_MUST_PRELOAD, 10, "tvtime", XINE_VERSION_CODE, &deinterlace_special_info, &deinterlace_init_plugin },
{ PLUGIN_NONE, 0, "", 0, NULL, NULL }
};
@@ -56,8 +56,8 @@ typedef struct post_plugin_deinterlace_s post_plugin_deinterlace_t;
#define MAX_NUM_METHODS 30
static const char *enum_methods[MAX_NUM_METHODS];
-static char *enum_pulldown[] = { "none", "vektor", NULL };
-static char *enum_framerate[] = { "full", "half_top", "half_bottom", NULL };
+static const char *const enum_pulldown[] = { "none", "vektor", NULL };
+static const char *const enum_framerate[] = { "full", "half_top", "half_bottom", NULL };
static void *help_string;
@@ -268,8 +268,6 @@ static xine_post_api_t post_api = {
static post_plugin_t *deinterlace_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *deinterlace_get_identifier(post_class_t *class_gen);
-static char *deinterlace_get_description(post_class_t *class_gen);
static void deinterlace_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
@@ -299,8 +297,8 @@ static void *deinterlace_init_plugin(xine_t *xine, void *data)
return NULL;
class->class.open_plugin = deinterlace_open_plugin;
- class->class.get_identifier = deinterlace_get_identifier;
- class->class.get_description = deinterlace_get_description;
+ class->class.identifier = "tvtime";
+ class->class.description = N_("advanced deinterlacer plugin with pulldown detection");
class->class.dispose = deinterlace_class_dispose;
@@ -412,16 +410,6 @@ static post_plugin_t *deinterlace_open_plugin(post_class_t *class_gen, int input
return &this->post;
}
-static char *deinterlace_get_identifier(post_class_t *class_gen)
-{
- return "tvtime";
-}
-
-static char *deinterlace_get_description(post_class_t *class_gen)
-{
- return "advanced deinterlacer plugin with pulldown detection";
-}
-
static void deinterlace_class_dispose(post_class_t *class_gen)
{
xine_buffer_free(help_string);
diff --git a/src/post/goom/Makefile.am b/src/post/goom/Makefile.am
index c01482917..22b4af79f 100644
--- a/src/post/goom/Makefile.am
+++ b/src/post/goom/Makefile.am
@@ -1,36 +1,15 @@
include $(top_srcdir)/misc/Makefile.common
-EXTRA_DIST = mmx.c xmmx.c ppc_drawings.s ppc_zoom_ultimate.s diff_against_release.patch \
- gfontrle.c mathtools.c
-
-## -fomit-frame-pointer segfaults here
-## Use -O2 if -Os is stripped or x86 does not build
-#CFLAGS = `echo @CFLAGS@ | sed -e 's/-fomit-frame-pointer//g;s/-Os/-O2/g'`
-CFLAGS = `echo @CFLAGS@ | sed -e 's/-Os/-O2/g'`
-
-# Avoid errors with -O0
-xineplug_post_goom_la-xmmx.o xineplug_post_goom_la-xmmx.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'`
-
-xinepost_LTLIBRARIES = xineplug_post_goom.la
+AM_CFLAGS = $(VISIBILITY_FLAG)
## doesn't work
-#if PPC_ARCH
+#if ARCH_PPC
#extra_files = ppc_drawings.s ppc_zoom_ultimate.s
#AM_CPPFLAGS = -DCPU_POWERPC
#endif
-if HAVE_MMX
-extra_files = mmx.c xmmx.c
-endif
-
-xineplug_post_goom_la_SOURCES = $(extra_files) xine_goom.c \
- config_param.c convolve_fx.c cpu_info.c drawmethods.c filters.c flying_stars_fx.c \
- gfontlib.c goom_core.c goom_tools.c goomsl.c goomsl_hash.c goomsl_heap.c \
- goomsl_lex.c goomsl_yacc.c graphic.c ifs.c lines.c \
- plugin_info.c sound_tester.c surf3d.c tentacle3d.c v3d.c
-xineplug_post_goom_la_LIBADD = $(XINE_LIB) $(GOOM_LIBS) $(PTHREAD_LIBS) $(LTLIBINTL) -lm
-xineplug_post_goom_la_CFLAGS = $(VISIBILITY_FLAG)
-xineplug_post_goom_la_LDFLAGS = -avoid-version -module
+EXTRA_DIST = mmx.c xmmx.c ppc_drawings.s ppc_zoom_ultimate.s diff_against_release.patch \
+ gfontrle.c mathtools.c
noinst_HEADERS = cpu_info.h default_scripts.h drawmethods.h gfontlib.h goom.h \
goom_config.h goom_config_param.h goom_filters.h goom_fx.h goom_graphic.h \
@@ -38,3 +17,21 @@ noinst_HEADERS = cpu_info.h default_scripts.h drawmethods.h gfontlib.h goom.h \
goomsl_heap.h goomsl_private.h goomsl_yacc.h ifs.h lines.h mathtools.h mmx.h \
ppc_drawings.h ppc_zoom_ultimate.h sound_tester.h surf3d.h tentacle3d.h v3d.h \
motif_goom1.h motif_goom2.h
+
+noinst_LTLIBRARIES = libpost_goom_asm.la
+libpost_goom_asm_la_SOURCES = xmmx.c
+if DEBUG_BUILD
+libpost_goom_asm_la_CFLAGS = $(O1_CFLAGS) $(AM_CFLAGS)
+else
+libpost_goom_asm_la_CFLAGS = $(DEFAULT_OCFLAGS) $(AM_CFLAGS)
+endif
+
+xinepost_LTLIBRARIES = xineplug_post_goom.la
+xineplug_post_goom_la_SOURCES = mmx.c xine_goom.c \
+ config_param.c convolve_fx.c cpu_info.c drawmethods.c filters.c flying_stars_fx.c \
+ gfontlib.c goom_core.c goom_tools.c goomsl.c goomsl_hash.c goomsl_heap.c \
+ goomsl_lex.c goomsl_yacc.c graphic.c ifs.c lines.c \
+ plugin_info.c sound_tester.c surf3d.c tentacle3d.c v3d.c
+xineplug_post_goom_la_LIBADD = $(XINE_LIB) $(GOOM_LIBS) $(PTHREAD_LIBS) $(LTLIBINTL) -lm $(noinst_LTLIBRARIES)
+xineplug_post_goom_la_CFLAGS = $(DEFAULT_OCFLAGS) $(AM_CFLAGS)
+xineplug_post_goom_la_LDFLAGS = $(AM_LDFLAGS) $(xineplug_ldflags)
diff --git a/src/post/goom/gfontlib.c b/src/post/goom/gfontlib.c
index 2bc366305..2bc366305 100644..100755
--- a/src/post/goom/gfontlib.c
+++ b/src/post/goom/gfontlib.c
diff --git a/src/post/goom/gfontlib.h b/src/post/goom/gfontlib.h
index 0520b7da9..0520b7da9 100644..100755
--- a/src/post/goom/gfontlib.h
+++ b/src/post/goom/gfontlib.h
diff --git a/src/post/goom/gfontrle.c b/src/post/goom/gfontrle.c
index a22545a1e..a22545a1e 100644..100755
--- a/src/post/goom/gfontrle.c
+++ b/src/post/goom/gfontrle.c
diff --git a/src/post/goom/goom_core.c b/src/post/goom/goom_core.c
index 35fd7fc35..b69994d8f 100644
--- a/src/post/goom/goom_core.c
+++ b/src/post/goom/goom_core.c
@@ -26,7 +26,7 @@
#include "goom_fx.h"
#include "goomsl.h"
-#include "xine_internal.h"
+#include <xine/xine_internal.h>
/* #define VERBOSE */
diff --git a/src/post/goom/mathtools.h b/src/post/goom/mathtools.h
index 165fc66b0..165fc66b0 100644..100755
--- a/src/post/goom/mathtools.h
+++ b/src/post/goom/mathtools.h
diff --git a/src/post/goom/mmx.h b/src/post/goom/mmx.h
index b650d8b12..6861b7cfe 100644
--- a/src/post/goom/mmx.h
+++ b/src/post/goom/mmx.h
@@ -31,6 +31,8 @@
# include "config.h"
#endif
+#include <xine/attributes.h>
+
#include "goom_graphic.h"
/* Warning: at this writing, the version of GAS packaged
@@ -58,7 +60,7 @@ typedef union {
char b[8]; /* 8 Byte (8-bit) values */
unsigned char ub[8]; /* 8 Unsigned Byte */
float s[2]; /* Single-precision (32-bit) value */
-} __attribute__ ((aligned (8))) mmx_t; /* On an 8-byte (64-bit) boundary */
+} ATTR_ALIGN(8) mmx_t; /* On an 8-byte (64-bit) boundary */
diff --git a/src/post/goom/surf3d.c b/src/post/goom/surf3d.c
index ba8c69094..ba8c69094 100644..100755
--- a/src/post/goom/surf3d.c
+++ b/src/post/goom/surf3d.c
diff --git a/src/post/goom/surf3d.h b/src/post/goom/surf3d.h
index 482b6a090..482b6a090 100644..100755
--- a/src/post/goom/surf3d.h
+++ b/src/post/goom/surf3d.h
diff --git a/src/post/goom/tentacle3d.c b/src/post/goom/tentacle3d.c
index e1e2157e7..e1e2157e7 100644..100755
--- a/src/post/goom/tentacle3d.c
+++ b/src/post/goom/tentacle3d.c
diff --git a/src/post/goom/tentacle3d.h b/src/post/goom/tentacle3d.h
index ad0858fad..ad0858fad 100644..100755
--- a/src/post/goom/tentacle3d.h
+++ b/src/post/goom/tentacle3d.h
diff --git a/src/post/goom/v3d.h b/src/post/goom/v3d.h
index 7690847f2..7690847f2 100644..100755
--- a/src/post/goom/v3d.h
+++ b/src/post/goom/v3d.h
diff --git a/src/post/goom/xine_goom.c b/src/post/goom/xine_goom.c
index 5cd5406b2..dfc4036f1 100644
--- a/src/post/goom/xine_goom.c
+++ b/src/post/goom/xine_goom.c
@@ -35,9 +35,9 @@
*/
#include "config.h"
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "goom.h"
@@ -116,7 +116,7 @@ static const post_info_t goom_special_info = {
const plugin_info_t xine_plugin_info[] EXPORTED = {
/* type, API, "name", version, special_info, init_function */
- { PLUGIN_POST | PLUGIN_MUST_PRELOAD, 9, "goom", XINE_VERSION_CODE, &goom_special_info, &goom_init_plugin },
+ { PLUGIN_POST | PLUGIN_MUST_PRELOAD, 10, "goom", XINE_VERSION_CODE, &goom_special_info, &goom_init_plugin },
{ PLUGIN_NONE, 0, "", 0, NULL, NULL }
};
@@ -125,8 +125,6 @@ const plugin_info_t xine_plugin_info[] EXPORTED = {
static post_plugin_t *goom_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *goom_get_identifier(post_class_t *class_gen);
-static char *goom_get_description(post_class_t *class_gen);
static void goom_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
@@ -194,8 +192,8 @@ static void *goom_init_plugin(xine_t *xine, void *data)
return NULL;
this->class.open_plugin = goom_open_plugin;
- this->class.get_identifier = goom_get_identifier;
- this->class.get_description = goom_get_description;
+ this->class.identifier = "goom";
+ this->class.description = N_("What a GOOM");
this->class.dispose = goom_class_dispose;
this->ip = NULL;
this->xine = xine;
@@ -307,16 +305,6 @@ static post_plugin_t *goom_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *goom_get_identifier(post_class_t *class_gen)
-{
- return "goom";
-}
-
-static char *goom_get_description(post_class_t *class_gen)
-{
- return "What a GOOM";
-}
-
static void goom_class_dispose(post_class_t *class_gen)
{
post_class_goom_t *this = (post_class_goom_t*) class_gen;
diff --git a/src/post/mosaico/Makefile.am b/src/post/mosaico/Makefile.am
index af027b6e6..106d480c3 100644
--- a/src/post/mosaico/Makefile.am
+++ b/src/post/mosaico/Makefile.am
@@ -1,13 +1,12 @@
include $(top_srcdir)/misc/Makefile.common
+AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG)
+AM_LDFLAGS = $(xineplug_ldflags)
+
xinepost_LTLIBRARIES = xineplug_post_mosaico.la xineplug_post_switch.la
xineplug_post_mosaico_la_SOURCES = mosaico.c
xineplug_post_mosaico_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) $(LTLIBINTL)
-xineplug_post_mosaico_la_CFLAGS = $(VISIBILITY_FLAG)
-xineplug_post_mosaico_la_LDFLAGS = -avoid-version -module
xineplug_post_switch_la_SOURCES = switch.c
xineplug_post_switch_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) $(LTLIBINTL)
-xineplug_post_switch_la_CFLAGS = $(VISIBILITY_FLAG)
-xineplug_post_switch_la_LDFLAGS = -avoid-version -module
diff --git a/src/post/mosaico/mosaico.c b/src/post/mosaico/mosaico.c
index d99bab43b..0a4031bde 100644
--- a/src/post/mosaico/mosaico.c
+++ b/src/post/mosaico/mosaico.c
@@ -32,8 +32,8 @@
#define LOG
*/
-#include "xine_internal.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
/* FIXME: This plugin needs to handle overlays as well. */
@@ -45,7 +45,7 @@ static const post_info_t mosaico_special_info = { XINE_POST_TYPE_VIDEO_COMPOSE }
const plugin_info_t xine_plugin_info[] EXPORTED = {
/* type, API, "name", version, special_info, init_function */
- { PLUGIN_POST, 9, "mosaico", XINE_VERSION_CODE, &mosaico_special_info, &mosaico_init_plugin },
+ { PLUGIN_POST, 10, "mosaico", XINE_VERSION_CODE, &mosaico_special_info, &mosaico_init_plugin },
{ PLUGIN_NONE, 0, "", 0, NULL, NULL }
};
@@ -100,9 +100,6 @@ struct post_mosaico_s {
static post_plugin_t *mosaico_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *mosaico_get_identifier(post_class_t *class_gen);
-static char *mosaico_get_description(post_class_t *class_gen);
-static void mosaico_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void mosaico_dispose(post_plugin_t *this_gen);
@@ -132,9 +129,9 @@ static void *mosaico_init_plugin(xine_t *xine, void *data)
return NULL;
this->class.open_plugin = mosaico_open_plugin;
- this->class.get_identifier = mosaico_get_identifier;
- this->class.get_description = mosaico_get_description;
- this->class.dispose = mosaico_class_dispose;
+ this->class.identifier = "mosaico";
+ this->class.description = N_("Mosaico is a picture in picture (pip) post plugin");
+ this->class.dispose = default_post_class_dispose;
this->xine = xine;
return &this->class;
@@ -205,22 +202,6 @@ static post_plugin_t *mosaico_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *mosaico_get_identifier(post_class_t *class_gen)
-{
- return "mosaico";
-}
-
-static char *mosaico_get_description(post_class_t *class_gen)
-{
- return "Mosaico is a picture in picture (pip) post plugin";
-}
-
-static void mosaico_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void mosaico_dispose(post_plugin_t *this_gen)
{
post_mosaico_t *this = (post_mosaico_t *)this_gen;
diff --git a/src/post/mosaico/switch.c b/src/post/mosaico/switch.c
index a01c821b2..90dbf2690 100644
--- a/src/post/mosaico/switch.c
+++ b/src/post/mosaico/switch.c
@@ -28,8 +28,8 @@
#define LOG
*/
-#include "xine_internal.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
/* FIXME: This plugin needs to handle overlays as well. */
@@ -41,7 +41,7 @@ static const post_info_t switch_special_info = { XINE_POST_TYPE_VIDEO_COMPOSE };
const plugin_info_t xine_plugin_info[] EXPORTED = {
/* type, API, "name", version, special_info, init_function */
- { PLUGIN_POST, 9, "switch", XINE_VERSION_CODE, &switch_special_info, &switch_init_plugin },
+ { PLUGIN_POST, 10, "switch", XINE_VERSION_CODE, &switch_special_info, &switch_init_plugin },
{ PLUGIN_NONE, 0, "", 0, NULL, NULL }
};
@@ -82,9 +82,6 @@ struct post_switch_s {
static post_plugin_t *switch_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *switch_get_identifier(post_class_t *class_gen);
-static char *switch_get_description(post_class_t *class_gen);
-static void switch_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void switch_dispose(post_plugin_t *this_gen);
@@ -107,9 +104,9 @@ static void *switch_init_plugin(xine_t *xine, void *data)
return NULL;
this->class.open_plugin = switch_open_plugin;
- this->class.get_identifier = switch_get_identifier;
- this->class.get_description = switch_get_description;
- this->class.dispose = switch_class_dispose;
+ this->class.identifier = "switch";
+ this->class.description = N_("Switch is a post plugin able to switch at any time between different streams");
+ this->class.dispose = default_post_class_dispose;
this->xine = xine;
return &this->class;
@@ -168,22 +165,6 @@ static post_plugin_t *switch_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *switch_get_identifier(post_class_t *class_gen)
-{
- return "switch";
-}
-
-static char *switch_get_description(post_class_t *class_gen)
-{
- return "Switch is a post plugin able to switch at any time between different streams";
-}
-
-static void switch_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void switch_dispose(post_plugin_t *this_gen)
{
post_switch_t *this = (post_switch_t *)this_gen;
diff --git a/src/post/planar/Makefile.am b/src/post/planar/Makefile.am
index 36405bfc2..8caffc6b9 100644
--- a/src/post/planar/Makefile.am
+++ b/src/post/planar/Makefile.am
@@ -1,34 +1,30 @@
include $(top_srcdir)/misc/Makefile.common
-POSTPROC_INT_LIB = $(top_builddir)/src/libffmpeg/libavcodec/libpostproc/libpostprocess.la
+AM_CFLAGS = $(VISIBILITY_FLAG) $(ff_cflags)
+AM_CPPFLAGS =
+AM_LDFLAGS =
-if HAVE_FFMPEG
+if WITH_EXTERNAL_FFMPEG
postproc_lib = $(FFMPEG_POSTPROC_LIBS)
-ff_cflags = $(FFMPEG_POSTPROC_CFLAGS)
+ff_cflags = $(FFMPEG_POSTPROC_CFLAGS)
else
-ff_cflags = -I$(top_srcdir)/src/libffmpeg/libavcodec
-postproc_lib = $(POSTPROC_INT_LIB)
-postproc_dep = $(postproc_lib)
-endif
+AM_CPPFLAGS += -I$(top_srcdir)/contrib/ffmpeg/
+postproc_lib = $(top_builddir)/contrib/ffmpeg/libpostproc/libpostproc.a \
+ $(top_builddir)/contrib/ffmpeg/libavutil/libavutil.a
-# -fomit-frame-pointer is always needed. it might cause debug to not
-# work, but at least it compiles.
-AM_CFLAGS = $(ff_cflags) -fomit-frame-pointer
+$(top_builddir)/contrib/ffmpeg/libpostproc/libpostproc.a:
+ $(MAKE) -C $(top_builddir)/contrib ffmpeg/libpostproc/libpostproc.a
+$(top_builddir)/contrib/ffmpeg/libavutil/libavutil.a:
+ $(MAKE) -C $(top_builddir)/contrib ffmpeg/libavutil/libavutil.a
+endif
-# Avoid errors with -O0
-xineplug_post_planar_la-eq.o xineplug_post_planar_la-eq.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'`
-xineplug_post_planar_la-eq2.o xineplug_post_planar_la-eq2.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'`
-xineplug_post_planar_la-noise.o xineplug_post_planar_la-noise.lo: CFLAGS=`echo @CFLAGS@ | sed -e 's/-O0\?\s/-Os /g'`
+noinst_LTLIBRARIES = libpost_planar_asm.la
+libpost_planar_asm_la_SOURCES = eq.c eq2.c noise.c
+libpost_planar_asm_la_CFLAGS = $(O1_CFLAGS) -fomit-frame-pointer $(AM_CFLAGS)
xinepost_LTLIBRARIES = xineplug_post_planar.la
-
xineplug_post_planar_la_SOURCES = planar.c invert.c expand.c fill.c boxblur.c \
- denoise3d.c eq.c eq2.c unsharp.c pp.c noise.c
-xineplug_post_planar_la_DEPENDENCIES = $(postproc_dep)
-xineplug_post_planar_la_LIBADD = $(XINE_LIB) $(postproc_lib) -lm $(PTHREAD_LIBS) $(LTLIBINTL)
-xineplug_post_planar_la_LDFLAGS = -avoid-version -module \
- @IMPURE_TEXT_LDFLAGS@
-xineplug_post_planar_la_CFLAGS = $(VISIBILITY_FLAG) $(AM_CFLAGS)
-
-$(POSTPROC_INT_LIB):
- cd $(top_builddir)/src/libffmpeg/libavcodec/libpostproc && $(MAKE) libpostprocess.la
+ denoise3d.c unsharp.c pp.c
+xineplug_post_planar_la_LIBADD = $(XINE_LIB) $(postproc_lib) -lm $(PTHREAD_LIBS) $(LTLIBINTL) $(noinst_LTLIBRARIES)
+xineplug_post_planar_la_CFLAGS = $(DEFAULT_OCFLAGS) $(AM_CFLAGS)
+xineplug_post_planar_la_LDFLAGS = $(AM_LDFLAGS) $(xineplug_ldflags) $(IMPURE_TEXT_LDFLAGS)
diff --git a/src/post/planar/boxblur.c b/src/post/planar/boxblur.c
index edad304a6..b27e7e561 100644
--- a/src/post/planar/boxblur.c
+++ b/src/post/planar/boxblur.c
@@ -21,9 +21,9 @@
* Copyright (C) 2002 Michael Niedermayer <michaelni@gmx.at>
*/
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
#include <pthread.h>
/* plugin class initialization function */
@@ -120,9 +120,6 @@ static xine_post_api_t post_api = {
static post_plugin_t *boxblur_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *boxblur_get_identifier(post_class_t *class_gen);
-static char *boxblur_get_description(post_class_t *class_gen);
-static void boxblur_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void boxblur_dispose(post_plugin_t *this_gen);
@@ -136,15 +133,15 @@ static int boxblur_draw(vo_frame_t *frame, xine_stream_t *stream);
void *boxblur_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = boxblur_open_plugin;
- class->get_identifier = boxblur_get_identifier;
- class->get_description = boxblur_get_description;
- class->dispose = boxblur_class_dispose;
+ class->identifier = "boxblur";
+ class->description = N_("box blur filter from mplayer");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -194,22 +191,6 @@ static post_plugin_t *boxblur_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *boxblur_get_identifier(post_class_t *class_gen)
-{
- return "boxblur";
-}
-
-static char *boxblur_get_description(post_class_t *class_gen)
-{
- return "box blur filter from mplayer";
-}
-
-static void boxblur_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void boxblur_dispose(post_plugin_t *this_gen)
{
post_plugin_boxblur_t *this = (post_plugin_boxblur_t *)this_gen;
diff --git a/src/post/planar/denoise3d.c b/src/post/planar/denoise3d.c
index 74ed02250..cadaafae0 100644
--- a/src/post/planar/denoise3d.c
+++ b/src/post/planar/denoise3d.c
@@ -21,9 +21,9 @@
* Copyright (C) 2003 Daniel Moreno <comac@comac.darktech.org>
*/
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
#include <math.h>
#include <pthread.h>
@@ -157,9 +157,6 @@ static xine_post_api_t post_api = {
static post_plugin_t *denoise3d_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *denoise3d_get_identifier(post_class_t *class_gen);
-static char *denoise3d_get_description(post_class_t *class_gen);
-static void denoise3d_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void denoise3d_dispose(post_plugin_t *this_gen);
@@ -176,15 +173,15 @@ static int denoise3d_draw(vo_frame_t *frame, xine_stream_t *stream);
void *denoise3d_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = denoise3d_open_plugin;
- class->get_identifier = denoise3d_get_identifier;
- class->get_description = denoise3d_get_description;
- class->dispose = denoise3d_class_dispose;
+ class->identifier = "denoise3d";
+ class->description = N_("3D Denoiser (variable lowpass filter)");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -237,22 +234,6 @@ static post_plugin_t *denoise3d_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *denoise3d_get_identifier(post_class_t *class_gen)
-{
- return "denoise3d";
-}
-
-static char *denoise3d_get_description(post_class_t *class_gen)
-{
- return "3D Denoiser (variable lowpass filter)";
-}
-
-static void denoise3d_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void denoise3d_dispose(post_plugin_t *this_gen)
{
post_plugin_denoise3d_t *this = (post_plugin_denoise3d_t *)this_gen;
diff --git a/src/post/planar/eq.c b/src/post/planar/eq.c
index 92dae8e36..128616e6d 100644
--- a/src/post/planar/eq.c
+++ b/src/post/planar/eq.c
@@ -21,9 +21,9 @@
* Copyright (C) Richard Felker
*/
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
#include <pthread.h>
@@ -208,9 +208,6 @@ static xine_post_api_t post_api = {
static post_plugin_t *eq_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *eq_get_identifier(post_class_t *class_gen);
-static char *eq_get_description(post_class_t *class_gen);
-static void eq_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void eq_dispose(post_plugin_t *this_gen);
@@ -228,15 +225,15 @@ static int eq_draw(vo_frame_t *frame, xine_stream_t *stream);
void *eq_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = eq_open_plugin;
- class->get_identifier = eq_get_identifier;
- class->get_description = eq_get_description;
- class->dispose = eq_class_dispose;
+ class->identifier = "eq";
+ class->description = N_("soft video equalizer");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -292,22 +289,6 @@ static post_plugin_t *eq_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *eq_get_identifier(post_class_t *class_gen)
-{
- return "eq";
-}
-
-static char *eq_get_description(post_class_t *class_gen)
-{
- return "soft video equalizer";
-}
-
-static void eq_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void eq_dispose(post_plugin_t *this_gen)
{
post_plugin_eq_t *this = (post_plugin_eq_t *)this_gen;
diff --git a/src/post/planar/eq2.c b/src/post/planar/eq2.c
index 0ead54f55..c47270c2f 100644
--- a/src/post/planar/eq2.c
+++ b/src/post/planar/eq2.c
@@ -25,9 +25,9 @@
* Richard Felker (original MMX contrast/brightness code (vf_eq.c))
*/
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
#include <math.h>
#include <pthread.h>
@@ -389,9 +389,6 @@ static xine_post_api_t post_api = {
static post_plugin_t *eq2_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *eq2_get_identifier(post_class_t *class_gen);
-static char *eq2_get_description(post_class_t *class_gen);
-static void eq2_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void eq2_dispose(post_plugin_t *this_gen);
@@ -409,15 +406,15 @@ static int eq2_draw(vo_frame_t *frame, xine_stream_t *stream);
void *eq2_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = eq2_open_plugin;
- class->get_identifier = eq2_get_identifier;
- class->get_description = eq2_get_description;
- class->dispose = eq2_class_dispose;
+ class->identifier = "eq2";
+ class->description = N_("Software video equalizer");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -478,22 +475,6 @@ static post_plugin_t *eq2_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *eq2_get_identifier(post_class_t *class_gen)
-{
- return "eq2";
-}
-
-static char *eq2_get_description(post_class_t *class_gen)
-{
- return "Software video equalizer";
-}
-
-static void eq2_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void eq2_dispose(post_plugin_t *this_gen)
{
post_plugin_eq2_t *this = (post_plugin_eq2_t *)this_gen;
diff --git a/src/post/planar/expand.c b/src/post/planar/expand.c
index 52bc2b37a..3cecaf47d 100644
--- a/src/post/planar/expand.c
+++ b/src/post/planar/expand.c
@@ -27,8 +27,8 @@
*
*/
-#include "xine_internal.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
/* The expand trick explained:
*
@@ -100,9 +100,6 @@ typedef struct post_expand_s {
static post_plugin_t *expand_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *expand_get_identifier(post_class_t *class_gen);
-static char *expand_get_description(post_class_t *class_gen);
-static void expand_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void expand_dispose(post_plugin_t *this_gen);
@@ -130,15 +127,15 @@ static int32_t expand_overlay_add_event(video_overlay_manager_t *this_gen
void *expand_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = expand_open_plugin;
- class->get_identifier = expand_get_identifier;
- class->get_description = expand_get_description;
- class->dispose = expand_class_dispose;
+ class->identifier = "expand";
+ class->description = N_("add black borders to top and bottom of video to expand it to 4:3 aspect ratio");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -191,22 +188,6 @@ static post_plugin_t *expand_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *expand_get_identifier(post_class_t *class_gen)
-{
- return "expand";
-}
-
-static char *expand_get_description(post_class_t *class_gen)
-{
- return "add black borders to top and bottom of video to expand it to 4:3 aspect ratio";
-}
-
-static void expand_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void expand_dispose(post_plugin_t *this_gen)
{
post_expand_t *this = (post_expand_t *)this_gen;
diff --git a/src/post/planar/fill.c b/src/post/planar/fill.c
index 98c572777..5aacfd679 100644
--- a/src/post/planar/fill.c
+++ b/src/post/planar/fill.c
@@ -22,8 +22,8 @@
* based on invert.c
*/
-#include "xine_internal.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
/* plugin class initialization function */
void *fill_init_plugin(xine_t *xine, void *);
@@ -32,9 +32,6 @@ void *fill_init_plugin(xine_t *xine, void *);
static post_plugin_t *fill_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *fill_get_identifier(post_class_t *class_gen);
-static char *fill_get_description(post_class_t *class_gen);
-static void fill_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void fill_dispose(post_plugin_t *this_gen);
@@ -48,15 +45,15 @@ static int fill_draw(vo_frame_t *frame, xine_stream_t *stream);
void *fill_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = fill_open_plugin;
- class->get_identifier = fill_get_identifier;
- class->get_description = fill_get_description;
- class->dispose = fill_class_dispose;
+ class->identifier = "fill";
+ class->description = N_("crops left and right of video to fill 4:3 aspect ratio");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -92,21 +89,6 @@ static post_plugin_t *fill_open_plugin(post_class_t *class_gen, int inputs,
return this;
}
-static char *fill_get_identifier(post_class_t *class_gen)
-{
- return "fill";
-}
-
-static char *fill_get_description(post_class_t *class_gen)
-{
- return "crops left and right of video to fill 4:3 aspect ratio";
-}
-
-static void fill_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
static void fill_dispose(post_plugin_t *this)
{
if (_x_post_dispose(this))
diff --git a/src/post/planar/invert.c b/src/post/planar/invert.c
index d1f0c8d4e..17f237fd7 100644
--- a/src/post/planar/invert.c
+++ b/src/post/planar/invert.c
@@ -22,8 +22,8 @@
* simple video inverter plugin
*/
-#include "xine_internal.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
/* plugin class initialization function */
@@ -33,9 +33,6 @@ void *invert_init_plugin(xine_t *xine, void *);
static post_plugin_t *invert_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *invert_get_identifier(post_class_t *class_gen);
-static char *invert_get_description(post_class_t *class_gen);
-static void invert_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void invert_dispose(post_plugin_t *this_gen);
@@ -49,15 +46,15 @@ static int invert_draw(vo_frame_t *frame, xine_stream_t *stream);
void *invert_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = invert_open_plugin;
- class->get_identifier = invert_get_identifier;
- class->get_description = invert_get_description;
- class->dispose = invert_class_dispose;
+ class->identifier = "invert";
+ class->description = N_("inverts the colours of every video frame");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -91,22 +88,6 @@ static post_plugin_t *invert_open_plugin(post_class_t *class_gen, int inputs,
return this;
}
-static char *invert_get_identifier(post_class_t *class_gen)
-{
- return "invert";
-}
-
-static char *invert_get_description(post_class_t *class_gen)
-{
- return "inverts the colours of every video frame";
-}
-
-static void invert_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void invert_dispose(post_plugin_t *this)
{
if (_x_post_dispose(this))
diff --git a/src/post/planar/noise.c b/src/post/planar/noise.c
index e15c6fb4d..cba5004d0 100644
--- a/src/post/planar/noise.c
+++ b/src/post/planar/noise.c
@@ -21,9 +21,9 @@
* is copyright 2002 Michael Niedermayer <michaelni@gmx.at>
*/
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
#include <math.h>
#include <pthread.h>
@@ -318,8 +318,8 @@ typedef struct noise_parameters_s {
type, quality, pattern;
} noise_parameters_t;
-static char *enum_types[] = {"uniform", "gaussian", NULL};
-static char *enum_quality[] = {"fixed", "temporal", "averaged temporal", NULL};
+static const char *const enum_types[] = {"uniform", "gaussian", NULL};
+static const char *const enum_quality[] = {"fixed", "temporal", "averaged temporal", NULL};
/*
* description of params struct
@@ -429,9 +429,6 @@ static xine_post_api_t post_api = {
static post_plugin_t *noise_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *noise_get_identifier(post_class_t *class_gen);
-static char *noise_get_description(post_class_t *class_gen);
-static void noise_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void noise_dispose(post_plugin_t *this_gen);
@@ -445,15 +442,15 @@ static int noise_draw(vo_frame_t *frame, xine_stream_t *stream);
void *noise_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = noise_open_plugin;
- class->get_identifier = noise_get_identifier;
- class->get_description = noise_get_description;
- class->dispose = noise_class_dispose;
+ class->identifier = "noise";
+ class->description = N_("Adds noise");
+ class->dispose = default_post_class_dispose;
#ifdef ARCH_X86
if (xine_mm_accel() & MM_ACCEL_X86_MMX) {
@@ -515,22 +512,6 @@ static post_plugin_t *noise_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *noise_get_identifier(post_class_t *class_gen)
-{
- return "noise";
-}
-
-static char *noise_get_description(post_class_t *class_gen)
-{
- return "Adds noise";
-}
-
-static void noise_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void noise_dispose(post_plugin_t *this_gen)
{
post_plugin_noise_t *this = (post_plugin_noise_t *)this_gen;
diff --git a/src/post/planar/planar.c b/src/post/planar/planar.c
index 5907d58e5..1d0c59254 100644
--- a/src/post/planar/planar.c
+++ b/src/post/planar/planar.c
@@ -20,9 +20,9 @@
* catalog for planar post plugins
*/
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
extern void *invert_init_plugin(xine_t *xine, void *);
static const post_info_t invert_special_info = { XINE_POST_TYPE_VIDEO_FILTER };
@@ -56,15 +56,15 @@ static const post_info_t noise_special_info = { XINE_POST_TYPE_VIDEO_FILTER };
const plugin_info_t xine_plugin_info[] EXPORTED = {
/* type, API, "name", version, special_info, init_function */
- { PLUGIN_POST, 9, "expand", XINE_VERSION_CODE, &expand_special_info, &expand_init_plugin },
- { PLUGIN_POST, 9, "fill", XINE_VERSION_CODE, &fill_special_info, &fill_init_plugin },
- { PLUGIN_POST, 9, "invert", XINE_VERSION_CODE, &invert_special_info, &invert_init_plugin },
- { PLUGIN_POST, 9, "eq", XINE_VERSION_CODE, &eq_special_info, &eq_init_plugin },
- { PLUGIN_POST, 9, "denoise3d", XINE_VERSION_CODE, &denoise3d_special_info, &denoise3d_init_plugin },
- { PLUGIN_POST, 9, "boxblur", XINE_VERSION_CODE, &boxblur_special_info, &boxblur_init_plugin },
- { PLUGIN_POST, 9, "eq2", XINE_VERSION_CODE, &eq2_special_info, &eq2_init_plugin },
- { PLUGIN_POST, 9, "unsharp", XINE_VERSION_CODE, &unsharp_special_info, &unsharp_init_plugin },
- { PLUGIN_POST, 9, "pp", XINE_VERSION_CODE, &pp_special_info, &pp_init_plugin },
- { PLUGIN_POST, 9, "noise", XINE_VERSION_CODE, &noise_special_info, &noise_init_plugin },
+ { PLUGIN_POST, 10, "expand", XINE_VERSION_CODE, &expand_special_info, &expand_init_plugin },
+ { PLUGIN_POST, 10, "fill", XINE_VERSION_CODE, &fill_special_info, &fill_init_plugin },
+ { PLUGIN_POST, 10, "invert", XINE_VERSION_CODE, &invert_special_info, &invert_init_plugin },
+ { PLUGIN_POST, 10, "eq", XINE_VERSION_CODE, &eq_special_info, &eq_init_plugin },
+ { PLUGIN_POST, 10, "denoise3d", XINE_VERSION_CODE, &denoise3d_special_info, &denoise3d_init_plugin },
+ { PLUGIN_POST, 10, "boxblur", XINE_VERSION_CODE, &boxblur_special_info, &boxblur_init_plugin },
+ { PLUGIN_POST, 10, "eq2", XINE_VERSION_CODE, &eq2_special_info, &eq2_init_plugin },
+ { PLUGIN_POST, 10, "unsharp", XINE_VERSION_CODE, &unsharp_special_info, &unsharp_init_plugin },
+ { PLUGIN_POST, 10, "pp", XINE_VERSION_CODE, &pp_special_info, &pp_init_plugin },
+ { PLUGIN_POST, 10, "noise", XINE_VERSION_CODE, &noise_special_info, &noise_init_plugin },
{ PLUGIN_NONE, 0, "", 0, NULL, NULL }
};
diff --git a/src/post/planar/pp.c b/src/post/planar/pp.c
index 51d28b33d..ce163aacc 100644
--- a/src/post/planar/pp.c
+++ b/src/post/planar/pp.c
@@ -24,9 +24,11 @@
#include <config.h>
#endif
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
+#include <config.h>
+
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
#include <pthread.h>
#ifdef HAVE_FFMPEG_AVUTIL_H
@@ -111,21 +113,19 @@ static xine_post_api_descr_t * get_param_descr (void) {
}
static char * get_help (void) {
- char *help1 =
- _("FFmpeg libpostprocess plugin.\n"
- "\n"
- "Parameters\n"
- "\n");
-
- char *help2 =
- _("\n"
- "* libpostprocess (C) Michael Niedermayer\n"
- );
static char *help = NULL;
- if( !help )
- asprintf(&help, "%s%s%s", help1, help2, pp_help);
-
+ if( !help ) {
+ asprintf(&help, "%s%s%s",
+ _("FFmpeg libpostprocess plugin.\n"
+ "\n"
+ "Parameters\n"
+ "\n"),
+ pp_help,
+ _("\n"
+ "* libpostprocess (C) Michael Niedermayer\n")
+ );
+ }
return help;
}
@@ -141,9 +141,6 @@ static xine_post_api_t post_api = {
static post_plugin_t *pp_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *pp_get_identifier(post_class_t *class_gen);
-static char *pp_get_description(post_class_t *class_gen);
-static void pp_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void pp_dispose(post_plugin_t *this_gen);
@@ -157,15 +154,15 @@ static int pp_draw(vo_frame_t *frame, xine_stream_t *stream);
void *pp_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = pp_open_plugin;
- class->get_identifier = pp_get_identifier;
- class->get_description = pp_get_description;
- class->dispose = pp_class_dispose;
+ class->identifier = "pp";
+ class->description = N_("plugin for ffmpeg libpostprocess");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -227,22 +224,6 @@ static post_plugin_t *pp_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *pp_get_identifier(post_class_t *class_gen)
-{
- return "pp";
-}
-
-static char *pp_get_description(post_class_t *class_gen)
-{
- return "plugin for ffmpeg libpostprocess";
-}
-
-static void pp_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
-
static void pp_dispose(post_plugin_t *this_gen)
{
post_plugin_pp_t *this = (post_plugin_pp_t *)this_gen;
diff --git a/src/post/planar/unsharp.c b/src/post/planar/unsharp.c
index e61d80076..91ac6de82 100644
--- a/src/post/planar/unsharp.c
+++ b/src/post/planar/unsharp.c
@@ -21,9 +21,9 @@
* Copyright (C) 2002 Rémi Guyomarch <rguyom@pobox.com>
*/
-#include "xine_internal.h"
-#include "post.h"
-#include "xineutils.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
+#include <xine/xineutils.h>
#include <pthread.h>
#ifndef MIN
@@ -253,9 +253,6 @@ static xine_post_api_t post_api = {
static post_plugin_t *unsharp_open_plugin(post_class_t *class_gen, int inputs,
xine_audio_port_t **audio_target,
xine_video_port_t **video_target);
-static char *unsharp_get_identifier(post_class_t *class_gen);
-static char *unsharp_get_description(post_class_t *class_gen);
-static void unsharp_class_dispose(post_class_t *class_gen);
/* plugin instance functions */
static void unsharp_dispose(post_plugin_t *this_gen);
@@ -269,15 +266,15 @@ static int unsharp_draw(vo_frame_t *frame, xine_stream_t *stream);
void *unsharp_init_plugin(xine_t *xine, void *data)
{
- post_class_t *class = (post_class_t *)malloc(sizeof(post_class_t));
+ post_class_t *class = (post_class_t *)xine_xmalloc(sizeof(post_class_t));
if (!class)
return NULL;
class->open_plugin = unsharp_open_plugin;
- class->get_identifier = unsharp_get_identifier;
- class->get_description = unsharp_get_description;
- class->dispose = unsharp_class_dispose;
+ class->identifier = "unsharp";
+ class->description = N_("unsharp mask & gaussian blur");
+ class->dispose = default_post_class_dispose;
return class;
}
@@ -332,21 +329,6 @@ static post_plugin_t *unsharp_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *unsharp_get_identifier(post_class_t *class_gen)
-{
- return "unsharp";
-}
-
-static char *unsharp_get_description(post_class_t *class_gen)
-{
- return "unsharp mask & gaussian blur";
-}
-
-static void unsharp_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
static void unsharp_free_SC(post_plugin_unsharp_t *this)
{
int i;
diff --git a/src/post/visualizations/Makefile.am b/src/post/visualizations/Makefile.am
index f42598d9c..bea89ac49 100644
--- a/src/post/visualizations/Makefile.am
+++ b/src/post/visualizations/Makefile.am
@@ -1,13 +1,14 @@
include $(top_srcdir)/misc/Makefile.common
+AM_CFLAGS = $(DEFAULT_OCFLAGS) $(VISIBILITY_FLAG)
+AM_LDFLAGS = $(xineplug_ldflags)
+
EXTRA_DIST = fooviz.c
+noinst_HEADERS = fft.h visualizations.h
+
xinepost_LTLIBRARIES = xineplug_post_visualizations.la
xineplug_post_visualizations_la_SOURCES = \
visualizations.c fft.c fftscope.c oscope.c fftgraph.c
xineplug_post_visualizations_la_LIBADD = $(XINE_LIB) $(PTHREAD_LIBS) -lm
-xineplug_post_visualizations_la_CFLAGS = $(VISIBILITY_FLAG)
-xineplug_post_visualizations_la_LDFLAGS = -avoid-version -module
-
-noinst_HEADERS = fft.h visualizations.h
diff --git a/src/post/visualizations/fft.c b/src/post/visualizations/fft.c
index e9a99911a..01044987b 100644
--- a/src/post/visualizations/fft.c
+++ b/src/post/visualizations/fft.c
@@ -184,18 +184,6 @@ double fft_amp (int n, complex_t wave[], int bits)
}
/*
- * Calculate phase of component n in the decimated wave[] array.
- */
-double fft_phase (int n, complex_t wave[], int bits)
-{
- n = PERMUTE (n, bits);
- if (REAL(n) != 0.0)
- return (atan (IMAG(n) / REAL(n)));
- else
- return (0.0);
-}
-
-/*
* Scale sampled values.
* Do this *before* the fft.
*/
diff --git a/src/post/visualizations/fft.h b/src/post/visualizations/fft.h
index dff3cd7e8..1600430bc 100644
--- a/src/post/visualizations/fft.h
+++ b/src/post/visualizations/fft.h
@@ -44,7 +44,6 @@ void fft_compute (fft_t *fft, complex_t wave[]);
void fft_window (fft_t *fft, complex_t wave[]);
double fft_amp (int n, complex_t wave[], int bits);
-double fft_phase (int n, complex_t wave[], int bits);
void fft_scale (complex_t wave[], int bits);
#endif /* FFT_H */
diff --git a/src/post/visualizations/fftgraph.c b/src/post/visualizations/fftgraph.c
index 0cf27faf8..b881b9bec 100644
--- a/src/post/visualizations/fftgraph.c
+++ b/src/post/visualizations/fftgraph.c
@@ -26,9 +26,9 @@
#include <assert.h>
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "bswap.h"
#include "visualizations.h"
#include "fft.h"
@@ -452,33 +452,18 @@ static post_plugin_t *fftgraph_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *fftgraph_get_identifier(post_class_t *class_gen)
-{
- return "fftgraph";
-}
-
-static char *fftgraph_get_description(post_class_t *class_gen)
-{
- return "fftgraph Visualization Post Plugin";
-}
-
-static void fftgraph_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
/* plugin class initialization function */
void *fftgraph_init_plugin(xine_t *xine, void *data)
{
- post_class_fftgraph_t *class = (post_class_fftgraph_t *)malloc(sizeof(post_class_fftgraph_t));
+ post_class_fftgraph_t *class = (post_class_fftgraph_t *)xine_xmalloc(sizeof(post_class_fftgraph_t));
if (!class)
return NULL;
class->post_class.open_plugin = fftgraph_open_plugin;
- class->post_class.get_identifier = fftgraph_get_identifier;
- class->post_class.get_description = fftgraph_get_description;
- class->post_class.dispose = fftgraph_class_dispose;
+ class->post_class.identifier = "fftgraph";
+ class->post_class.description = N_("fftgraph Visualization Post Plugin");
+ class->post_class.dispose = default_post_class_dispose;
class->xine = xine;
diff --git a/src/post/visualizations/fftscope.c b/src/post/visualizations/fftscope.c
index 2c6297a44..eca2e2f93 100644
--- a/src/post/visualizations/fftscope.c
+++ b/src/post/visualizations/fftscope.c
@@ -26,9 +26,9 @@
#include <stdio.h>
#include <math.h>
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "bswap.h"
#include "visualizations.h"
#include "fft.h"
@@ -473,33 +473,18 @@ static post_plugin_t *fftscope_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *fftscope_get_identifier(post_class_t *class_gen)
-{
- return "FFT Scope";
-}
-
-static char *fftscope_get_description(post_class_t *class_gen)
-{
- return "FFT Scope";
-}
-
-static void fftscope_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
/* plugin class initialization function */
void *fftscope_init_plugin(xine_t *xine, void *data)
{
- post_class_fftscope_t *class = (post_class_fftscope_t *)malloc(sizeof(post_class_fftscope_t));
+ post_class_fftscope_t *class = (post_class_fftscope_t *)xine_xmalloc(sizeof(post_class_fftscope_t));
if (!class)
return NULL;
class->post_class.open_plugin = fftscope_open_plugin;
- class->post_class.get_identifier = fftscope_get_identifier;
- class->post_class.get_description = fftscope_get_description;
- class->post_class.dispose = fftscope_class_dispose;
+ class->post_class.identifier = "FFT Scope";
+ class->post_class.description = N_("FFT Scope");
+ class->post_class.dispose = default_post_class_dispose;
class->xine = xine;
diff --git a/src/post/visualizations/fooviz.c b/src/post/visualizations/fooviz.c
index 2219143be..722ae9f7c 100644
--- a/src/post/visualizations/fooviz.c
+++ b/src/post/visualizations/fooviz.c
@@ -26,9 +26,9 @@
#include <stdio.h>
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#define FPS 20
@@ -284,33 +284,18 @@ static post_plugin_t *fooviz_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *fooviz_get_identifier(post_class_t *class_gen)
-{
- return "fooviz";
-}
-
-static char *fooviz_get_description(post_class_t *class_gen)
-{
- return "fooviz";
-}
-
-static void fooviz_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
/* plugin class initialization function */
static void *fooviz_init_plugin(xine_t *xine, void *data)
{
- post_class_fooviz_t *class = (post_class_fooviz_t *)malloc(sizeof(post_class_fooviz_t));
+ post_class_fooviz_t *class = (post_class_fooviz_t *)xine_xmalloc(sizeof(post_class_fooviz_t));
if (!class)
return NULL;
class->post_class.open_plugin = fooviz_open_plugin;
- class->post_class.get_identifier = fooviz_get_identifier;
- class->post_class.get_description = fooviz_get_description;
- class->post_class.dispose = fooviz_class_dispose;
+ class->post_class.identifier = "fooviz";
+ class->post_class.description = N_("fooviz");
+ class->post_class.dispose = default_post_class_dispose;
class->xine = xine;
@@ -322,6 +307,6 @@ static const post_info_t fooviz_special_info = { XINE_POST_TYPE_AUDIO_VISUALIZAT
const plugin_info_t xine_plugin_info[] EXPORTED = {
/* type, API, "name", version, special_info, init_function */
- { PLUGIN_POST, 9, "fooviz", XINE_VERSION_CODE, &fooviz_special_info, &fooviz_init_plugin },
+ { PLUGIN_POST, 10, "fooviz", XINE_VERSION_CODE, &fooviz_special_info, &fooviz_init_plugin },
{ PLUGIN_NONE, 0, "", 0, NULL, NULL }
};
diff --git a/src/post/visualizations/oscope.c b/src/post/visualizations/oscope.c
index 099920b42..3e783cce7 100644
--- a/src/post/visualizations/oscope.c
+++ b/src/post/visualizations/oscope.c
@@ -23,9 +23,9 @@
#include <stdio.h>
-#include "xine_internal.h"
-#include "xineutils.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/xineutils.h>
+#include <xine/post.h>
#include "visualizations.h"
#define FPS 20
@@ -355,33 +355,18 @@ static post_plugin_t *oscope_open_plugin(post_class_t *class_gen, int inputs,
return &this->post;
}
-static char *oscope_get_identifier(post_class_t *class_gen)
-{
- return "Oscilloscope";
-}
-
-static char *oscope_get_description(post_class_t *class_gen)
-{
- return "Oscilloscope";
-}
-
-static void oscope_class_dispose(post_class_t *class_gen)
-{
- free(class_gen);
-}
-
/* plugin class initialization function */
void *oscope_init_plugin(xine_t *xine, void *data)
{
- post_class_oscope_t *class = (post_class_oscope_t *)malloc(sizeof(post_class_oscope_t));
+ post_class_oscope_t *class = (post_class_oscope_t *)xine_xmalloc(sizeof(post_class_oscope_t));
if (!class)
return NULL;
class->post_class.open_plugin = oscope_open_plugin;
- class->post_class.get_identifier = oscope_get_identifier;
- class->post_class.get_description = oscope_get_description;
- class->post_class.dispose = oscope_class_dispose;
+ class->post_class.identifier = "Oscilloscope";
+ class->post_class.description = N_("Oscilloscope");
+ class->post_class.dispose = default_post_class_dispose;
class->xine = xine;
diff --git a/src/post/visualizations/visualizations.c b/src/post/visualizations/visualizations.c
index a26f0bd5b..17c8491d5 100644
--- a/src/post/visualizations/visualizations.c
+++ b/src/post/visualizations/visualizations.c
@@ -24,8 +24,8 @@
#include "config.h"
#endif
-#include "xine_internal.h"
-#include "post.h"
+#include <xine/xine_internal.h>
+#include <xine/post.h>
#include "visualizations.h"
@@ -46,8 +46,8 @@ static const post_info_t fftgraph_special_info = { XINE_POST_TYPE_AUDIO_VISUALIZ
const plugin_info_t xine_plugin_info[] EXPORTED = {
/* type, API, "name", version, special_info, init_function */
- { PLUGIN_POST, 9, "oscope", XINE_VERSION_CODE, &oscope_special_info, &oscope_init_plugin },
- { PLUGIN_POST, 9, "fftscope", XINE_VERSION_CODE, &fftscope_special_info, &fftscope_init_plugin },
- { PLUGIN_POST, 9, "fftgraph", XINE_VERSION_CODE, &fftgraph_special_info, &fftgraph_init_plugin },
+ { PLUGIN_POST, 10, "oscope", XINE_VERSION_CODE, &oscope_special_info, &oscope_init_plugin },
+ { PLUGIN_POST, 10, "fftscope", XINE_VERSION_CODE, &fftscope_special_info, &fftscope_init_plugin },
+ { PLUGIN_POST, 10, "fftgraph", XINE_VERSION_CODE, &fftgraph_special_info, &fftgraph_init_plugin },
{ PLUGIN_NONE, 0, "", 0, NULL, NULL }
};
diff --git a/src/post/visualizations/visualizations.h b/src/post/visualizations/visualizations.h
index 39d02e1cb..c72a1ad77 100644
--- a/src/post/visualizations/visualizations.h
+++ b/src/post/visualizations/visualizations.h
@@ -20,7 +20,7 @@
* This file contains plugin entries for several visualization post plugins.
*/
-#include "xine_internal.h"
+#include <xine/xine_internal.h>
void *oscope_init_plugin(xine_t *xine, void *data);
void *fftscope_init_plugin(xine_t *xine, void *data);