From 763595a925b6a5f75e9821654f28e28683cf5960 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Sun, 23 Dec 2007 16:49:52 +0100 Subject: Remove XINE_COMPILE conditional. --- include/xine/plugin_catalog.h | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'include') diff --git a/include/xine/plugin_catalog.h b/include/xine/plugin_catalog.h index fd9afb959..1c2d5e806 100644 --- a/include/xine/plugin_catalog.h +++ b/include/xine/plugin_catalog.h @@ -23,13 +23,8 @@ #ifndef _PLUGIN_CATALOG_H #define _PLUGIN_CATALOG_H -#ifdef XINE_COMPILE -# include "xine_plugin.h" -# include "xineutils.h" -#else -# include -# include -#endif +#include +#include #define DECODER_MAX 128 #define PLUGIN_MAX 256 -- cgit v1.2.3 From bc8c21fd7f45233fe6501e4e9a21b33a0c498248 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Sun, 23 Dec 2007 17:03:04 +0100 Subject: Make supported_types constant, change plugins' loading code so that it actually load them properly. --- include/xine/xine_plugin.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/xine/xine_plugin.h b/include/xine/xine_plugin.h index 74e7523e9..11ccc5e11 100644 --- a/include/xine/xine_plugin.h +++ b/include/xine/xine_plugin.h @@ -70,7 +70,7 @@ typedef struct { /* special_info for a decoder plugin */ typedef struct { - uint32_t *supported_types; /* streamtypes this decoder can handle */ + const uint32_t *supported_types; /* streamtypes this decoder can handle */ int priority; } decoder_info_t; -- cgit v1.2.3 From 476a3e5b3151a4b626d086e65d53d6f5eea914db Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Sun, 23 Dec 2007 18:44:08 +0100 Subject: Move os_types.h together with the other includes. --HG-- rename : lib/os_types.h => include/xine/os_types.h --- include/xine/Makefile.am | 2 +- include/xine/os_types.h | 109 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 110 insertions(+), 1 deletion(-) create mode 100644 include/xine/os_types.h (limited to 'include') diff --git a/include/xine/Makefile.am b/include/xine/Makefile.am index 2861460be..8c86f3e2a 100644 --- a/include/xine/Makefile.am +++ b/include/xine/Makefile.am @@ -8,4 +8,4 @@ xineinclude_HEADERS = version.h buffer.h metronom.h configfile.h vo_scale.h \ io_helper.h broadcaster.h info_helper.h refcounter.h alphablend.h \ demux.h input_plugin.h attributes.h compat.h xine_buffer.h \ xineutils.h xmllexer.h xmlparser.h list.h array.h sorted_array.h \ - pool.h ring_buffer.h + pool.h ring_buffer.h os_types.h diff --git a/include/xine/os_types.h b/include/xine/os_types.h new file mode 100644 index 000000000..75ce9b8a5 --- /dev/null +++ b/include/xine/os_types.h @@ -0,0 +1,109 @@ +/* + * Copyright (C) 2004-2006 the xine project + * + * This file is part of xine, a free video player. + * + * xine is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * xine 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA + * + * Platform dependent types needed by public xine.h. + * Types not needed by xine.h are specified in os_internal.h. + * + * Heavily based on os_types.h from OggVorbis (BSD License), + * not tested on all platforms with xine. + */ + +#ifndef XINE_OS_TYPES_H +#define XINE_OS_TYPES_H + +#if defined(_WIN32) && !defined(__GNUC__) + + /* MSVC/Borland */ + typedef __int8 int8_t; + typedef unsigned __int8 uint8_t; + typedef __int16 int16_t; + typedef unsigned __int16 uint16_t; + typedef __int32 int32_t; + typedef unsigned __int32 uint32_t; + typedef __int64 int64_t; + typedef unsigned __int64 uint64_t; + +#elif defined(__MACOS__) + +# include + typedef SInt8 int8_t; + typedef UInt8 uint8_t; + typedef SInt16 int16_t; + typedef UInt16 uint16_t; + typedef SInt32 int32_t; + typedef UInt32 uint32_t; + typedef SInt64 int64_t; + typedef UInt64 uint64_t; + +#elif defined(__MACOSX__) /* MacOS X Framework build */ + +# include + typedef u_int8_t uint8_t; + typedef u_int16_t uint16_t; + typedef u_int32_t uint32_t; + typedef u_int64_t uint64_t; + +#elif defined (__EMX__) + + /* OS/2 GCC */ + typedef signed char int8_t; + typedef unsigned char uint8_t; + typedef short int16_t; + typedef unsigned short uint16_t; + typedef int int32_t; + typedef unsigned int uint32_t; + typedef long long int64_t; + typedef unsigned long long int64_t; + +#elif defined (DJGPP) + + /* DJGPP */ + typedef signed char int8_t; + typedef unsigned char uint8_t; + typedef short int16_t; + typedef unsigned short uint16_t; + typedef int int32_t; + typedef unsigned int uint32_t; + typedef long long int64_t; + typedef unsigned long long uint64_t; + +#elif defined(R5900) + + /* PS2 EE */ + typedef signed char int8_t; + typedef unsigned char uint8_t; + typedef short int16_t; + typedef unsigned short int16_t; + typedef int int32_t; + typedef unsigned uint32_t; + typedef long int64_t; + typedef unsigned long int64_t; + +#else + + /* + * CygWin: _WIN32 & __GNUC__ + * BeOS: __BEOS__ + * Linux, Solaris, Mac and others + */ +# include + +#endif + +#endif /* XINE_OS_TYPES_H */ -- cgit v1.2.3 From a3ded7d74f5e8bb08f4fc25ff75ca6b534c633dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Sun, 23 Dec 2007 18:44:29 +0100 Subject: Remove XINE_COMPILE conditionals where they just changed the include directive paths. --- include/xine.h | 5 ----- include/xine/audio_decoder.h | 9 ++------- include/xine/audio_out.h | 8 -------- include/xine/buffer.h | 9 ++------- include/xine/configfile.h | 6 +----- include/xine/input_plugin.h | 15 ++++----------- include/xine/metronom.h | 9 ++------- include/xine/osd.h | 6 +----- include/xine/post.h | 18 +++++------------- include/xine/spu_decoder.h | 9 ++------- include/xine/video_decoder.h | 9 ++------- include/xine/video_out.h | 9 ++------- include/xine/video_overlay.h | 6 +----- include/xine/vo_scale.h | 6 +----- include/xine/xine_buffer.h | 6 +----- include/xine/xineutils.h | 36 ++++++++++++------------------------ 16 files changed, 38 insertions(+), 128 deletions(-) (limited to 'include') diff --git a/include/xine.h b/include/xine.h index da1d394a3..1d26daa19 100644 --- a/include/xine.h +++ b/include/xine.h @@ -55,12 +55,7 @@ extern "C" { #include #endif -#ifdef XINE_COMPILE -#include -#else #include -#endif - #include #include diff --git a/include/xine/audio_decoder.h b/include/xine/audio_decoder.h index 307692b81..7e3107727 100644 --- a/include/xine/audio_decoder.h +++ b/include/xine/audio_decoder.h @@ -23,13 +23,8 @@ #ifndef HAVE_AUDIO_DECODER_H #define HAVE_AUDIO_DECODER_H -#ifdef XINE_COMPILE -# include -# include "buffer.h" -#else -# include -# include -#endif +#include +#include #define AUDIO_DECODER_IFACE_VERSION 16 diff --git a/include/xine/audio_out.h b/include/xine/audio_out.h index bd1b910df..8f73bbbf7 100644 --- a/include/xine/audio_out.h +++ b/include/xine/audio_out.h @@ -24,18 +24,10 @@ extern "C" { #endif -#if defined(XINE_COMPILE) -#include -#include "metronom.h" -#include "configfile.h" -#include "xineutils.h" -#else #include #include #include #include -#endif - #define AUDIO_OUT_IFACE_VERSION 9 diff --git a/include/xine/buffer.h b/include/xine/buffer.h index ce209c9da..4af718a1b 100644 --- a/include/xine/buffer.h +++ b/include/xine/buffer.h @@ -43,13 +43,8 @@ extern "C" { #include #include -#ifdef XINE_COMPILE -# include -# include "attributes.h" -#else -# include -# include -#endif +#include +#include #define BUF_MAX_CALLBACKS 5 diff --git a/include/xine/configfile.h b/include/xine/configfile.h index 22a544c00..724a75245 100644 --- a/include/xine/configfile.h +++ b/include/xine/configfile.h @@ -29,11 +29,7 @@ extern "C" { #include -#ifdef XINE_COMPILE -# include "xine.h" -#else -# include -#endif +#include #define CONFIG_FILE_VERSION 2 diff --git a/include/xine/input_plugin.h b/include/xine/input_plugin.h index 2917721c9..aa0e2bf47 100644 --- a/include/xine/input_plugin.h +++ b/include/xine/input_plugin.h @@ -23,17 +23,10 @@ #include -#ifdef XINE_COMPILE -# include -# include "xineutils.h" -# include "buffer.h" -# include "configfile.h" -#else -# include -# include -# include -# include -#endif +#include +#include +#include +#include #define INPUT_PLUGIN_IFACE_VERSION 18 diff --git a/include/xine/metronom.h b/include/xine/metronom.h index 77919f16e..df08a0058 100644 --- a/include/xine/metronom.h +++ b/include/xine/metronom.h @@ -46,13 +46,8 @@ extern "C" { #include -#ifdef XINE_COMPILE -# include "video_out.h" -# include "xine.h" -#else -# include -# include -#endif +#include +#include typedef struct metronom_s metronom_t ; typedef struct metronom_clock_s metronom_clock_t; diff --git a/include/xine/osd.h b/include/xine/osd.h index ed4e2434b..4e34030ee 100644 --- a/include/xine/osd.h +++ b/include/xine/osd.h @@ -27,11 +27,7 @@ # include #endif -#ifdef XINE_COMPILE -# include "video_overlay.h" -#else -# include -#endif +#include typedef struct osd_object_s osd_object_t; typedef struct osd_renderer_s osd_renderer_t; diff --git a/include/xine/post.h b/include/xine/post.h index 1995ca82f..4f2b8d272 100644 --- a/include/xine/post.h +++ b/include/xine/post.h @@ -23,19 +23,11 @@ #ifndef XINE_POST_H #define XINE_POST_H -#ifdef XINE_COMPILE -# include "xine.h" -# include "video_out.h" -# include "audio_out.h" -# include "xine_internal.h" -# include "xineutils.h" -#else -# include -# include -# include -# include -# include -#endif +#include +#include +#include +#include +#include #define POST_PLUGIN_IFACE_VERSION 9 diff --git a/include/xine/spu_decoder.h b/include/xine/spu_decoder.h index dcf9107f7..b11bf7952 100644 --- a/include/xine/spu_decoder.h +++ b/include/xine/spu_decoder.h @@ -24,13 +24,8 @@ #ifndef HAVE_SPU_API_H #define HAVE_SPU_API_H -#ifdef XINE_COMPILE -# include -# include "buffer.h" -#else -# include -# include -#endif +#include +#include #define SPU_DECODER_IFACE_VERSION 17 diff --git a/include/xine/video_decoder.h b/include/xine/video_decoder.h index 705efa3da..ec0855277 100644 --- a/include/xine/video_decoder.h +++ b/include/xine/video_decoder.h @@ -23,13 +23,8 @@ #ifndef HAVE_VIDEO_DECODER_H #define HAVE_VIDEO_DECODER_H -#ifdef XINE_COMPILE -# include -# include "buffer.h" -#else -# include -# include -#endif +#include +#include #define VIDEO_DECODER_IFACE_VERSION 19 diff --git a/include/xine/video_out.h b/include/xine/video_out.h index 8efdae9f6..83d6986bb 100644 --- a/include/xine/video_out.h +++ b/include/xine/video_out.h @@ -42,13 +42,8 @@ extern "C" { #include -#ifdef XINE_COMPILE -# include "xine.h" -# include "buffer.h" -#else -# include -# include -#endif +#include +#include typedef struct vo_frame_s vo_frame_t; diff --git a/include/xine/video_overlay.h b/include/xine/video_overlay.h index 6bb529204..b45f5149e 100644 --- a/include/xine/video_overlay.h +++ b/include/xine/video_overlay.h @@ -21,11 +21,7 @@ #ifndef HAVE_VIDEO_OVERLAY_H #define HAVE_VIDEO_OVERLAY_H -#ifdef XINE_COMPILE -# include "xine_internal.h" -#else -# include -#endif +#include #ifdef __GNUC__ #define CLUT_Y_CR_CB_INIT(_y,_cr,_cb) {y: (_y), cr: (_cr), cb: (_cb)} diff --git a/include/xine/vo_scale.h b/include/xine/vo_scale.h index e502b2f62..b8b1a535b 100644 --- a/include/xine/vo_scale.h +++ b/include/xine/vo_scale.h @@ -33,11 +33,7 @@ extern "C" { #include "config.h" #endif -#ifdef XINE_COMPILE -# include "configfile.h" -#else -# include -#endif +#include typedef struct { int x, y; diff --git a/include/xine/xine_buffer.h b/include/xine/xine_buffer.h index 84511bd1b..73699a2d2 100644 --- a/include/xine/xine_buffer.h +++ b/include/xine/xine_buffer.h @@ -50,11 +50,7 @@ #ifndef HAVE_XINE_BUFFER_H #define HAVE_XINE_BUFFER_H -#ifdef XINE_COMPILE -# include -#else -# include -#endif +#include /* * returns an initialized pointer to a buffer. diff --git a/include/xine/xineutils.h b/include/xine/xineutils.h index 89c62676b..5f052ee58 100644 --- a/include/xine/xineutils.h +++ b/include/xine/xineutils.h @@ -33,32 +33,20 @@ extern "C" { #include #include -#ifdef XINE_COMPILE -# include -# include "attributes.h" -# include "compat.h" -# include "xmlparser.h" -# include "xine_buffer.h" -# include "configfile.h" -# include "list.h" -# include "array.h" -# include "sorted_array.h" +#ifdef WIN32 +# include #else -# ifdef WIN32 -# include -# else -# include -# endif -# include -# include -# include -# include -# include -# include -# include -# include -# include +# include #endif +#include +#include +#include +#include +#include +#include +#include +#include +#include #include #include -- cgit v1.2.3 From 057be3a11b092f1a1333e62945060cbb5c7ee59e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Sun, 23 Dec 2007 18:54:49 +0100 Subject: Make the node pointer transparent during xine build. Check XINE_COMPILE definition, if it's present, define node as a plugin_node_t pointer rather than a void pointer. --- include/xine/audio_decoder.h | 17 +++++++++++++++-- include/xine/audio_out.h | 14 ++++++++++++++ include/xine/demux.h | 17 +++++++++++++++-- include/xine/input_plugin.h | 16 +++++++++++++++- include/xine/post.h | 17 +++++++++++++++-- include/xine/spu_decoder.h | 16 +++++++++++++++- include/xine/video_decoder.h | 18 +++++++++++++++--- include/xine/video_out.h | 15 ++++++++++++++- 8 files changed, 118 insertions(+), 12 deletions(-) (limited to 'include') diff --git a/include/xine/audio_decoder.h b/include/xine/audio_decoder.h index 7e3107727..49194e290 100644 --- a/include/xine/audio_decoder.h +++ b/include/xine/audio_decoder.h @@ -26,6 +26,10 @@ #include #include +#ifdef XINE_COMPILE +# include +#endif + #define AUDIO_DECODER_IFACE_VERSION 16 /* @@ -93,8 +97,17 @@ struct audio_decoder_s { */ void (*dispose) (audio_decoder_t *this); - void *node; /* used by plugin loader */ - + /** + * @brief Pointer to the loaded plugin node. + * + * Used by the plugins loader. It's an opaque type when using the + * structure outside of xine's build. + */ +#ifdef XINE_COMPILE + plugin_node_t *node; +#else + void *node; +#endif }; #endif diff --git a/include/xine/audio_out.h b/include/xine/audio_out.h index 8f73bbbf7..b720110bf 100644 --- a/include/xine/audio_out.h +++ b/include/xine/audio_out.h @@ -29,6 +29,10 @@ extern "C" { #include #include +#ifdef XINE_COMPILE +# include +#endif + #define AUDIO_OUT_IFACE_VERSION 9 /* @@ -118,7 +122,17 @@ struct ao_driver_s { */ int (*control) (ao_driver_t *, int cmd, /* arg */ ...); + /** + * @brief Pointer to the loaded plugin node. + * + * Used by the plugins loader. It's an opaque type when using the + * structure outside of xine's build. + */ +#ifdef XINE_COMPILE + plugin_node_t *node; +#else void *node; +#endif }; typedef struct ao_format_s ao_format_t; diff --git a/include/xine/demux.h b/include/xine/demux.h index 476c80b8e..35a5c9a82 100644 --- a/include/xine/demux.h +++ b/include/xine/demux.h @@ -25,6 +25,10 @@ #include #include +#ifdef XINE_COMPILE +# include +#endif + #define DEMUXER_PLUGIN_IFACE_VERSION 27 #define DEMUX_OK 0 @@ -169,8 +173,17 @@ struct demux_plugin_s { demux_class_t *demux_class; - void *node; /* used by plugin loader */ - + /** + * @brief Pointer to the loaded plugin node. + * + * Used by the plugins loader. It's an opaque type when using the + * structure outside of xine's build. + */ +#ifdef XINE_COMPILE + plugin_node_t *node; +#else + void *node; +#endif } ; #define default_demux_plugin_dispose (void (*) (demux_plugin_t *this))free diff --git a/include/xine/input_plugin.h b/include/xine/input_plugin.h index aa0e2bf47..e434dc5a8 100644 --- a/include/xine/input_plugin.h +++ b/include/xine/input_plugin.h @@ -28,6 +28,10 @@ #include #include +#ifdef XINE_COMPILE +# include +#endif + #define INPUT_PLUGIN_IFACE_VERSION 18 typedef struct input_class_s input_class_t ; @@ -221,7 +225,17 @@ struct input_plugin_s { input_class_t *input_class; - void *node; /* used by plugin loader */ + /** + * @brief Pointer to the loaded plugin node. + * + * Used by the plugins loader. It's an opaque type when using the + * structure outside of xine's build. + */ +#ifdef XINE_COMPILE + plugin_node_t *node; +#else + void *node; +#endif }; diff --git a/include/xine/post.h b/include/xine/post.h index 4f2b8d272..3056f8120 100644 --- a/include/xine/post.h +++ b/include/xine/post.h @@ -29,6 +29,10 @@ #include #include +#ifdef XINE_COMPILE +# include +#endif + #define POST_PLUGIN_IFACE_VERSION 9 @@ -111,8 +115,17 @@ struct post_plugin_s { const char **input_ids; const char **output_ids; - /* used by plugin loader */ - void *node; + /** + * @brief Pointer to the loaded plugin node. + * + * Used by the plugins loader. It's an opaque type when using the + * structure outside of xine's build. + */ +#ifdef XINE_COMPILE + plugin_node_t *node; +#else + void *node; +#endif /* has dispose been called */ int dispose_pending; diff --git a/include/xine/spu_decoder.h b/include/xine/spu_decoder.h index b11bf7952..d36b5b691 100644 --- a/include/xine/spu_decoder.h +++ b/include/xine/spu_decoder.h @@ -27,6 +27,10 @@ #include #include +#ifdef XINE_COMPILE +# include +#endif + #define SPU_DECODER_IFACE_VERSION 17 /* @@ -113,7 +117,17 @@ struct spu_decoder_s { */ void (*set_button) (spu_decoder_t *this_gen, int32_t button, int32_t mode); - void *node; /* used by plugin loader */ + /** + * @brief Pointer to the loaded plugin node. + * + * Used by the plugins loader. It's an opaque type when using the + * structure outside of xine's build. + */ +#ifdef XINE_COMPILE + plugin_node_t *node; +#else + void *node; +#endif }; diff --git a/include/xine/video_decoder.h b/include/xine/video_decoder.h index ec0855277..916cfe68b 100644 --- a/include/xine/video_decoder.h +++ b/include/xine/video_decoder.h @@ -26,6 +26,10 @@ #include #include +#ifdef XINE_COMPILE +# include +#endif + #define VIDEO_DECODER_IFACE_VERSION 19 @@ -98,9 +102,17 @@ struct video_decoder_s { */ void (*dispose) (video_decoder_t *this); - - void *node; /*used by plugin loader */ - + /** + * @brief Pointer to the loaded plugin node. + * + * Used by the plugins loader. It's an opaque type when using the + * structure outside of xine's build. + */ +#ifdef XINE_COMPILE + plugin_node_t *node; +#else + void *node; +#endif }; #endif diff --git a/include/xine/video_out.h b/include/xine/video_out.h index 83d6986bb..c7432e1fc 100644 --- a/include/xine/video_out.h +++ b/include/xine/video_out.h @@ -45,6 +45,9 @@ extern "C" { #include #include +#ifdef XINE_COMPILE +# include +#endif typedef struct vo_frame_s vo_frame_t; typedef struct vo_driver_s vo_driver_t; @@ -354,7 +357,17 @@ struct vo_driver_s { */ void (*dispose) (vo_driver_t *self); - void *node; /* needed by plugin_loader */ + /** + * @brief Pointer to the loaded plugin node. + * + * Used by the plugins loader. It's an opaque type when using the + * structure outside of xine's build. + */ +#ifdef XINE_COMPILE + plugin_node_t *node; +#else + void *node; +#endif }; struct video_driver_class_s { -- cgit v1.2.3 From 0e5934002fd660a25d844d0f11fa7d2e53a10297 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Mon, 24 Dec 2007 15:24:15 +0100 Subject: Move _x_scan_plugins and _x_dispose_plugins into an internal header, and don't export them anymore. --- include/xine/plugin_catalog.h | 16 ---------------- 1 file changed, 16 deletions(-) (limited to 'include') diff --git a/include/xine/plugin_catalog.h b/include/xine/plugin_catalog.h index 1c2d5e806..be02c3649 100644 --- a/include/xine/plugin_catalog.h +++ b/include/xine/plugin_catalog.h @@ -71,20 +71,4 @@ struct plugin_catalog_s { }; typedef struct plugin_catalog_s plugin_catalog_t; -/* - * load plugins into catalog - * - * all input+demux plugins will be fully loaded+initialized - * decoder plugins are loaded on demand - * video/audio output plugins have special load/probe functions - */ -void _x_scan_plugins (xine_t *this) XINE_PROTECTED; - - -/* - * dispose all currently loaded plugins (shutdown) - */ - -void _x_dispose_plugins (xine_t *this) XINE_PROTECTED; - #endif -- cgit v1.2.3 From c994a0bcf1e379afeb06293218d3946faf94c8f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reinhard=20Ni=C3=9Fl?= Date: Mon, 31 Dec 2007 11:09:53 +0100 Subject: Fix installation of input_vdr.h by moving it to include/xine. Recent repository changes broke installation of input_vdr.h. --HG-- rename : src/vdr/input_vdr.h => include/xine/input_vdr.h --- include/xine/Makefile.am | 2 +- include/xine/input_vdr.h | 616 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 617 insertions(+), 1 deletion(-) create mode 100644 include/xine/input_vdr.h (limited to 'include') diff --git a/include/xine/Makefile.am b/include/xine/Makefile.am index 8c86f3e2a..cad6adb31 100644 --- a/include/xine/Makefile.am +++ b/include/xine/Makefile.am @@ -8,4 +8,4 @@ xineinclude_HEADERS = version.h buffer.h metronom.h configfile.h vo_scale.h \ io_helper.h broadcaster.h info_helper.h refcounter.h alphablend.h \ demux.h input_plugin.h attributes.h compat.h xine_buffer.h \ xineutils.h xmllexer.h xmlparser.h list.h array.h sorted_array.h \ - pool.h ring_buffer.h os_types.h + pool.h ring_buffer.h os_types.h input_vdr.h diff --git a/include/xine/input_vdr.h b/include/xine/input_vdr.h new file mode 100644 index 000000000..41c96d741 --- /dev/null +++ b/include/xine/input_vdr.h @@ -0,0 +1,616 @@ +/* + * Copyright (C) 2000-2004 the xine project + * + * This file is part of xine, a free video player. + * + * xine is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * xine 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA + */ + +#ifndef __INPUT_VDR_H +#define __INPUT_VDR_H + + +#define XINE_INPUT_VDR_VERSION 712 + + +enum funcs +{ + func_unknown = -1 + , func_nop + , func_osd_new + , func_osd_free + , func_osd_show + , func_osd_hide + , func_osd_set_position + , func_osd_draw_bitmap + , func_set_color + , func_clear + , func_mute + , func_set_volume + , func_set_speed + , func_set_prebuffer + , func_metronom + , func_start + , func_wait + , func_setup + , func_grab_image + , func_get_pts + , func_flush + , func_first_frame + , func_still_frame + , func_video_size + , func_set_video_window + , func_osd_flush + , func_play_external + , func_key + , func_frame_size + , func_reset_audio + , func_select_audio + , func_trick_speed_mode + , func_get_version +}; + +enum keys +{ + key_none, + key_up, + key_down, + key_menu, + key_ok, + key_back, + key_left, + key_right, + key_red, + key_green, + key_yellow, + key_blue, + key_0, + key_1, + key_2, + key_3, + key_4, + key_5, + key_6, + key_7, + key_8, + key_9, + key_play, + key_pause, + key_stop, + key_record, + key_fast_fwd, + key_fast_rew, + key_power, + key_channel_plus, + key_channel_minus, + key_volume_plus, + key_volume_minus, + key_mute, + key_schedule, + key_channels, + key_timers, + key_recordings, + key_setup, + key_commands, + key_user1, + key_user2, + key_user3, + key_user4, + key_user5, + key_user6, + key_user7, + key_user8, + key_user9, + key_audio, + key_info, + key_channel_previous, + key_next, + key_previous, + key_subtitles, +}; + + + +typedef struct __attribute__((packed)) data_header_s +{ + uint32_t func:8; + uint32_t len:24; +} +data_header_t; + + + +typedef data_header_t result_header_t; +typedef data_header_t event_header_t; + + + +typedef struct __attribute__((packed)) data_nop_s +{ + data_header_t header; +} +data_nop_t; + + + +typedef struct __attribute__((packed)) data_osd_new_s +{ + data_header_t header; + + uint8_t window; + int16_t x; + int16_t y; + uint16_t width; + uint16_t height; +} +data_osd_new_t; + + + +typedef struct __attribute__((packed)) data_osd_free_s +{ + data_header_t header; + + uint8_t window; +} +data_osd_free_t; + + + +typedef struct __attribute__((packed)) data_osd_show_s +{ + data_header_t header; + + uint8_t window; +} +data_osd_show_t; + + + +typedef struct __attribute__((packed)) data_osd_hide_s +{ + data_header_t header; + + uint8_t window; +} +data_osd_hide_t; + + + +typedef struct __attribute__((packed)) data_osd_flush_s +{ + data_header_t header; +} +data_osd_flush_t; + + + +typedef struct __attribute__((packed)) data_play_external_s +{ + data_header_t header; +} +data_play_external_t; + + + +typedef struct __attribute__((packed)) data_osd_set_position_s +{ + data_header_t header; + + uint8_t window; + int16_t x; + int16_t y; +} +data_osd_set_position_t; + + + +typedef struct __attribute__((packed)) data_osd_draw_bitmap_s +{ + data_header_t header; + + uint8_t window; + int16_t x; + int16_t y; + uint16_t width; + uint16_t height; +} +data_osd_draw_bitmap_t; + + + +typedef struct __attribute__((packed)) data_set_color_s +{ + data_header_t header; + + uint8_t window; + uint8_t index; + uint8_t num; +} +data_set_color_t; + + + +typedef struct __attribute__((packed)) data_flush_s +{ + data_header_t header; + + int32_t ms_timeout; + uint8_t just_wait; +} +data_flush_t; + + + +typedef struct __attribute__((packed)) result_flush_s +{ + result_header_t header; + + uint8_t timed_out; +} +result_flush_t; + + + +typedef struct __attribute__((packed)) data_clear_s +{ + data_header_t header; + + int32_t n; + int8_t s; +} +data_clear_t; + + + +typedef struct __attribute__((packed)) data_mute_s +{ + data_header_t header; + + uint8_t mute; +} +data_mute_t; + + + +typedef struct __attribute__((packed)) data_set_volume_s +{ + data_header_t header; + + uint8_t volume; +} +data_set_volume_t; + + + +typedef struct __attribute__((packed)) data_set_speed_s +{ + data_header_t header; + + int32_t speed; +} +data_set_speed_t; + + + +typedef struct __attribute__((packed)) data_set_prebuffer_s +{ + data_header_t header; + + uint32_t prebuffer; +} +data_set_prebuffer_t; + + + +typedef struct __attribute__((packed)) data_metronom_s +{ + data_header_t header; + + int64_t pts; + uint32_t flags; +} +data_metronom_t; + + + +typedef struct __attribute__((packed)) data_start_s +{ + data_header_t header; +} +data_start_t; + + + +typedef struct __attribute__((packed)) data_wait_s +{ + data_header_t header; +} +data_wait_t; + + + +typedef struct __attribute__((packed)) result_wait_s +{ + result_header_t header; +} +result_wait_t; + + + +#define INPUT_VDR_VOLUME_IGNORE 0 +#define INPUT_VDR_VOLUME_CHANGE_HW 1 +#define INPUT_VDR_VOLUME_CHANGE_SW 2 + +#define INPUT_VDR_MUTE_IGNORE 0 +#define INPUT_VDR_MUTE_EXECUTE 1 +#define INPUT_VDR_MUTE_SIMULATE 2 + +typedef struct __attribute__((packed)) data_setup_s +{ + data_header_t header; + + uint8_t osd_unscaled_blending; + uint8_t volume_mode; + uint8_t mute_mode; + uint16_t image4_3_zoom_x; + uint16_t image4_3_zoom_y; + uint16_t image16_9_zoom_x; + uint16_t image16_9_zoom_y; +} +data_setup_t; + + + +typedef struct __attribute__((packed)) data_first_frame_s +{ + data_header_t header; +} +data_first_frame_t; + + + +typedef struct __attribute__((packed)) data_still_frame_s +{ + data_header_t header; +} +data_still_frame_t; + + + +typedef struct __attribute__((packed)) data_set_video_window_s +{ + data_header_t header; + + uint32_t x; + uint32_t y; + uint32_t w; + uint32_t h; + uint32_t w_ref; + uint32_t h_ref; +} +data_set_video_window_t; + + + +typedef struct __attribute__((packed)) data_grab_image_s +{ + data_header_t header; +} +data_grab_image_t; + + + +typedef struct __attribute__((packed)) result_grab_image_s +{ + result_header_t header; + + int32_t width; + int32_t height; + int32_t ratio; + int32_t format; +} +result_grab_image_t; + + + +typedef struct __attribute__((packed)) data_get_pts_s +{ + data_header_t header; +} +data_get_pts_t; + + + +typedef struct __attribute__((packed)) result_get_pts_s +{ + result_header_t header; + + int64_t pts; +} +result_get_pts_t; + + + +typedef struct __attribute__((packed)) data_get_version_s +{ + data_header_t header; +} +data_get_version_t; + + + +typedef struct __attribute__((packed)) result_get_version_s +{ + result_header_t header; + + int32_t version; +} +result_get_version_t; + + + +typedef struct __attribute__((packed)) data_video_size_s +{ + data_header_t header; +} +data_video_size_t; + + + +typedef struct __attribute__((packed)) result_video_size_s +{ + result_header_t header; + + int32_t left; + int32_t top; + int32_t width; + int32_t height; + int32_t ratio; + int32_t zoom_x; + int32_t zoom_y; +} +result_video_size_t; + + + +typedef struct __attribute__((packed)) data_reset_audio_s +{ + data_header_t header; +} +data_reset_audio_t; + + + +typedef struct __attribute__((packed)) event_key_s +{ + event_header_t header; + + uint32_t key; +} +event_key_t; + + + +typedef struct __attribute__((packed)) event_frame_size_s +{ + event_header_t header; + + int32_t left; + int32_t top; + int32_t width; + int32_t height; + int32_t zoom_x; + int32_t zoom_y; +} +event_frame_size_t; + + + +typedef struct __attribute__((packed)) event_play_external_s +{ + event_header_t header; + + uint32_t key; +} +event_play_external_t; + + + +typedef struct __attribute__((packed)) data_select_audio_s +{ + data_header_t header; + + uint8_t channels; +} +data_select_audio_t; + + + +typedef struct __attribute__((packed)) data_trick_speed_mode_s +{ + data_header_t header; + + uint8_t on; +} +data_trick_speed_mode_t; + + + +typedef union __attribute__((packed)) data_union_u +{ + data_header_t header; + data_nop_t nop; + data_osd_new_t osd_new; + data_osd_free_t osd_free; + data_osd_show_t osd_show; + data_osd_hide_t osd_hide; + data_osd_set_position_t osd_set_position; + data_osd_draw_bitmap_t osd_draw_bitmap; + data_set_color_t set_color; + data_flush_t flush; + data_clear_t clear; + data_mute_t mute; + data_set_volume_t set_volume; + data_set_speed_t set_speed; + data_set_prebuffer_t set_prebuffer; + data_metronom_t metronom; + data_start_t start; + data_wait_t wait; + data_setup_t setup; + data_grab_image_t grab_image; + data_get_pts_t get_pts; + data_first_frame_t first_frame; + data_still_frame_t still_frame; + data_video_size_t video_size; + data_set_video_window_t set_video_window; + data_osd_flush_t osd_flush; + data_play_external_t play_external; + data_reset_audio_t reset_audio; + data_select_audio_t select_audio; + data_trick_speed_mode_t trick_speed_mode; + data_get_version_t get_version; +} +data_union_t; + + + +typedef union __attribute__((packed)) result_union_u +{ + result_header_t header; + result_grab_image_t grab_image; + result_get_pts_t get_pts; + result_flush_t flush; + result_video_size_t video_size; + result_get_version_t get_version; + result_wait_t wait; +} +result_union_t; + + + +typedef union __attribute__((packed)) event_union_u +{ + event_header_t header; + event_key_t key; + event_frame_size_t frame_size; + event_play_external_t play_external; +} +event_union_t; + + + +#endif /* __INPUT_VDR_H */ + -- cgit v1.2.3 From 7a42265fbf3833b328f7ac87d58d732a179ef6e5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reinhard=20Ni=C3=9Fl?= Date: Mon, 31 Dec 2007 11:40:37 +0100 Subject: Combine vdr plugins into a single binary. Several files were renamed for consistency. --HG-- rename : include/xine/input_vdr.h => include/xine/vdr.h rename : src/vdr/post_vdr.c => src/vdr/combined_vdr.c rename : src/vdr/post_vdr.h => src/vdr/combined_vdr.h --- include/xine/Makefile.am | 2 +- include/xine/input_vdr.h | 616 ----------------------------------------------- include/xine/vdr.h | 616 +++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 617 insertions(+), 617 deletions(-) delete mode 100644 include/xine/input_vdr.h create mode 100644 include/xine/vdr.h (limited to 'include') diff --git a/include/xine/Makefile.am b/include/xine/Makefile.am index cad6adb31..cc086dfaf 100644 --- a/include/xine/Makefile.am +++ b/include/xine/Makefile.am @@ -8,4 +8,4 @@ xineinclude_HEADERS = version.h buffer.h metronom.h configfile.h vo_scale.h \ io_helper.h broadcaster.h info_helper.h refcounter.h alphablend.h \ demux.h input_plugin.h attributes.h compat.h xine_buffer.h \ xineutils.h xmllexer.h xmlparser.h list.h array.h sorted_array.h \ - pool.h ring_buffer.h os_types.h input_vdr.h + pool.h ring_buffer.h os_types.h vdr.h diff --git a/include/xine/input_vdr.h b/include/xine/input_vdr.h deleted file mode 100644 index 41c96d741..000000000 --- a/include/xine/input_vdr.h +++ /dev/null @@ -1,616 +0,0 @@ -/* - * Copyright (C) 2000-2004 the xine project - * - * This file is part of xine, a free video player. - * - * xine is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * xine 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 General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA - */ - -#ifndef __INPUT_VDR_H -#define __INPUT_VDR_H - - -#define XINE_INPUT_VDR_VERSION 712 - - -enum funcs -{ - func_unknown = -1 - , func_nop - , func_osd_new - , func_osd_free - , func_osd_show - , func_osd_hide - , func_osd_set_position - , func_osd_draw_bitmap - , func_set_color - , func_clear - , func_mute - , func_set_volume - , func_set_speed - , func_set_prebuffer - , func_metronom - , func_start - , func_wait - , func_setup - , func_grab_image - , func_get_pts - , func_flush - , func_first_frame - , func_still_frame - , func_video_size - , func_set_video_window - , func_osd_flush - , func_play_external - , func_key - , func_frame_size - , func_reset_audio - , func_select_audio - , func_trick_speed_mode - , func_get_version -}; - -enum keys -{ - key_none, - key_up, - key_down, - key_menu, - key_ok, - key_back, - key_left, - key_right, - key_red, - key_green, - key_yellow, - key_blue, - key_0, - key_1, - key_2, - key_3, - key_4, - key_5, - key_6, - key_7, - key_8, - key_9, - key_play, - key_pause, - key_stop, - key_record, - key_fast_fwd, - key_fast_rew, - key_power, - key_channel_plus, - key_channel_minus, - key_volume_plus, - key_volume_minus, - key_mute, - key_schedule, - key_channels, - key_timers, - key_recordings, - key_setup, - key_commands, - key_user1, - key_user2, - key_user3, - key_user4, - key_user5, - key_user6, - key_user7, - key_user8, - key_user9, - key_audio, - key_info, - key_channel_previous, - key_next, - key_previous, - key_subtitles, -}; - - - -typedef struct __attribute__((packed)) data_header_s -{ - uint32_t func:8; - uint32_t len:24; -} -data_header_t; - - - -typedef data_header_t result_header_t; -typedef data_header_t event_header_t; - - - -typedef struct __attribute__((packed)) data_nop_s -{ - data_header_t header; -} -data_nop_t; - - - -typedef struct __attribute__((packed)) data_osd_new_s -{ - data_header_t header; - - uint8_t window; - int16_t x; - int16_t y; - uint16_t width; - uint16_t height; -} -data_osd_new_t; - - - -typedef struct __attribute__((packed)) data_osd_free_s -{ - data_header_t header; - - uint8_t window; -} -data_osd_free_t; - - - -typedef struct __attribute__((packed)) data_osd_show_s -{ - data_header_t header; - - uint8_t window; -} -data_osd_show_t; - - - -typedef struct __attribute__((packed)) data_osd_hide_s -{ - data_header_t header; - - uint8_t window; -} -data_osd_hide_t; - - - -typedef struct __attribute__((packed)) data_osd_flush_s -{ - data_header_t header; -} -data_osd_flush_t; - - - -typedef struct __attribute__((packed)) data_play_external_s -{ - data_header_t header; -} -data_play_external_t; - - - -typedef struct __attribute__((packed)) data_osd_set_position_s -{ - data_header_t header; - - uint8_t window; - int16_t x; - int16_t y; -} -data_osd_set_position_t; - - - -typedef struct __attribute__((packed)) data_osd_draw_bitmap_s -{ - data_header_t header; - - uint8_t window; - int16_t x; - int16_t y; - uint16_t width; - uint16_t height; -} -data_osd_draw_bitmap_t; - - - -typedef struct __attribute__((packed)) data_set_color_s -{ - data_header_t header; - - uint8_t window; - uint8_t index; - uint8_t num; -} -data_set_color_t; - - - -typedef struct __attribute__((packed)) data_flush_s -{ - data_header_t header; - - int32_t ms_timeout; - uint8_t just_wait; -} -data_flush_t; - - - -typedef struct __attribute__((packed)) result_flush_s -{ - result_header_t header; - - uint8_t timed_out; -} -result_flush_t; - - - -typedef struct __attribute__((packed)) data_clear_s -{ - data_header_t header; - - int32_t n; - int8_t s; -} -data_clear_t; - - - -typedef struct __attribute__((packed)) data_mute_s -{ - data_header_t header; - - uint8_t mute; -} -data_mute_t; - - - -typedef struct __attribute__((packed)) data_set_volume_s -{ - data_header_t header; - - uint8_t volume; -} -data_set_volume_t; - - - -typedef struct __attribute__((packed)) data_set_speed_s -{ - data_header_t header; - - int32_t speed; -} -data_set_speed_t; - - - -typedef struct __attribute__((packed)) data_set_prebuffer_s -{ - data_header_t header; - - uint32_t prebuffer; -} -data_set_prebuffer_t; - - - -typedef struct __attribute__((packed)) data_metronom_s -{ - data_header_t header; - - int64_t pts; - uint32_t flags; -} -data_metronom_t; - - - -typedef struct __attribute__((packed)) data_start_s -{ - data_header_t header; -} -data_start_t; - - - -typedef struct __attribute__((packed)) data_wait_s -{ - data_header_t header; -} -data_wait_t; - - - -typedef struct __attribute__((packed)) result_wait_s -{ - result_header_t header; -} -result_wait_t; - - - -#define INPUT_VDR_VOLUME_IGNORE 0 -#define INPUT_VDR_VOLUME_CHANGE_HW 1 -#define INPUT_VDR_VOLUME_CHANGE_SW 2 - -#define INPUT_VDR_MUTE_IGNORE 0 -#define INPUT_VDR_MUTE_EXECUTE 1 -#define INPUT_VDR_MUTE_SIMULATE 2 - -typedef struct __attribute__((packed)) data_setup_s -{ - data_header_t header; - - uint8_t osd_unscaled_blending; - uint8_t volume_mode; - uint8_t mute_mode; - uint16_t image4_3_zoom_x; - uint16_t image4_3_zoom_y; - uint16_t image16_9_zoom_x; - uint16_t image16_9_zoom_y; -} -data_setup_t; - - - -typedef struct __attribute__((packed)) data_first_frame_s -{ - data_header_t header; -} -data_first_frame_t; - - - -typedef struct __attribute__((packed)) data_still_frame_s -{ - data_header_t header; -} -data_still_frame_t; - - - -typedef struct __attribute__((packed)) data_set_video_window_s -{ - data_header_t header; - - uint32_t x; - uint32_t y; - uint32_t w; - uint32_t h; - uint32_t w_ref; - uint32_t h_ref; -} -data_set_video_window_t; - - - -typedef struct __attribute__((packed)) data_grab_image_s -{ - data_header_t header; -} -data_grab_image_t; - - - -typedef struct __attribute__((packed)) result_grab_image_s -{ - result_header_t header; - - int32_t width; - int32_t height; - int32_t ratio; - int32_t format; -} -result_grab_image_t; - - - -typedef struct __attribute__((packed)) data_get_pts_s -{ - data_header_t header; -} -data_get_pts_t; - - - -typedef struct __attribute__((packed)) result_get_pts_s -{ - result_header_t header; - - int64_t pts; -} -result_get_pts_t; - - - -typedef struct __attribute__((packed)) data_get_version_s -{ - data_header_t header; -} -data_get_version_t; - - - -typedef struct __attribute__((packed)) result_get_version_s -{ - result_header_t header; - - int32_t version; -} -result_get_version_t; - - - -typedef struct __attribute__((packed)) data_video_size_s -{ - data_header_t header; -} -data_video_size_t; - - - -typedef struct __attribute__((packed)) result_video_size_s -{ - result_header_t header; - - int32_t left; - int32_t top; - int32_t width; - int32_t height; - int32_t ratio; - int32_t zoom_x; - int32_t zoom_y; -} -result_video_size_t; - - - -typedef struct __attribute__((packed)) data_reset_audio_s -{ - data_header_t header; -} -data_reset_audio_t; - - - -typedef struct __attribute__((packed)) event_key_s -{ - event_header_t header; - - uint32_t key; -} -event_key_t; - - - -typedef struct __attribute__((packed)) event_frame_size_s -{ - event_header_t header; - - int32_t left; - int32_t top; - int32_t width; - int32_t height; - int32_t zoom_x; - int32_t zoom_y; -} -event_frame_size_t; - - - -typedef struct __attribute__((packed)) event_play_external_s -{ - event_header_t header; - - uint32_t key; -} -event_play_external_t; - - - -typedef struct __attribute__((packed)) data_select_audio_s -{ - data_header_t header; - - uint8_t channels; -} -data_select_audio_t; - - - -typedef struct __attribute__((packed)) data_trick_speed_mode_s -{ - data_header_t header; - - uint8_t on; -} -data_trick_speed_mode_t; - - - -typedef union __attribute__((packed)) data_union_u -{ - data_header_t header; - data_nop_t nop; - data_osd_new_t osd_new; - data_osd_free_t osd_free; - data_osd_show_t osd_show; - data_osd_hide_t osd_hide; - data_osd_set_position_t osd_set_position; - data_osd_draw_bitmap_t osd_draw_bitmap; - data_set_color_t set_color; - data_flush_t flush; - data_clear_t clear; - data_mute_t mute; - data_set_volume_t set_volume; - data_set_speed_t set_speed; - data_set_prebuffer_t set_prebuffer; - data_metronom_t metronom; - data_start_t start; - data_wait_t wait; - data_setup_t setup; - data_grab_image_t grab_image; - data_get_pts_t get_pts; - data_first_frame_t first_frame; - data_still_frame_t still_frame; - data_video_size_t video_size; - data_set_video_window_t set_video_window; - data_osd_flush_t osd_flush; - data_play_external_t play_external; - data_reset_audio_t reset_audio; - data_select_audio_t select_audio; - data_trick_speed_mode_t trick_speed_mode; - data_get_version_t get_version; -} -data_union_t; - - - -typedef union __attribute__((packed)) result_union_u -{ - result_header_t header; - result_grab_image_t grab_image; - result_get_pts_t get_pts; - result_flush_t flush; - result_video_size_t video_size; - result_get_version_t get_version; - result_wait_t wait; -} -result_union_t; - - - -typedef union __attribute__((packed)) event_union_u -{ - event_header_t header; - event_key_t key; - event_frame_size_t frame_size; - event_play_external_t play_external; -} -event_union_t; - - - -#endif /* __INPUT_VDR_H */ - diff --git a/include/xine/vdr.h b/include/xine/vdr.h new file mode 100644 index 000000000..faec3b966 --- /dev/null +++ b/include/xine/vdr.h @@ -0,0 +1,616 @@ +/* + * Copyright (C) 2000-2004 the xine project + * + * This file is part of xine, a free video player. + * + * xine is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * xine 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 General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA + */ + +#ifndef __VDR_H +#define __VDR_H + + +#define XINE_INPUT_VDR_VERSION 712 + + +enum funcs +{ + func_unknown = -1 + , func_nop + , func_osd_new + , func_osd_free + , func_osd_show + , func_osd_hide + , func_osd_set_position + , func_osd_draw_bitmap + , func_set_color + , func_clear + , func_mute + , func_set_volume + , func_set_speed + , func_set_prebuffer + , func_metronom + , func_start + , func_wait + , func_setup + , func_grab_image + , func_get_pts + , func_flush + , func_first_frame + , func_still_frame + , func_video_size + , func_set_video_window + , func_osd_flush + , func_play_external + , func_key + , func_frame_size + , func_reset_audio + , func_select_audio + , func_trick_speed_mode + , func_get_version +}; + +enum keys +{ + key_none, + key_up, + key_down, + key_menu, + key_ok, + key_back, + key_left, + key_right, + key_red, + key_green, + key_yellow, + key_blue, + key_0, + key_1, + key_2, + key_3, + key_4, + key_5, + key_6, + key_7, + key_8, + key_9, + key_play, + key_pause, + key_stop, + key_record, + key_fast_fwd, + key_fast_rew, + key_power, + key_channel_plus, + key_channel_minus, + key_volume_plus, + key_volume_minus, + key_mute, + key_schedule, + key_channels, + key_timers, + key_recordings, + key_setup, + key_commands, + key_user1, + key_user2, + key_user3, + key_user4, + key_user5, + key_user6, + key_user7, + key_user8, + key_user9, + key_audio, + key_info, + key_channel_previous, + key_next, + key_previous, + key_subtitles, +}; + + + +typedef struct __attribute__((packed)) data_header_s +{ + uint32_t func:8; + uint32_t len:24; +} +data_header_t; + + + +typedef data_header_t result_header_t; +typedef data_header_t event_header_t; + + + +typedef struct __attribute__((packed)) data_nop_s +{ + data_header_t header; +} +data_nop_t; + + + +typedef struct __attribute__((packed)) data_osd_new_s +{ + data_header_t header; + + uint8_t window; + int16_t x; + int16_t y; + uint16_t width; + uint16_t height; +} +data_osd_new_t; + + + +typedef struct __attribute__((packed)) data_osd_free_s +{ + data_header_t header; + + uint8_t window; +} +data_osd_free_t; + + + +typedef struct __attribute__((packed)) data_osd_show_s +{ + data_header_t header; + + uint8_t window; +} +data_osd_show_t; + + + +typedef struct __attribute__((packed)) data_osd_hide_s +{ + data_header_t header; + + uint8_t window; +} +data_osd_hide_t; + + + +typedef struct __attribute__((packed)) data_osd_flush_s +{ + data_header_t header; +} +data_osd_flush_t; + + + +typedef struct __attribute__((packed)) data_play_external_s +{ + data_header_t header; +} +data_play_external_t; + + + +typedef struct __attribute__((packed)) data_osd_set_position_s +{ + data_header_t header; + + uint8_t window; + int16_t x; + int16_t y; +} +data_osd_set_position_t; + + + +typedef struct __attribute__((packed)) data_osd_draw_bitmap_s +{ + data_header_t header; + + uint8_t window; + int16_t x; + int16_t y; + uint16_t width; + uint16_t height; +} +data_osd_draw_bitmap_t; + + + +typedef struct __attribute__((packed)) data_set_color_s +{ + data_header_t header; + + uint8_t window; + uint8_t index; + uint8_t num; +} +data_set_color_t; + + + +typedef struct __attribute__((packed)) data_flush_s +{ + data_header_t header; + + int32_t ms_timeout; + uint8_t just_wait; +} +data_flush_t; + + + +typedef struct __attribute__((packed)) result_flush_s +{ + result_header_t header; + + uint8_t timed_out; +} +result_flush_t; + + + +typedef struct __attribute__((packed)) data_clear_s +{ + data_header_t header; + + int32_t n; + int8_t s; +} +data_clear_t; + + + +typedef struct __attribute__((packed)) data_mute_s +{ + data_header_t header; + + uint8_t mute; +} +data_mute_t; + + + +typedef struct __attribute__((packed)) data_set_volume_s +{ + data_header_t header; + + uint8_t volume; +} +data_set_volume_t; + + + +typedef struct __attribute__((packed)) data_set_speed_s +{ + data_header_t header; + + int32_t speed; +} +data_set_speed_t; + + + +typedef struct __attribute__((packed)) data_set_prebuffer_s +{ + data_header_t header; + + uint32_t prebuffer; +} +data_set_prebuffer_t; + + + +typedef struct __attribute__((packed)) data_metronom_s +{ + data_header_t header; + + int64_t pts; + uint32_t flags; +} +data_metronom_t; + + + +typedef struct __attribute__((packed)) data_start_s +{ + data_header_t header; +} +data_start_t; + + + +typedef struct __attribute__((packed)) data_wait_s +{ + data_header_t header; +} +data_wait_t; + + + +typedef struct __attribute__((packed)) result_wait_s +{ + result_header_t header; +} +result_wait_t; + + + +#define INPUT_VDR_VOLUME_IGNORE 0 +#define INPUT_VDR_VOLUME_CHANGE_HW 1 +#define INPUT_VDR_VOLUME_CHANGE_SW 2 + +#define INPUT_VDR_MUTE_IGNORE 0 +#define INPUT_VDR_MUTE_EXECUTE 1 +#define INPUT_VDR_MUTE_SIMULATE 2 + +typedef struct __attribute__((packed)) data_setup_s +{ + data_header_t header; + + uint8_t osd_unscaled_blending; + uint8_t volume_mode; + uint8_t mute_mode; + uint16_t image4_3_zoom_x; + uint16_t image4_3_zoom_y; + uint16_t image16_9_zoom_x; + uint16_t image16_9_zoom_y; +} +data_setup_t; + + + +typedef struct __attribute__((packed)) data_first_frame_s +{ + data_header_t header; +} +data_first_frame_t; + + + +typedef struct __attribute__((packed)) data_still_frame_s +{ + data_header_t header; +} +data_still_frame_t; + + + +typedef struct __attribute__((packed)) data_set_video_window_s +{ + data_header_t header; + + uint32_t x; + uint32_t y; + uint32_t w; + uint32_t h; + uint32_t w_ref; + uint32_t h_ref; +} +data_set_video_window_t; + + + +typedef struct __attribute__((packed)) data_grab_image_s +{ + data_header_t header; +} +data_grab_image_t; + + + +typedef struct __attribute__((packed)) result_grab_image_s +{ + result_header_t header; + + int32_t width; + int32_t height; + int32_t ratio; + int32_t format; +} +result_grab_image_t; + + + +typedef struct __attribute__((packed)) data_get_pts_s +{ + data_header_t header; +} +data_get_pts_t; + + + +typedef struct __attribute__((packed)) result_get_pts_s +{ + result_header_t header; + + int64_t pts; +} +result_get_pts_t; + + + +typedef struct __attribute__((packed)) data_get_version_s +{ + data_header_t header; +} +data_get_version_t; + + + +typedef struct __attribute__((packed)) result_get_version_s +{ + result_header_t header; + + int32_t version; +} +result_get_version_t; + + + +typedef struct __attribute__((packed)) data_video_size_s +{ + data_header_t header; +} +data_video_size_t; + + + +typedef struct __attribute__((packed)) result_video_size_s +{ + result_header_t header; + + int32_t left; + int32_t top; + int32_t width; + int32_t height; + int32_t ratio; + int32_t zoom_x; + int32_t zoom_y; +} +result_video_size_t; + + + +typedef struct __attribute__((packed)) data_reset_audio_s +{ + data_header_t header; +} +data_reset_audio_t; + + + +typedef struct __attribute__((packed)) event_key_s +{ + event_header_t header; + + uint32_t key; +} +event_key_t; + + + +typedef struct __attribute__((packed)) event_frame_size_s +{ + event_header_t header; + + int32_t left; + int32_t top; + int32_t width; + int32_t height; + int32_t zoom_x; + int32_t zoom_y; +} +event_frame_size_t; + + + +typedef struct __attribute__((packed)) event_play_external_s +{ + event_header_t header; + + uint32_t key; +} +event_play_external_t; + + + +typedef struct __attribute__((packed)) data_select_audio_s +{ + data_header_t header; + + uint8_t channels; +} +data_select_audio_t; + + + +typedef struct __attribute__((packed)) data_trick_speed_mode_s +{ + data_header_t header; + + uint8_t on; +} +data_trick_speed_mode_t; + + + +typedef union __attribute__((packed)) data_union_u +{ + data_header_t header; + data_nop_t nop; + data_osd_new_t osd_new; + data_osd_free_t osd_free; + data_osd_show_t osd_show; + data_osd_hide_t osd_hide; + data_osd_set_position_t osd_set_position; + data_osd_draw_bitmap_t osd_draw_bitmap; + data_set_color_t set_color; + data_flush_t flush; + data_clear_t clear; + data_mute_t mute; + data_set_volume_t set_volume; + data_set_speed_t set_speed; + data_set_prebuffer_t set_prebuffer; + data_metronom_t metronom; + data_start_t start; + data_wait_t wait; + data_setup_t setup; + data_grab_image_t grab_image; + data_get_pts_t get_pts; + data_first_frame_t first_frame; + data_still_frame_t still_frame; + data_video_size_t video_size; + data_set_video_window_t set_video_window; + data_osd_flush_t osd_flush; + data_play_external_t play_external; + data_reset_audio_t reset_audio; + data_select_audio_t select_audio; + data_trick_speed_mode_t trick_speed_mode; + data_get_version_t get_version; +} +data_union_t; + + + +typedef union __attribute__((packed)) result_union_u +{ + result_header_t header; + result_grab_image_t grab_image; + result_get_pts_t get_pts; + result_flush_t flush; + result_video_size_t video_size; + result_get_version_t get_version; + result_wait_t wait; +} +result_union_t; + + + +typedef union __attribute__((packed)) event_union_u +{ + event_header_t header; + event_key_t key; + event_frame_size_t frame_size; + event_play_external_t play_external; +} +event_union_t; + + + +#endif /* __VDR_H */ + -- cgit v1.2.3 From a25d1ff9ec4f0ff8c59b66a9bb1ffca957e3b793 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reinhard=20Ni=C3=9Fl?= Date: Mon, 31 Dec 2007 11:45:54 +0100 Subject: Change some constants to accommodate recent filename changes. --- include/xine/vdr.h | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'include') diff --git a/include/xine/vdr.h b/include/xine/vdr.h index faec3b966..c67873636 100644 --- a/include/xine/vdr.h +++ b/include/xine/vdr.h @@ -22,7 +22,7 @@ #define __VDR_H -#define XINE_INPUT_VDR_VERSION 712 +#define XINE_VDR_VERSION 712 enum funcs @@ -350,13 +350,13 @@ result_wait_t; -#define INPUT_VDR_VOLUME_IGNORE 0 -#define INPUT_VDR_VOLUME_CHANGE_HW 1 -#define INPUT_VDR_VOLUME_CHANGE_SW 2 +#define XINE_VDR_VOLUME_IGNORE 0 +#define XINE_VDR_VOLUME_CHANGE_HW 1 +#define XINE_VDR_VOLUME_CHANGE_SW 2 -#define INPUT_VDR_MUTE_IGNORE 0 -#define INPUT_VDR_MUTE_EXECUTE 1 -#define INPUT_VDR_MUTE_SIMULATE 2 +#define XINE_VDR_MUTE_IGNORE 0 +#define XINE_VDR_MUTE_EXECUTE 1 +#define XINE_VDR_MUTE_SIMULATE 2 typedef struct __attribute__((packed)) data_setup_s { -- cgit v1.2.3 From 9674cfd4453258a728a7a77a3dd44416284522af Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Reinhard=20Ni=C3=9Fl?= Date: Mon, 31 Dec 2007 11:48:01 +0100 Subject: Require at least vdr-xine-0.8.1 due to the repository changes. --- include/xine/vdr.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/xine/vdr.h b/include/xine/vdr.h index c67873636..5102d7f77 100644 --- a/include/xine/vdr.h +++ b/include/xine/vdr.h @@ -22,7 +22,7 @@ #define __VDR_H -#define XINE_VDR_VERSION 712 +#define XINE_VDR_VERSION 801 enum funcs -- cgit v1.2.3 From 9285ce63facf833394d79d4e5be6adfa4c70eac6 Mon Sep 17 00:00:00 2001 From: Petri Hintukainen Date: Tue, 1 Jan 2008 07:22:49 +0200 Subject: Bump post plugin interface version after API changes (Changeset 9602: Replace get_identifier/get_description functions with strings.) --- include/xine/post.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/xine/post.h b/include/xine/post.h index 3056f8120..10844d03a 100644 --- a/include/xine/post.h +++ b/include/xine/post.h @@ -33,7 +33,7 @@ # include #endif -#define POST_PLUGIN_IFACE_VERSION 9 +#define POST_PLUGIN_IFACE_VERSION 10 typedef struct post_class_s post_class_t; -- cgit v1.2.3 From 2d2d8ad95d38fc879884ee8921dbdbdb7bb72de8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Wed, 2 Jan 2008 18:46:49 +0100 Subject: Mark id as constant, as we always use a literal. --- include/xine/xine_plugin.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/xine/xine_plugin.h b/include/xine/xine_plugin.h index 11ccc5e11..2939b17a9 100644 --- a/include/xine/xine_plugin.h +++ b/include/xine/xine_plugin.h @@ -50,7 +50,7 @@ typedef struct { uint8_t type; /* one of the PLUGIN_* constants above */ uint8_t API; /* API version supported by this plugin */ - char *id; /* a name that identifies this plugin */ + const char *id; /* a name that identifies this plugin */ uint32_t version; /* version number, increased every release */ const void *special_info; /* plugin-type specific, see structs below */ void *(*init)(xine_t *, void *); /* init the plugin class */ -- cgit v1.2.3 From 1406457b847cac6b63d4d670833e5e47f35b8cf4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Wed, 2 Jan 2008 18:55:25 +0100 Subject: Make _x_vo_scape_aspect_ratio_name return a constant string. Note that this should probably be replaced with a const string table. --- include/xine/vo_scale.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/xine/vo_scale.h b/include/xine/vo_scale.h index b8b1a535b..9c7f8f4f3 100644 --- a/include/xine/vo_scale.h +++ b/include/xine/vo_scale.h @@ -183,7 +183,7 @@ void _x_vo_scale_translate_gui2video(vo_scale_t *self, * Returns description of a given ratio code */ -char *_x_vo_scale_aspect_ratio_name(int a) XINE_PROTECTED; +const char *_x_vo_scale_aspect_ratio_name(int a) XINE_PROTECTED; /* * initialize rescaling struct -- cgit v1.2.3 From 25637e5a99d5a9cabd5a37b5746bcadcda1b2360 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Wed, 2 Jan 2008 19:01:39 +0100 Subject: Mark xine_health_check_s strings as constant. --- include/xine.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/xine.h b/include/xine.h index 1d26daa19..c3ac38cbf 100644 --- a/include/xine.h +++ b/include/xine.h @@ -1335,9 +1335,9 @@ typedef struct { struct xine_health_check_s { const char* cdrom_dev; const char* dvd_dev; - char* msg; - char* title; - char* explanation; + const char* msg; + const char* title; + const char* explanation; int status; }; -- cgit v1.2.3 From 299a77d45f12f0e9103925a86b985f307e8eee6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Wed, 2 Jan 2008 19:14:22 +0100 Subject: Make description and name of post-plugin parameters constant. --- include/xine.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/xine.h b/include/xine.h index c3ac38cbf..17b8cfbf6 100644 --- a/include/xine.h +++ b/include/xine.h @@ -707,14 +707,14 @@ void xine_post_dispose(xine_t *xine, xine_post_t *self) XINE_PROTECTED; /* defines a single parameter entry. */ typedef struct { int type; /* POST_PARAM_TYPE_xxx */ - char *name; /* name of this parameter */ + const char *name; /* name of this parameter */ int size; /* sizeof(parameter) */ int offset; /* offset in bytes from struct ptr */ char **enum_values; /* enumeration (first=0) or NULL */ double range_min; /* minimum value */ double range_max; /* maximum value */ int readonly; /* 0 = read/write, 1=read-only */ - char *description; /* user-friendly description */ + const char *description; /* user-friendly description */ } xine_post_api_parameter_t; /* description of parameters struct (params). */ -- cgit v1.2.3 From 760c9b664fb211d720111b2e462092180acae44c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Diego=20=27Flameeyes=27=20Petten=C3=B2?= Date: Thu, 3 Jan 2008 01:25:57 +0100 Subject: Replace _x_vo_scale_aspect_ratio_name() function with a string table, all the uses already check for the index not to go over ther expected one. --- include/xine/vo_scale.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/xine/vo_scale.h b/include/xine/vo_scale.h index 9c7f8f4f3..686d53c22 100644 --- a/include/xine/vo_scale.h +++ b/include/xine/vo_scale.h @@ -183,7 +183,7 @@ void _x_vo_scale_translate_gui2video(vo_scale_t *self, * Returns description of a given ratio code */ -const char *_x_vo_scale_aspect_ratio_name(int a) XINE_PROTECTED; +extern const char _x_vo_scale_aspect_ratio_name_table[][8] XINE_PROTECTED; /* * initialize rescaling struct -- cgit v1.2.3