From 356a1d6958810ca98dbb433af9afb13cf916091b Mon Sep 17 00:00:00 2001 From: dooglus Date: Tue, 25 Sep 2007 09:13:23 +0000 Subject: [PATCH] Move the gamma_in and gamma_out macros into "color.h". git-svn-id: http://svn.voria.com/code@751 1f10aa63-cdf2-0310-b900-c93c546f37ac --- synfig-core/trunk/src/synfig/color.h | 5 +++++ synfig-studio/trunk/src/gtkmm/dock_info.cpp | 4 ---- synfig-studio/trunk/src/gtkmm/widget_coloredit.cpp | 5 ----- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/synfig-core/trunk/src/synfig/color.h b/synfig-core/trunk/src/synfig/color.h index a5455c1..35e2857 100644 --- a/synfig-core/trunk/src/synfig/color.h +++ b/synfig-core/trunk/src/synfig/color.h @@ -44,6 +44,11 @@ /* === M A C R O S ========================================================= */ +#define use_colorspace_gamma() App::use_colorspace_gamma +#define colorspace_gamma() (2.2f) +#define gamma_in(x) ((x>=0)?pow((float)x,1.0f/colorspace_gamma()):-pow((float)-x,1.0f/colorspace_gamma())) +#define gamma_out(x) ((x>=0)?pow((float)x,colorspace_gamma()):-pow((float)-x,colorspace_gamma())) + #ifdef WIN32 #include #ifndef isnan diff --git a/synfig-studio/trunk/src/gtkmm/dock_info.cpp b/synfig-studio/trunk/src/gtkmm/dock_info.cpp index 5bd393e..0c7f073 100644 --- a/synfig-studio/trunk/src/gtkmm/dock_info.cpp +++ b/synfig-studio/trunk/src/gtkmm/dock_info.cpp @@ -48,10 +48,6 @@ using namespace etl; using namespace synfig; /* === M A C R O S ========================================================= */ -#define use_colorspace_gamma() App::use_colorspace_gamma -#define colorspace_gamma() (2.2f) -#define gamma_in(x) ((x>=0)?pow((float)x,1.0f/colorspace_gamma()):-pow((float)-x,1.0f/colorspace_gamma())) -#define gamma_out(x) ((x>=0)?pow((float)x,colorspace_gamma()):-pow((float)-x,colorspace_gamma())) /* === G L O B A L S ======================================================= */ diff --git a/synfig-studio/trunk/src/gtkmm/widget_coloredit.cpp b/synfig-studio/trunk/src/gtkmm/widget_coloredit.cpp index ac85260..37d4523 100644 --- a/synfig-studio/trunk/src/gtkmm/widget_coloredit.cpp +++ b/synfig-studio/trunk/src/gtkmm/widget_coloredit.cpp @@ -50,11 +50,6 @@ using namespace studio; /* === M A C R O S ========================================================= */ -#define use_colorspace_gamma() App::use_colorspace_gamma -#define colorspace_gamma() (2.2f) -#define gamma_in(x) ((x>=0)?pow((float)x,1.0f/colorspace_gamma()):-pow((float)-x,1.0f/colorspace_gamma())) -#define gamma_out(x) ((x>=0)?pow((float)x,colorspace_gamma()):-pow((float)-x,colorspace_gamma())) - /* === G L O B A L S ======================================================= */ /* === P R O C E D U R E S ================================================= */ -- 2.7.4