diff --git a/cfg-common-opts.h b/cfg-common-opts.h index dd9b691002..1bdbca4735 100644 --- a/cfg-common-opts.h +++ b/cfg-common-opts.h @@ -20,7 +20,7 @@ #define MPLAYER_CFG_COMMON_OPTS_H #include "config.h" - +#include "libmpcodecs/vd.h" #include "osdep/priority.h" // ------------------------- common options -------------------- diff --git a/cfg-common.h b/cfg-common.h index 410e7e386e..aefe60c097 100644 --- a/cfg-common.h +++ b/cfg-common.h @@ -28,11 +28,6 @@ extern char *mp_msg_charset; extern int mp_msg_color; extern int mp_msg_module; -// codec/filter opts: (defined at libmpcodecs/vd.c) -extern float screen_size_xy; -extern int softzoom; -extern int flip; - /* defined in codec-cfg.c */ extern char * codecs_file; diff --git a/cfg-mplayer.h b/cfg-mplayer.h index b5e83f7b04..0465725421 100644 --- a/cfg-mplayer.h +++ b/cfg-mplayer.h @@ -24,6 +24,7 @@ */ #include "cfg-common.h" +#include "libmpcodecs/vd.h" #include "libvo/vo_zr.h" extern int key_fifo_size; @@ -39,11 +40,6 @@ extern float vo_panscanrange; /* only used at startup (setting these values from configfile) */ extern char *vo_geometry; -extern int opt_screen_size_x; -extern int opt_screen_size_y; -extern int fullscreen; -extern int vidmode; - extern char *ao_outputfilename; extern int ao_pcm_waveheader; diff --git a/gui/cfg.c b/gui/cfg.c index ca361fb9eb..3d564b4200 100644 --- a/gui/cfg.c +++ b/gui/cfg.c @@ -28,6 +28,7 @@ #include "m_config.h" #include "m_option.h" #include "get_path.h" +#include "libmpcodecs/vd.h" #include "libvo/sub.h" #include "libvo/video_out.h" #include "stream/stream.h" diff --git a/gui/interface.c b/gui/interface.c index 9d57caf2c3..83e897d267 100644 --- a/gui/interface.c +++ b/gui/interface.c @@ -39,6 +39,7 @@ #include "get_path.h" #include "mp_core.h" #include "mplayer.h" +#include "libmpcodecs/vd.h" #include "libvo/x11_common.h" #include "libvo/video_out.h" #include "libvo/font_load.h" diff --git a/gui/mplayer/gmplayer.h b/gui/mplayer/gmplayer.h index 279cad0753..d932cde31f 100644 --- a/gui/mplayer/gmplayer.h +++ b/gui/mplayer/gmplayer.h @@ -31,8 +31,6 @@ extern int mplMiddleMenu; extern char * dvd_device; extern char * cdrom_device; -extern int fullscreen; -extern int flip; void mplInit( void * disp ); diff --git a/gui/mplayer/play.c b/gui/mplayer/play.c index b398f9f901..55fc98b931 100644 --- a/gui/mplayer/play.c +++ b/gui/mplayer/play.c @@ -26,6 +26,7 @@ #include "config.h" #include "help_mp.h" +#include "libmpcodecs/vd.h" #include "libvo/x11_common.h" #include "libvo/video_out.h" #include "input/input.h" diff --git a/libmpcodecs/vd.h b/libmpcodecs/vd.h index 33d9ec55f1..6c9593dd0a 100644 --- a/libmpcodecs/vd.h +++ b/libmpcodecs/vd.h @@ -38,8 +38,15 @@ typedef struct vd_functions_s // NULL terminated array of all drivers extern const vd_functions_t * const mpcodecs_vd_drivers[]; +extern int flip; +extern int fullscreen; +extern int opt_screen_size_x; +extern int opt_screen_size_y; +extern int softzoom; extern int vd_use_slices; +extern int vidmode; extern float movie_aspect; +extern float screen_size_xy; #define VDCTRL_QUERY_FORMAT 3 /* test for availabilty of a format */ #define VDCTRL_QUERY_MAX_PP_LEVEL 4 /* test for postprocessing support (max level) */ diff --git a/libmpcodecs/vf_ass.c b/libmpcodecs/vf_ass.c index 894ebba6c2..f2d3ebac08 100644 --- a/libmpcodecs/vf_ass.c +++ b/libmpcodecs/vf_ass.c @@ -34,6 +34,7 @@ #include "img_format.h" #include "mp_image.h" +#include "vd.h" #include "vf.h" #include "libvo/fastmemcpy.h" @@ -67,9 +68,6 @@ static const struct vf_priv_s { unsigned char* dirty_rows; } vf_priv_dflt; -extern int opt_screen_size_x; -extern int opt_screen_size_y; - extern ass_track_t* ass_track; extern float sub_delay; extern int sub_visibility; diff --git a/libmpcodecs/vf_crop.c b/libmpcodecs/vf_crop.c index 19935ce600..20b0228d82 100644 --- a/libmpcodecs/vf_crop.c +++ b/libmpcodecs/vf_crop.c @@ -26,6 +26,7 @@ #include "img_format.h" #include "mp_image.h" +#include "vd.h" #include "vf.h" #include "m_option.h" @@ -39,9 +40,6 @@ static const struct vf_priv_s { -1,-1 }; -extern int opt_screen_size_x; -extern int opt_screen_size_y; - //===========================================================================// static int config(struct vf_instance *vf, diff --git a/libmpcodecs/vf_expand.c b/libmpcodecs/vf_expand.c index 7232257394..963a2eb6a5 100644 --- a/libmpcodecs/vf_expand.c +++ b/libmpcodecs/vf_expand.c @@ -28,6 +28,7 @@ #include "img_format.h" #include "mp_image.h" +#include "vd.h" #include "vf.h" #include "libvo/fastmemcpy.h" @@ -70,9 +71,6 @@ static struct vf_priv_s { 0 }; -extern int opt_screen_size_x; -extern int opt_screen_size_y; - //===========================================================================// #ifdef OSD_SUPPORT diff --git a/libmpcodecs/vf_filmdint.c b/libmpcodecs/vf_filmdint.c index 784cf56a29..1838a197ca 100644 --- a/libmpcodecs/vf_filmdint.c +++ b/libmpcodecs/vf_filmdint.c @@ -27,6 +27,7 @@ #include "img_format.h" #include "mp_image.h" +#include "vd.h" #include "vf.h" #include "cmmx.h" @@ -97,9 +98,6 @@ struct vf_priv_s { static const struct frame_stats ppzs = {PPZ,PPZ,PPZ,PPZ,PPZ,PPZ,PPZ,0,0,9999}; static const struct frame_stats pprs = {PPR,PPR,PPR,PPR,PPR,PPR,PPR,0,0,9999}; -extern int opt_screen_size_x; -extern int opt_screen_size_y; - #ifndef MIN #define MIN(a,b) (((a)<(b))?(a):(b)) #endif diff --git a/libmpcodecs/vf_scale.c b/libmpcodecs/vf_scale.c index 523e9cb5a8..76c7634aa3 100644 --- a/libmpcodecs/vf_scale.c +++ b/libmpcodecs/vf_scale.c @@ -27,6 +27,7 @@ #include "img_format.h" #include "mp_image.h" +#include "vd.h" #include "vf.h" #include "fmt-conversion.h" #include "mpbswap.h" @@ -58,10 +59,6 @@ static struct vf_priv_s { NULL }; -extern int opt_screen_size_x; -extern int opt_screen_size_y; -extern float screen_size_xy; - //===========================================================================// void sws_getFlagsAndFilterFromCmdLine(int *flags, SwsFilter **srcFilterParam, SwsFilter **dstFilterParam); diff --git a/libvo/vo_directx.c b/libvo/vo_directx.c index af4a090493..014ee29d0e 100644 --- a/libvo/vo_directx.c +++ b/libvo/vo_directx.c @@ -31,6 +31,7 @@ #include "video_out_internal.h" #include "fastmemcpy.h" #include "input/input.h" +#include "libmpcodecs/vd.h" #include "osdep/keycodes.h" #include "input/mouse.h" #include "mp_msg.h" @@ -90,8 +91,6 @@ static float window_aspect; static BOOL (WINAPI* myGetMonitorInfo)(HMONITOR, LPMONITORINFO) = NULL; static RECT last_rect = {0xDEADC0DE, 0xDEADC0DE, 0xDEADC0DE, 0xDEADC0DE}; -extern int vidmode; - /***************************************************************************** * DirectDraw GUIDs. * Defining them here allows us to get rid of the dxguid library during