diff options
author | Darren Salt <linux@youmustbejoking.demon.co.uk> | 2008-12-28 21:21:34 +0000 |
---|---|---|
committer | Darren Salt <linux@youmustbejoking.demon.co.uk> | 2008-12-28 21:21:34 +0000 |
commit | 53833ecfeb3b961f6dba3ace15e725b08728efc9 (patch) | |
tree | d6ef9daa894e5fd3577c51434f97fbc7c32cfab2 | |
parent | 9e8eeff63323bc5e5dd6c40fc779b5d89e64acd4 (diff) | |
download | xine-lib-53833ecfeb3b961f6dba3ace15e725b08728efc9.tar.gz xine-lib-53833ecfeb3b961f6dba3ace15e725b08728efc9.tar.bz2 |
Centralise some Xv-related static string array declarations.
-rw-r--r-- | src/video_out/video_out_xcbxv.c | 6 | ||||
-rw-r--r-- | src/video_out/video_out_xv.c | 6 | ||||
-rw-r--r-- | src/video_out/video_out_xxmc.c | 4 | ||||
-rw-r--r-- | src/video_out/xv_common.h | 20 |
4 files changed, 19 insertions, 17 deletions
diff --git a/src/video_out/video_out_xcbxv.c b/src/video_out/video_out_xcbxv.c index 107a60a5c..f1f14333d 100644 --- a/src/video_out/video_out_xcbxv.c +++ b/src/video_out/video_out_xcbxv.c @@ -158,9 +158,9 @@ typedef struct { xine_t *xine; } xv_class_t; -static const char *const prefer_types[] = VIDEO_DEVICE_XV_PREFER_TYPES; -static const char *const bicubic_types[] = VIDEO_DEVICE_XV_BICUBIC_TYPES; -static const char *const sync_atoms[] = VIDEO_DEVICE_XV_VSYNC_ATOMS; +VIDEO_DEVICE_XV_DECL_BICUBIC_TYPES; +VIDEO_DEVICE_XV_DECL_PREFER_TYPES; +VIDEO_DEVICE_XV_DECL_SYNC_ATOMS; static uint32_t xv_get_capabilities (vo_driver_t *this_gen) { xv_driver_t *this = (xv_driver_t *) this_gen; diff --git a/src/video_out/video_out_xv.c b/src/video_out/video_out_xv.c index cc5ed3fb0..d5d854ebf 100644 --- a/src/video_out/video_out_xv.c +++ b/src/video_out/video_out_xv.c @@ -171,9 +171,9 @@ typedef struct { static int gX11Fail; -static const char *const prefer_types[] = VIDEO_DEVICE_XV_PREFER_TYPES; -static const char *const bicubic_types[] = VIDEO_DEVICE_XV_BICUBIC_TYPES; -static const char *const sync_atoms[] = VIDEO_DEVICE_XV_VSYNC_ATOMS; +VIDEO_DEVICE_XV_DECL_BICUBIC_TYPES; +VIDEO_DEVICE_XV_DECL_PREFER_TYPES; +VIDEO_DEVICE_XV_DECL_SYNC_ATOMS; static uint32_t xv_get_capabilities (vo_driver_t *this_gen) { xv_driver_t *this = (xv_driver_t *) this_gen; diff --git a/src/video_out/video_out_xxmc.c b/src/video_out/video_out_xxmc.c index 454f2cb8b..d30e69247 100644 --- a/src/video_out/video_out_xxmc.c +++ b/src/video_out/video_out_xxmc.c @@ -45,8 +45,8 @@ static void xxmc_frame_updates(xxmc_driver_t *driver, xxmc_frame_t *frame, static void dispose_ximage (xxmc_driver_t *this, XShmSegmentInfo *shminfo, XvImage *myimage); -static const char *const prefer_types[] = VIDEO_DEVICE_XV_PREFER_TYPES; -static const char *const bicubic_types[] = VIDEO_DEVICE_XV_BICUBIC_TYPES; +VIDEO_DEVICE_XV_DECL_BICUBIC_TYPES; +VIDEO_DEVICE_XV_DECL_PREFER_TYPES; /* * Acceleration level priority. Static for now. It may well turn out that IDCT diff --git a/src/video_out/xv_common.h b/src/video_out/xv_common.h index e24728cdd..cac80c0aa 100644 --- a/src/video_out/xv_common.h +++ b/src/video_out/xv_common.h @@ -57,22 +57,24 @@ _("pitch alignment workaround"), \ _("Some buggy video drivers need a workaround to function properly.") -#define VIDEO_DEVICE_XV_VSYNC_ATOMS \ - { "XV_SYNC_TO_VBLANK", "XV_VSYNC" } +#define VIDEO_DEVICE_XV_DECL_SYNC_ATOMS \ + static const char *const sync_atoms[] = \ + { "XV_SYNC_TO_VBLANK", "XV_VSYNC" }; -typedef enum { - xv_prefer_none, xv_prefer_overlay, xv_prefer_textured -} xv_prefertype; -#define VIDEO_DEVICE_XV_PREFER_TYPES \ - { "Any", "Overlay", "Textured Video", NULL } +#define VIDEO_DEVICE_XV_DECL_PREFER_TYPES \ + typedef enum { \ + xv_prefer_none, xv_prefer_overlay, xv_prefer_textured, \ + } xv_prefertype; \ + static const char *const prefer_types[] = \ + { "Any", "Overlay", "Textured Video", NULL }; #define VIDEO_DEVICE_XV_PREFER_TYPE_HELP \ _("video display method preference"), \ _("Selects which video output method is preferred. " \ "Detection is done using the reported Xv adaptor names.\n" \ "(Only applies when auto-detecting which Xv port to use.)") -#define VIDEO_DEVICE_XV_BICUBIC_TYPES \ - { "Off", "On", "Auto", NULL } +#define VIDEO_DEVICE_XV_DECL_BICUBIC_TYPES \ + static const char *const bicubic_types[] = { "Off", "On", "Auto", NULL }; #define VIDEO_DEVICE_XV_BICUBIC_HELP \ _("bicubic filtering"), \ _("This option controls bicubic filtering of the video image. " \ |