diff options
author | wm4 <wm4@nowhere> | 2013-12-04 01:51:27 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2013-12-04 01:51:27 +0100 |
commit | 0c2a0a67b611ee87280bbdd8dc7e5f8179a97f56 (patch) | |
tree | 1f0b2d537b4620b6f5c232ab9ab4f838eb375f95 /video | |
parent | 05ba5a08d27a96b57a12f272c702564ac2722ac6 (diff) | |
download | mpv-0c2a0a67b611ee87280bbdd8dc7e5f8179a97f56.tar.bz2 mpv-0c2a0a67b611ee87280bbdd8dc7e5f8179a97f56.tar.xz |
vf_eq: revert unintended binary size increase
The vf_eq context contains a very large lookup table, and the method of
setting default values caused the vf_eq context to be included in the
compiled code.
Diffstat (limited to 'video')
-rw-r--r-- | video/filter/vf_eq.c | 23 |
1 files changed, 10 insertions, 13 deletions
diff --git a/video/filter/vf_eq.c b/video/filter/vf_eq.c index c61c8f249b..a8341a64a0 100644 --- a/video/filter/vf_eq.c +++ b/video/filter/vf_eq.c @@ -506,20 +506,17 @@ const vf_info_t vf_info_eq = { .name = "eq", .open = &vf_open, .priv_size = sizeof(struct vf_priv_s), - .priv_defaults = &(const struct vf_priv_s){ - .par = {1.0, 1.0, 0.0, 1.0, 1.0, 1.0, 1.0, 1.0}, - }, .options = (const struct m_option[]){ -#define PARAM(name, n, min_, max_) \ - OPT_DOUBLE(name, par[n], CONF_RANGE, .min = min_, .max = max_) - PARAM("gamma", 0, 0.1, 10), - PARAM("contrast", 1, -2, 2), - PARAM("brightness", 2, -1, 1), - PARAM("saturation", 3, 0, 3), - PARAM("rg", 4, 0.1, 10), - PARAM("gg", 5, 0.1, 10), - PARAM("bg", 6, 0.1, 10), - PARAM("weight", 7, 0, 1), +#define PARAM(name, n, def, min_, max_) \ + OPT_DOUBLE(name, par[n], CONF_RANGE, .min = min_, .max = max_, OPTDEF_DOUBLE(def)) + PARAM("gamma", 0, 1.0, 0.1, 10), + PARAM("contrast", 1, 1.0, -2, 2), + PARAM("brightness", 2, 0.0, -1, 1), + PARAM("saturation", 3, 1.0, 0, 3), + PARAM("rg", 4, 1.0, 0.1, 10), + PARAM("gg", 5, 1.0, 0.1, 10), + PARAM("bg", 6, 1.0, 0.1, 10), + PARAM("weight", 7, 1.0, 0, 1), {0} }, }; |