diff --git a/Common/ColorTable.cpp b/Common/ColorTable.cpp index 2eba886d7ca249474a789dfe663cfd91cbbe778b..f8b3f9f09830f686b9ad94b4cced4d2604e82cd2 100644 --- a/Common/ColorTable.cpp +++ b/Common/ColorTable.cpp @@ -1,4 +1,4 @@ -// $Id: ColorTable.cpp,v 1.24 2004-12-23 22:26:34 geuzaine Exp $ +// $Id: ColorTable.cpp,v 1.25 2004-12-24 04:58:20 geuzaine Exp $ // // Copyright (C) 1997-2004 C. Geuzaine, J.-F. Remacle // @@ -34,19 +34,16 @@ extern Context_T CTX; -void ColorTable_InitParam(int number, double alpha, GmshColorTable * ct) +void ColorTable_InitParam(int number, GmshColorTable * ct) { ct->size = 255; + for(int i = 0; i < COLORTABLE_NBMAX_PARAM; i++){ + ct->ipar[i] = 0; + ct->dpar[i] = 0.; + } ct->ipar[COLORTABLE_MODE] = COLORTABLE_RGB; ct->ipar[COLORTABLE_NUMBER] = number; - ct->ipar[COLORTABLE_INVERT] = 0; - ct->ipar[COLORTABLE_SWAP] = 0; - ct->ipar[COLORTABLE_ROTATE] = 0; - - ct->dpar[COLORTABLE_CURVE] = 0.0; - ct->dpar[COLORTABLE_BIAS] = 0.0; - ct->dpar[COLORTABLE_BETA] = 0.0; - ct->dpar[COLORTABLE_ALPHAVAL] = alpha; + ct->dpar[COLORTABLE_ALPHA] = 1.0; } static double gray(double s) @@ -76,24 +73,22 @@ static double cubic(double a, double b, double c, double d, double x) void ColorTable_Recompute(GmshColorTable * ct) { - double curve, bias, s, t, gamma; - int i, r, g, b, a, rotate; + double s, t, gamma; + int r, g, b, a; - ct->ipar[COLORTABLE_CHANGED] = 1; + double bias = ct->dpar[COLORTABLE_BIAS]; + double curvature = ct->dpar[COLORTABLE_CURVATURE]; + int rotation = ct->ipar[COLORTABLE_ROTATION]; - bias = ct->dpar[COLORTABLE_BIAS]; - curve = ct->dpar[COLORTABLE_CURVE]; - rotate = ct->ipar[COLORTABLE_ROTATE]; - - for(i = 0; i < ct->size; i++) { + for(int i = 0; i < ct->size; i++) { if(ct->size > 1) { - if(i + rotate < 0) - s = (double)(i + rotate + ct->size) / (double)(ct->size - 1); - else if(i + rotate > ct->size - 1) - s = (double)(i + rotate - ct->size) / (double)(ct->size - 1); + if(i + rotation < 0) + s = (double)(i + rotation + ct->size) / (double)(ct->size - 1); + else if(i + rotation > ct->size - 1) + s = (double)(i + rotation - ct->size) / (double)(ct->size - 1); else - s = (double)(i + rotate) / (double)(ct->size - 1); + s = (double)(i + rotation) / (double)(ct->size - 1); } else s = 0.; @@ -103,7 +98,7 @@ void ColorTable_Recompute(GmshColorTable * ct) switch (ct->ipar[COLORTABLE_NUMBER]) { case 1: // vis5d - t = (curve + 1.4) * (s - (1. + bias) / 2.); + t = (curvature + 1.4) * (s - (1. + bias) / 2.); r = (int)(128.0 + 127.0 * atan(7.0 * t) / 1.57); g = (int)(128.0 + 127.0 * (2 * exp(-7 * t * t) - 1)); b = (int)(128.0 + 127.0 * atan(-7.0 * t) / 1.57); @@ -166,30 +161,30 @@ void ColorTable_Recompute(GmshColorTable * ct) g = 0; b = 255; } - else if(s - bias <= 0.25 + curve) { - curve = (curve == -0.25) ? -0.26 : curve; + else if(s - bias <= 0.25 + curvature) { + curvature = (curvature == -0.25) ? -0.26 : curvature; r = 0; - g = (int)((s - bias) * (255. / (0.25 + curve))); + g = (int)((s - bias) * (255. / (0.25 + curvature))); b = 255; } else if(s - bias <= 0.50) { - curve = (curve == 0.25) ? 0.26 : curve; + curvature = (curvature == 0.25) ? 0.26 : curvature; r = 0; g = 255; b = - (int)(255. - (255. / (0.25 - curve)) * (s - bias - 0.25 - curve)); + (int)(255. - (255. / (0.25 - curvature)) * (s - bias - 0.25 - curvature)); } - else if(s - bias <= 0.75 - curve) { - curve = (curve == 0.25) ? 0.26 : curve; - r = (int)((s - bias - 0.5) * (255. / (0.25 - curve))); + else if(s - bias <= 0.75 - curvature) { + curvature = (curvature == 0.25) ? 0.26 : curvature; + r = (int)((s - bias - 0.5) * (255. / (0.25 - curvature))); g = 255; b = 0; } else if(s - bias <= 1.) { - curve = (curve == -0.25) ? -0.26 : curve; + curvature = (curvature == -0.25) ? -0.26 : curvature; r = 255; g = - (int)(255. - (255. / (0.25 + curve)) * (s - bias - 0.75 + curve)); + (int)(255. - (255. / (0.25 + curvature)) * (s - bias - 0.75 + curvature)); b = 0; } else { @@ -260,10 +255,10 @@ void ColorTable_Recompute(GmshColorTable * ct) r = g = b = 0; } else if(s - bias <= 1.) { - r = g = b = (int)(255 * (1. - curve) * (s - bias)); + r = g = b = (int)(255 * (1. - curvature) * (s - bias)); } else { - r = g = b = (int)(255 * (1. - curve)); + r = g = b = (int)(255 * (1. - curvature)); } break; case 0: // all black @@ -272,19 +267,13 @@ void ColorTable_Recompute(GmshColorTable * ct) break; } - a = (int)(255. * ct->dpar[COLORTABLE_ALPHAVAL]); + a = (int)(255. * ct->dpar[COLORTABLE_ALPHA]); - // clamp to [0,255] - r = r < 0 ? 0 : (r > 255 ? 255 : r); - g = g < 0 ? 0 : (g > 255 ? 255 : g); - b = b < 0 ? 0 : (b > 255 ? 255 : b); - a = a < 0 ? 0 : (a > 255 ? 255 : a); - if(ct->dpar[COLORTABLE_BETA]) { if(ct->dpar[COLORTABLE_BETA] > 0.0) gamma = 1. - ct->dpar[COLORTABLE_BETA]; else - gamma = 1. / (1.001 + ct->dpar[COLORTABLE_BETA]); // beta is thresholded to [-1,1] + gamma = 1. / (1.001 + ct->dpar[COLORTABLE_BETA]); // beta is thresholded to [-1,1] r = (int)(255. * pow((double)r / 255., gamma)); g = (int)(255. * pow((double)g / 255., gamma)); b = (int)(255. * pow((double)b / 255., gamma)); @@ -295,6 +284,12 @@ void ColorTable_Recompute(GmshColorTable * ct) g = 255 - g; b = 255 - b; } + + // clamp to [0,255] + r = r < 0 ? 0 : (r > 255 ? 255 : r); + g = g < 0 ? 0 : (g > 255 ? 255 : g); + b = b < 0 ? 0 : (b > 255 ? 255 : b); + a = a < 0 ? 0 : (a > 255 ? 255 : a); ct->table[i] = PACK_COLOR(r, g, b, a); } diff --git a/Common/ColorTable.h b/Common/ColorTable.h index 1d7224fbd78a99a1021253be756bb9b14020c2b0..8a75deb671de1428d542f2b9a2844359efeccbd6 100644 --- a/Common/ColorTable.h +++ b/Common/ColorTable.h @@ -38,20 +38,19 @@ typedef struct{ // integrer parameters indices #define COLORTABLE_NUMBER 0 // predefined curve index -#define COLORTABLE_CHANGED 1 // did the colortable change ? -#define COLORTABLE_INVERT 2 // invert (rbg<->255-rgb) -#define COLORTABLE_SWAP 3 // swap (min<->max) -#define COLORTABLE_ROTATE 4 // rotate -#define COLORTABLE_MODE 5 // mode (rgb, hsv) +#define COLORTABLE_INVERT 1 // invert (rbg<->255-rgb) +#define COLORTABLE_SWAP 2 // swap (min<->max) +#define COLORTABLE_ROTATION 3 // rotation +#define COLORTABLE_MODE 4 // mode (rgb, hsv) // double parameters indices -#define COLORTABLE_CURVE 0 // curvature +#define COLORTABLE_CURVATURE 0 // curvature #define COLORTABLE_BIAS 1 // offset -#define COLORTABLE_ALPHAVAL 2 // alpha channel value +#define COLORTABLE_ALPHA 2 // alpha channel value #define COLORTABLE_BETA 3 // beta coeff for brighten -void ColorTable_InitParam(int number, double alpha, GmshColorTable *ct); +void ColorTable_InitParam(int number, GmshColorTable *ct); void ColorTable_Recompute(GmshColorTable *ct); void ColorTable_Copy(GmshColorTable *ct); void ColorTable_Paste(GmshColorTable *ct); diff --git a/Common/DefaultOptions.h b/Common/DefaultOptions.h index a9308e27ed93fa16cb6dcee3c5da54c0bd2bfbe3..3abf38c9d82e88412a40d95d35839a96abf81b05 100644 --- a/Common/DefaultOptions.h +++ b/Common/DefaultOptions.h @@ -983,8 +983,6 @@ StringXNumber PostProcessingOptions_Number[] = { } ; StringXNumber ViewOptions_Number[] = { - { F|O, "AlphaChannel" , opt_view_alpha_channel , 1.0 , - "Global alpha channel value (used only if != 1)" }, { F|O, "AngleSmoothNormals" , opt_view_angle_smooth_normals , 180. , "Threshold angle below which normals are not smoothed" }, { F|O, "ArrowHeadRadius" , opt_view_arrow_head_radius , 0.12 , @@ -1005,8 +1003,23 @@ StringXNumber ViewOptions_Number[] = { { F|O, "Boundary" , opt_view_boundary , 0. , "Draw the `N minus b'-dimensional boundary of the simplex (N=simplex dimension, b=option value)" }, - { F|O, "Colormap" , opt_view_default_colormap , 1. , + { F|O, "ColormapAlpha" , opt_view_colormap_alpha , 1.0 , + "Colormap alpha channel value (used only if != 1)" }, + { F|O, "ColormapBeta" , opt_view_colormap_beta , 0.0 , + "Colormap beta parameter (gamma = 1-beta)" }, + { F|O, "ColormapBias" , opt_view_colormap_bias , 0.0 , + "Colormap bias" }, + { F|O, "ColormapCurvature" , opt_view_colormap_curvature , 0.0 , + "Colormap curvature or slope coeficient" }, + { F|O, "ColormapInvert" , opt_view_colormap_invert , 0. , + "Invert the color values, i.e., replace x with (255-x) in the colormap?" }, + { F|O, "ColormapNumber" , opt_view_colormap_number , 1. , "Default colormap number" }, + { F|O, "ColormapRotation" , opt_view_colormap_rotation , 0. , + "Incremental colormap rotation" }, + { F|O, "ColormapSwap" , opt_view_colormap_swap , 0. , + "Swap the min/max values in the colormap?" }, + { F, "CustomMax" , opt_view_custom_max , 0. , "User-defined maximum value to be displayed" }, { F, "CustomMin" , opt_view_custom_min , 0. , diff --git a/Common/Options.cpp b/Common/Options.cpp index d548ddb54cb0be4473190069230bd9aab61bfefd..b844e4682d540cd9ac6c0da835c96d195adeb8b8 100644 --- a/Common/Options.cpp +++ b/Common/Options.cpp @@ -1,4 +1,4 @@ -// $Id: Options.cpp,v 1.213 2004-12-24 03:25:36 geuzaine Exp $ +// $Id: Options.cpp,v 1.214 2004-12-24 04:58:20 geuzaine Exp $ // // Copyright (C) 1997-2004 C. Geuzaine, J.-F. Remacle // @@ -42,7 +42,7 @@ extern Post_View *Post_ViewReference; void Init_Options_Safe(int num) { - ColorTable_InitParam(1, 1., &Post_ViewReference->CT); + ColorTable_InitParam(1, &Post_ViewReference->CT); ColorTable_Recompute(&Post_ViewReference->CT); // Default string options @@ -5402,28 +5402,134 @@ double opt_view_line_type(OPT_ARGS_NUM) return v->LineType; } -double opt_view_alpha_channel(OPT_ARGS_NUM) +double opt_view_colormap_alpha(OPT_ARGS_NUM) { GET_VIEW(0.); if(action & GMSH_SET) { - ColorTable_InitParam(v->CT.ipar[COLORTABLE_NUMBER], val, &v->CT); + v->CT.dpar[COLORTABLE_ALPHA] = val; ColorTable_Recompute(&v->CT); v->Changed = 1; } - return v->CT.dpar[COLORTABLE_ALPHAVAL]; +#if defined(HAVE_FLTK) + if(_gui_action_valid(action, num)) { + WID->view_colorbar_window->redraw(); + } +#endif + return v->CT.dpar[COLORTABLE_ALPHA]; +} + +double opt_view_colormap_beta(OPT_ARGS_NUM) +{ + GET_VIEW(0.); + if(action & GMSH_SET) { + v->CT.dpar[COLORTABLE_BETA] = val; + ColorTable_Recompute(&v->CT); + v->Changed = 1; + } +#if defined(HAVE_FLTK) + if(_gui_action_valid(action, num)) { + WID->view_colorbar_window->redraw(); + } +#endif + return v->CT.dpar[COLORTABLE_BETA]; +} + +double opt_view_colormap_bias(OPT_ARGS_NUM) +{ + GET_VIEW(0.); + if(action & GMSH_SET) { + v->CT.dpar[COLORTABLE_BIAS] = val; + ColorTable_Recompute(&v->CT); + v->Changed = 1; + } +#if defined(HAVE_FLTK) + if(_gui_action_valid(action, num)) { + WID->view_colorbar_window->redraw(); + } +#endif + return v->CT.dpar[COLORTABLE_BIAS]; +} + +double opt_view_colormap_curvature(OPT_ARGS_NUM) +{ + GET_VIEW(0.); + if(action & GMSH_SET) { + v->CT.dpar[COLORTABLE_CURVATURE] = val; + ColorTable_Recompute(&v->CT); + v->Changed = 1; + } +#if defined(HAVE_FLTK) + if(_gui_action_valid(action, num)) { + WID->view_colorbar_window->redraw(); + } +#endif + return v->CT.dpar[COLORTABLE_CURVATURE]; } -double opt_view_default_colormap(OPT_ARGS_NUM) +double opt_view_colormap_invert(OPT_ARGS_NUM) { GET_VIEW(0.); if(action & GMSH_SET) { - ColorTable_InitParam((int)val, v->CT.dpar[COLORTABLE_ALPHAVAL], &v->CT); + v->CT.ipar[COLORTABLE_INVERT] = (int)val; ColorTable_Recompute(&v->CT); v->Changed = 1; } +#if defined(HAVE_FLTK) + if(_gui_action_valid(action, num)) { + WID->view_colorbar_window->redraw(); + } +#endif + return v->CT.ipar[COLORTABLE_INVERT]; +} + +double opt_view_colormap_number(OPT_ARGS_NUM) +{ + GET_VIEW(0.); + if(action & GMSH_SET) { + v->CT.ipar[COLORTABLE_NUMBER] = (int)val; + ColorTable_Recompute(&v->CT); + v->Changed = 1; + } +#if defined(HAVE_FLTK) + if(_gui_action_valid(action, num)) { + WID->view_colorbar_window->redraw(); + } +#endif return v->CT.ipar[COLORTABLE_NUMBER]; } +double opt_view_colormap_rotation(OPT_ARGS_NUM) +{ + GET_VIEW(0.); + if(action & GMSH_SET) { + v->CT.ipar[COLORTABLE_ROTATION] = (int)val; + ColorTable_Recompute(&v->CT); + v->Changed = 1; + } +#if defined(HAVE_FLTK) + if(_gui_action_valid(action, num)) { + WID->view_colorbar_window->redraw(); + } +#endif + return v->CT.ipar[COLORTABLE_ROTATION]; +} + +double opt_view_colormap_swap(OPT_ARGS_NUM) +{ + GET_VIEW(0.); + if(action & GMSH_SET) { + v->CT.ipar[COLORTABLE_SWAP] = (int)val; + ColorTable_Recompute(&v->CT); + v->Changed = 1; + } +#if defined(HAVE_FLTK) + if(_gui_action_valid(action, num)) { + WID->view_colorbar_window->redraw(); + } +#endif + return v->CT.ipar[COLORTABLE_SWAP]; +} + double opt_view_external_view(OPT_ARGS_NUM) { GET_VIEW(0.); diff --git a/Common/Options.h b/Common/Options.h index 41eb7c04266edd02eea7d1e11cfe1fd31f8e6cfe..c06cc088227e92e1699032c8a3d049239bb3338d 100644 --- a/Common/Options.h +++ b/Common/Options.h @@ -483,8 +483,14 @@ double opt_view_intervals_type(OPT_ARGS_NUM); double opt_view_saturate_values(OPT_ARGS_NUM); double opt_view_max_recursion_level(OPT_ARGS_NUM); double opt_view_target_error(OPT_ARGS_NUM); -double opt_view_alpha_channel(OPT_ARGS_NUM); -double opt_view_default_colormap(OPT_ARGS_NUM); +double opt_view_colormap_alpha(OPT_ARGS_NUM); +double opt_view_colormap_beta(OPT_ARGS_NUM); +double opt_view_colormap_bias(OPT_ARGS_NUM); +double opt_view_colormap_curvature(OPT_ARGS_NUM); +double opt_view_colormap_invert(OPT_ARGS_NUM); +double opt_view_colormap_number(OPT_ARGS_NUM); +double opt_view_colormap_rotation(OPT_ARGS_NUM); +double opt_view_colormap_swap(OPT_ARGS_NUM); double opt_view_external_view(OPT_ARGS_NUM); double opt_view_gen_raise_view(OPT_ARGS_NUM); double opt_view_gen_raise_factor(OPT_ARGS_NUM); diff --git a/Common/Views.cpp b/Common/Views.cpp index c2c79816b9070a9dbf3e7bafafff2e3b19eb1cc3..294d1743799381670e08d094eff1731b373b3521 100644 --- a/Common/Views.cpp +++ b/Common/Views.cpp @@ -1,4 +1,4 @@ -// $Id: Views.cpp,v 1.150 2004-12-23 22:26:34 geuzaine Exp $ +// $Id: Views.cpp,v 1.151 2004-12-24 04:58:20 geuzaine Exp $ // // Copyright (C) 1997-2004 C. Geuzaine, J.-F. Remacle // @@ -699,10 +699,13 @@ void Print_ColorTable(int num, int diff, char *prefix, FILE * file) if(diff){ // compare the current colormap with a vanilla colormap having the - // same index number + // parameters GmshColorTable ref; - ColorTable_InitParam(v->CT.ipar[COLORTABLE_NUMBER], - v->CT.dpar[COLORTABLE_ALPHAVAL], &ref); + ColorTable_InitParam(v->CT.ipar[COLORTABLE_NUMBER], &ref); + for(int i = 0; i < COLORTABLE_NBMAX_PARAM; i++){ + ref.ipar[i] = v->CT.ipar[i]; + ref.dpar[i] = v->CT.dpar[i]; + } ColorTable_Recompute(&ref); if(!ColorTable_Diff(&ref, &v->CT)) return; diff --git a/Fltk/Colorbar_Window.cpp b/Fltk/Colorbar_Window.cpp index 9b45892b0abc00cebbfef9477adfe64fe9e2788e..56d7b9e19e9c5306d1c7e5a64f31529e12f150b0 100644 --- a/Fltk/Colorbar_Window.cpp +++ b/Fltk/Colorbar_Window.cpp @@ -1,4 +1,4 @@ -// $Id: Colorbar_Window.cpp,v 1.39 2004-12-23 22:26:34 geuzaine Exp $ +// $Id: Colorbar_Window.cpp,v 1.40 2004-12-24 04:58:20 geuzaine Exp $ // // Copyright (C) 1997-2004 C. Geuzaine, J.-F. Remacle // @@ -422,43 +422,43 @@ int Colorbar_Window::handle(int event) case FL_SHORTCUT: case FL_KEYBOARD: if(Fl::test_shortcut('0')) { - ColorTable_InitParam(0, 1., ct); + ColorTable_InitParam(0, ct); compute = 1; } else if(Fl::test_shortcut('1')) { - ColorTable_InitParam(1, 1., ct); + ColorTable_InitParam(1, ct); compute = 1; } else if(Fl::test_shortcut('2')) { - ColorTable_InitParam(2, 1., ct); + ColorTable_InitParam(2, ct); compute = 1; } else if(Fl::test_shortcut('3')) { - ColorTable_InitParam(3, 1., ct); + ColorTable_InitParam(3, ct); compute = 1; } else if(Fl::test_shortcut('4')) { - ColorTable_InitParam(4, 1., ct); + ColorTable_InitParam(4, ct); compute = 1; } else if(Fl::test_shortcut('5')) { - ColorTable_InitParam(5, 1., ct); + ColorTable_InitParam(5, ct); compute = 1; } else if(Fl::test_shortcut('6')) { - ColorTable_InitParam(6, 1., ct); + ColorTable_InitParam(6, ct); compute = 1; } else if(Fl::test_shortcut('7')) { - ColorTable_InitParam(7, 1., ct); + ColorTable_InitParam(7, ct); compute = 1; } else if(Fl::test_shortcut('8')) { - ColorTable_InitParam(8, 1., ct); + ColorTable_InitParam(8, ct); compute = 1; } else if(Fl::test_shortcut('9')) { - ColorTable_InitParam(9, 1., ct); + ColorTable_InitParam(9, ct); compute = 1; } else if(Fl::test_shortcut('c')) { @@ -473,7 +473,7 @@ int Colorbar_Window::handle(int event) draw(); } else if(Fl::test_shortcut('r')) { - ColorTable_InitParam(ct->ipar[COLORTABLE_NUMBER], 1., ct); + ColorTable_InitParam(ct->ipar[COLORTABLE_NUMBER], ct); compute = 1; } else if(Fl::test_shortcut('m')) { @@ -504,15 +504,15 @@ int Colorbar_Window::handle(int event) compute = 1; } else if(Fl::test_shortcut('a')) { - ct->dpar[COLORTABLE_ALPHAVAL] -= 0.05; - if(ct->dpar[COLORTABLE_ALPHAVAL] < 0.0) - ct->dpar[COLORTABLE_ALPHAVAL] = 0.0; + ct->dpar[COLORTABLE_ALPHA] -= 0.05; + if(ct->dpar[COLORTABLE_ALPHA] < 0.0) + ct->dpar[COLORTABLE_ALPHA] = 0.0; compute = 1; } else if(Fl::test_shortcut(FL_CTRL + 'a')) { - ct->dpar[COLORTABLE_ALPHAVAL] += 0.05; - if(ct->dpar[COLORTABLE_ALPHAVAL] > 1.0) - ct->dpar[COLORTABLE_ALPHAVAL] = 1.0; + ct->dpar[COLORTABLE_ALPHA] += 0.05; + if(ct->dpar[COLORTABLE_ALPHA] > 1.0) + ct->dpar[COLORTABLE_ALPHA] = 1.0; compute = 1; } else if(Fl::test_shortcut(FL_Left)) { @@ -520,9 +520,9 @@ int Colorbar_Window::handle(int event) compute = 1; } else if(Fl::test_shortcut(FL_CTRL + FL_Left)) { - ct->ipar[COLORTABLE_ROTATE] += 5; - if(ct->ipar[COLORTABLE_ROTATE] > ct->size - 1) - ct->ipar[COLORTABLE_ROTATE] -= ct->size - 1; + ct->ipar[COLORTABLE_ROTATION] += 5; + if(ct->ipar[COLORTABLE_ROTATION] > ct->size - 1) + ct->ipar[COLORTABLE_ROTATION] -= ct->size - 1; compute = 1; } else if(Fl::test_shortcut(FL_Right)) { @@ -530,17 +530,17 @@ int Colorbar_Window::handle(int event) compute = 1; } else if(Fl::test_shortcut(FL_CTRL + FL_Right)) { - ct->ipar[COLORTABLE_ROTATE] -= 5; - if(ct->ipar[COLORTABLE_ROTATE] < -(ct->size - 1)) - ct->ipar[COLORTABLE_ROTATE] += ct->size - 1; + ct->ipar[COLORTABLE_ROTATION] -= 5; + if(ct->ipar[COLORTABLE_ROTATION] < -(ct->size - 1)) + ct->ipar[COLORTABLE_ROTATION] += ct->size - 1; compute = 1; } else if(Fl::test_shortcut(FL_Up)) { - ct->dpar[COLORTABLE_CURVE] -= 0.05; + ct->dpar[COLORTABLE_CURVATURE] -= 0.05; compute = 1; } else if(Fl::test_shortcut(FL_Down)) { - ct->dpar[COLORTABLE_CURVE] += 0.05; + ct->dpar[COLORTABLE_CURVATURE] += 0.05; compute = 1; } else { diff --git a/doc/texinfo/opt_general.texi b/doc/texinfo/opt_general.texi index 19e65f0cd86d7e938bd1a46238c5ebf90cbf9f19..7ae2e483ac17ea1b2c0b4d8ca6b034de545692fe 100644 --- a/doc/texinfo/opt_general.texi +++ b/doc/texinfo/opt_general.texi @@ -720,8 +720,8 @@ Default value: @code{150}@* Saved in: @code{General.SessionFileName} @item General.ZoomFactor -`Speed' of the middle mouse button zoom@* -Default value: @code{1.1}@* +Middle mouse button zoom acceleration factor@* +Default value: @code{4}@* Saved in: @code{General.OptionsFileName} @item General.Color.Background diff --git a/doc/texinfo/opt_view.texi b/doc/texinfo/opt_view.texi index 1cbdca31345c018aacacf8a6518d9a39ea320d9e..ecb6dfa762f3515536055f22e375c7b033978cf6 100644 --- a/doc/texinfo/opt_view.texi +++ b/doc/texinfo/opt_view.texi @@ -39,11 +39,6 @@ Default post-processing view name@* Default value: @code{""}@* Saved in: @code{-} -@item View.AlphaChannel -Global alpha channel value (used only if != 1)@* -Default value: @code{1}@* -Saved in: @code{General.OptionsFileName} - @item View.AngleSmoothNormals Threshold angle below which normals are not smoothed@* Default value: @code{180}@* @@ -89,6 +84,46 @@ Draw the `N minus b'-dimensional boundary of the simplex (N=simplex dimension, b Default value: @code{0}@* Saved in: @code{General.OptionsFileName} +@item View.ColormapAlpha +Colormap alpha channel value (used only if != 1)@* +Default value: @code{1}@* +Saved in: @code{General.OptionsFileName} + +@item View.ColormapBeta +Colormap beta parameter (gamma = 1-beta)@* +Default value: @code{0}@* +Saved in: @code{General.OptionsFileName} + +@item View.ColormapBias +Colormap bias@* +Default value: @code{0}@* +Saved in: @code{General.OptionsFileName} + +@item View.ColormapCurvature +Colormap curvature or slope coeficient@* +Default value: @code{0}@* +Saved in: @code{General.OptionsFileName} + +@item View.ColormapInvert +Invert the color values, i.e., replace x with (255-x) in the colormap?@* +Default value: @code{0}@* +Saved in: @code{General.OptionsFileName} + +@item View.ColormapNumber +Default colormap number@* +Default value: @code{1}@* +Saved in: @code{General.OptionsFileName} + +@item View.ColormapRotation +Incremental colormap rotation@* +Default value: @code{0}@* +Saved in: @code{General.OptionsFileName} + +@item View.ColormapSwap +Swap the min/max values in the colormap?@* +Default value: @code{0}@* +Saved in: @code{General.OptionsFileName} + @item View.CustomMax User-defined maximum value to be displayed@* Default value: @code{0}@*