fixed up idle handler for file open (look like testgtk idle demo)

* app/app_procs.c: fixed up idle handler for file open (look like testgtk
idle demo)

* app/colomaps.c: fixup for visual test and use of gdk_color_alloc for some
fixed colors (from Owen Taylor)

* app/errors.h
* app/errors.c
* app/main.c
* libgimp/gimp.c: redid the signal handlers so we only get a debug prompt on
SIGSEGV, SIGBUS, and SIGFPE.

* applied gimp-jbuhler-980408-0 and gimp-joke-980409-0 (warning fixups)

* applied gimp-monnaux-980409-0 for configurable plugin path for multiarch
setups

-Yosh
This commit is contained in:
Manish Singh 1998-04-11 05:07:52 +00:00
parent 34582db809
commit 0ed0191962
53 changed files with 478 additions and 172 deletions

View File

@ -1,3 +1,23 @@
Fri Apr 10 21:59:18 PDT 1998 Manish Singh <yosh@gimp.org>
* app/app_procs.c: fixed up idle handler for file open
(look like testgtk idle demo)
* app/colomaps.c: fixup for visual test and use of gdk_color_alloc
for some fixed colors (from Owen Taylor)
* app/errors.h
* app/errors.c
* app/main.c
* libgimp/gimp.c: redid the signal handlers so we only get a
debug prompt on SIGSEGV, SIGBUS, and SIGFPE.
* applied gimp-jbuhler-980408-0 and gimp-joke-980409-0 (warning
fixups)
* applied gimp-monnaux-980409-0 for configurable plugin path for
multiarch setups
Fri Apr 10 00:17:23 EDT 1998 Matthew Wilson <msw@gimp.org>
* app/commands.c: Fixed (hopefully) the preferences code. Added

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -110,7 +110,7 @@ static ProcRecord quit_proc =
Thanks to Owen for this.
*/
GtkFunction file_open_wrapper (char *name) {
gint file_open_wrapper (char *name) {
file_open (name, name);
return FALSE;
}
@ -127,7 +127,7 @@ gimp_init (int gimp_argc,
while (gimp_argc--)
{
if (*gimp_argv)
gtk_idle_add ((GtkFunction *) file_open_wrapper, *gimp_argv);
gtk_idle_add ((GtkFunction) file_open_wrapper, *gimp_argv);
gimp_argv++;
}

View File

@ -65,39 +65,40 @@ gulong *g_lookup_blue;
gulong *color_pixel_vals;
gulong *gray_pixel_vals;
static int reserved_entries = 10; /* extra colors aside from color cube */
static int reserved_entries = 4; /* extra colors aside from color cube */
static gulong *reserved_pixels;
static void make_color (gulong *pixel_ptr,
int red,
int green,
int blue,
int readwrite);
static void
set_app_colors ()
{
int i;
if (g_visual->depth == 8)
if ((g_visual->type == GDK_VISUAL_PSEUDO_COLOR) ||
(g_visual->type == GDK_VISUAL_GRAYSCALE))
{
g_black_pixel = reserved_pixels[0];
g_gray_pixel = reserved_pixels[1];
g_white_pixel = reserved_pixels[2];
g_color_pixel = reserved_pixels[3];
g_normal_guide_pixel = reserved_pixels[4];
g_active_guide_pixel = reserved_pixels[5];
foreground_pixel = reserved_pixels[6];
background_pixel = reserved_pixels[7];
old_color_pixel = reserved_pixels[8];
new_color_pixel = reserved_pixels[9];
foreground_pixel = reserved_pixels[0];
background_pixel = reserved_pixels[1];
old_color_pixel = reserved_pixels[2];
new_color_pixel = reserved_pixels[3];
}
else
{
cycled_marching_ants = FALSE;
}
store_color (&g_black_pixel, 0, 0, 0);
store_color (&g_gray_pixel, 127, 127, 127);
store_color (&g_white_pixel, 255, 255, 255);
store_color (&g_color_pixel, 255, 255, 0);
store_color (&g_normal_guide_pixel, 0, 127, 255);
store_color (&g_active_guide_pixel, 255, 0, 0);
make_color (&g_black_pixel, 0, 0, 0, FALSE);
make_color (&g_gray_pixel, 127, 127, 127, FALSE);
make_color (&g_white_pixel, 255, 255, 255, FALSE);
make_color (&g_color_pixel, 255, 255, 0, FALSE);
make_color (&g_normal_guide_pixel, 0, 127, 255, FALSE);
make_color (&g_active_guide_pixel, 255, 0, 0, FALSE);
store_color (&foreground_pixel, 0, 0, 0);
store_color (&background_pixel, 255, 255, 255);
store_color (&old_color_pixel, 0, 0, 0);
@ -145,7 +146,8 @@ get_color (int red,
{
gulong pixel;
if (g_visual->depth == 8)
if ((g_visual->type == GDK_VISUAL_PSEUDO_COLOR) ||
(g_visual->type == GDK_VISUAL_GRAYSCALE))
pixel = color_pixel_vals [(red_ordered_dither[red].s[1] +
green_ordered_dither[green].s[1] +
blue_ordered_dither[blue].s[1])];
@ -156,11 +158,12 @@ get_color (int red,
}
void
store_color (gulong *pixel_ptr,
int red,
int green,
int blue)
static void
make_color (gulong *pixel_ptr,
int red,
int green,
int blue,
int readwrite)
{
GdkColor col;
@ -173,7 +176,8 @@ store_color (gulong *pixel_ptr,
col.blue = blue * (65535 / 255);
col.pixel = *pixel_ptr;
if (g_visual->depth == 8)
if (readwrite && ((g_visual->type == GDK_VISUAL_PSEUDO_COLOR) ||
(g_visual->type == GDK_VISUAL_GRAYSCALE)))
gdk_color_change (g_cmap, &col);
else
gdk_color_alloc (g_cmap, &col);
@ -181,6 +185,15 @@ store_color (gulong *pixel_ptr,
*pixel_ptr = col.pixel;
}
void
store_color (gulong *pixel_ptr,
int red,
int green,
int blue)
{
make_color (pixel_ptr, red, green, blue, TRUE);
}
void
get_standard_colormaps ()
@ -205,7 +218,9 @@ get_standard_colormaps ()
info = gtk_preview_get_info ();
g_visual = info->visual;
if (g_visual->depth == 8 && info->reserved_pixels == NULL) {
if (((g_visual->type == GDK_VISUAL_PSEUDO_COLOR) ||
(g_visual->type == GDK_VISUAL_GRAYSCALE)) &&
info->reserved_pixels == NULL) {
g_print("GIMP cannot get enough colormaps to boot.\n");
g_print("Try exiting other color intensive applications.\n");
g_print("Also try enabling the (install-colormap) option in gimprc.\n");

View File

@ -68,3 +68,17 @@ fatal_error (char *fmt, ...)
g_debug (prog_name);
app_exit (1);
}
void
terminate (char *fmt, ...)
{
va_list args;
va_start (args, fmt);
printf ("%s terminated: ", prog_name);
vprintf (fmt, args);
printf ("\n");
va_end (args);
gdk_exit (1);
}

View File

@ -21,5 +21,6 @@
void message (char *, ...);
void warning (char *, ...);
void fatal_error (char *, ...);
void terminate (char *, ...);
#endif /* __ERRORS_H__ */

View File

@ -2632,12 +2632,14 @@ gimage_dirty (GImage *gimage)
gimage->dirty ++;
if (active_tool && !active_tool->preserve) {
gdisp = active_tool->gdisp_ptr;
if (gdisp)
if (gdisp) {
if (gdisp->gimage->ID == gimage->ID)
tools_initialize (active_tool->type, gdisp);
else
tools_initialize (active_tool->type, NULL);
}
}
return gimage->dirty;
}

View File

@ -84,6 +84,7 @@ char * palette_path = NULL;
char * default_palette = NULL;
char * gradient_path = NULL;
char * default_gradient = NULL;
char * pluginrc_path = NULL;
int tile_cache_size = 4194304; /* 4 MB */
int marching_speed = 150; /* 150 ms */
double gamma_val = 1.0;
@ -176,6 +177,7 @@ static ParseFunc funcs[] =
{ "plug-in-path", TT_PATH, &plug_in_path, NULL },
{ "palette-path", TT_PATH, &palette_path, NULL },
{ "gradient-path", TT_PATH, &gradient_path, NULL },
{ "pluginrc-path", TT_PATH, &pluginrc_path, NULL },
{ "default-brush", TT_STRING, &default_brush, NULL },
{ "default-pattern", TT_STRING, &default_pattern, NULL },
{ "default-palette", TT_STRING, &default_palette, NULL },

View File

@ -33,6 +33,7 @@ extern char * palette_path;
extern char * default_palette;
extern char * gradient_path;
extern char * default_gradient;
extern char * pluginrc_path;
extern int tile_cache_size;
extern int marching_speed;
extern double gamma_val;

View File

@ -92,7 +92,7 @@ static void palette_close_callback (GtkWidget *, gpointer);
static gint palette_dialog_delete_callback (GtkWidget *, GdkEvent *, gpointer);
static void palette_new_entries_callback (GtkWidget *, gpointer);
static void palette_add_entries_callback (GtkWidget *, gpointer, gpointer);
static void palette_merge_entries_callback (GtkWidget *, gpointer);
/* static void palette_merge_entries_callback (GtkWidget *, gpointer); */
static void palette_delete_entries_callback (GtkWidget *, gpointer);
static void palette_select_callback (int, int, int, ColorSelectState, void *);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -232,8 +232,6 @@ static int caught_fatal_sig = 0;
static RETSIGTYPE
on_signal (int sig_num)
{
char *sig;
if (caught_fatal_sig)
/* raise (sig_num);*/
kill (getpid (), sig_num);
@ -242,38 +240,36 @@ on_signal (int sig_num)
switch (sig_num)
{
case SIGHUP:
sig = "sighup";
terminate ("sighup caught");
break;
case SIGINT:
sig = "sigint";
terminate ("sigint caught");
break;
case SIGQUIT:
sig = "sigquit";
terminate ("sigquit caught");
break;
case SIGABRT:
sig = "sigabrt";
terminate ("sigabrt caught");
break;
case SIGBUS:
sig = "sigbus";
fatal_error ("sigbus caught");
break;
case SIGSEGV:
sig = "sigsegv";
fatal_error ("sigsegv caught");
break;
case SIGPIPE:
sig = "sigpipe";
terminate ("sigpipe caught");
break;
case SIGTERM:
sig = "sigterm";
terminate ("sigterm caught");
break;
case SIGFPE:
sig = "sigfpe";
fatal_error ("sigfpe caught");
break;
default:
sig = "unknown signal";
fatal_error ("unknown signal");
break;
}
fatal_error ("%s caught", sig);
}
static RETSIGTYPE

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -92,7 +92,7 @@ static void palette_close_callback (GtkWidget *, gpointer);
static gint palette_dialog_delete_callback (GtkWidget *, GdkEvent *, gpointer);
static void palette_new_entries_callback (GtkWidget *, gpointer);
static void palette_add_entries_callback (GtkWidget *, gpointer, gpointer);
static void palette_merge_entries_callback (GtkWidget *, gpointer);
/* static void palette_merge_entries_callback (GtkWidget *, gpointer); */
static void palette_delete_entries_callback (GtkWidget *, gpointer);
static void palette_select_callback (int, int, int, ColorSelectState, void *);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -234,7 +234,16 @@ plug_in_init ()
datafiles_read_directories (plug_in_path, plug_in_init_file, MODE_EXECUTABLE);
/* read the pluginrc file for cached data */
sprintf (filename, "%s/pluginrc", gimp_directory ());
if (pluginrc_path)
{
if (*pluginrc_path == '/')
strcpy(filename, pluginrc_path);
else
sprintf(filename, "%s/%s", gimp_directory(), pluginrc_path);
}
else
sprintf (filename, "%s/pluginrc", gimp_directory ());
app_init_update_status("Resource configuration", filename, -1);
parse_gimprc_file (filename);

View File

@ -92,7 +92,7 @@ static void palette_close_callback (GtkWidget *, gpointer);
static gint palette_dialog_delete_callback (GtkWidget *, GdkEvent *, gpointer);
static void palette_new_entries_callback (GtkWidget *, gpointer);
static void palette_add_entries_callback (GtkWidget *, gpointer, gpointer);
static void palette_merge_entries_callback (GtkWidget *, gpointer);
/* static void palette_merge_entries_callback (GtkWidget *, gpointer); */
static void palette_delete_entries_callback (GtkWidget *, gpointer);
static void palette_select_callback (int, int, int, ColorSelectState, void *);

View File

@ -91,6 +91,7 @@ gimp_main (int argc,
signal (SIGSEGV, gimp_signal);
signal (SIGPIPE, gimp_signal);
signal (SIGTERM, gimp_signal);
signal (SIGFPE, gimp_signal);
_readfd = atoi (argv[2]);
_writefd = atoi (argv[3]);
@ -858,7 +859,17 @@ gimp_signal (int signum)
caught_fatal_sig = 1;
fprintf (stderr, "\n%s: %s caught\n", progname, g_strsignal (signum));
g_debug (progname);
switch (signum)
{
case SIGBUS:
case SIGSEGV:
case SIGFPE:
g_debug (progname);
break;
default:
break;
}
gimp_quit ();
}
@ -1035,7 +1046,7 @@ gimp_temp_proc_run (GPProcRun *proc_run)
int nreturn_vals;
GRunProc run_proc;
run_proc = g_hash_table_lookup (temp_proc_ht, (gpointer) proc_run->name);
run_proc = (GRunProc)g_hash_table_lookup (temp_proc_ht, (gpointer) proc_run->name);
if (run_proc)
{

View File

@ -2161,7 +2161,7 @@ force_overwrite (char *filename)
GtkWidget *dlg;
GtkWidget *label;
GtkWidget *table;
guchar buffer[CML_LINE_SIZE];
gchar buffer[CML_LINE_SIZE];
gint tmp;
dlg = gtkW_dialog_new ("CML file operation warning",

View File

@ -17,7 +17,7 @@ static void run(char *name,
GParam * param,
int *nreturn_vals,
GParam ** return_vals);
static int colors_equal(guchar *col1, gchar *col2, int bytes);
static int colors_equal(guchar *col1, guchar *col2, int bytes);
static int guess_bgcolor(GPixelRgn *pr, int width, int height, int bytes,
guchar *color);
@ -256,7 +256,7 @@ static int guess_bgcolor(GPixelRgn *pr, int width, int height, int bytes,
}
}
static int colors_equal(guchar *col1, gchar *col2, int bytes) {
static int colors_equal(guchar *col1, guchar *col2, int bytes) {
int equal = 1;
int b;

View File

@ -11,6 +11,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <gtk/gtk.h>
#include <libgimp/gimp.h>
#include "bmp.h"

View File

@ -2161,7 +2161,7 @@ force_overwrite (char *filename)
GtkWidget *dlg;
GtkWidget *label;
GtkWidget *table;
guchar buffer[CML_LINE_SIZE];
gchar buffer[CML_LINE_SIZE];
gint tmp;
dlg = gtkW_dialog_new ("CML file operation warning",

View File

@ -17,7 +17,7 @@ static void run(char *name,
GParam * param,
int *nreturn_vals,
GParam ** return_vals);
static int colors_equal(guchar *col1, gchar *col2, int bytes);
static int colors_equal(guchar *col1, guchar *col2, int bytes);
static int guess_bgcolor(GPixelRgn *pr, int width, int height, int bytes,
guchar *color);
@ -256,7 +256,7 @@ static int guess_bgcolor(GPixelRgn *pr, int width, int height, int bytes,
}
}
static int colors_equal(guchar *col1, gchar *col2, int bytes) {
static int colors_equal(guchar *col1, guchar *col2, int bytes) {
int equal = 1;
int b;

View File

@ -24,7 +24,7 @@ static void run (char *name, int nparams, GParam *param, int *nreturn_vals,
GPlugInInfo PLUG_IN_INFO = { NULL, NULL, query, run, };
static int running= FALSE;
static guchar *filename; /* Filename of palette file */
static gchar *filename; /* Filename of palette file */
MAIN ()
@ -63,10 +63,10 @@ static int palette_dialog();
/* AFAIK This should be part of libgimp (sigh) */
static guchar* gimp_gimprc_query(guchar *key) {
static gchar* gimp_gimprc_query(gchar *key) {
GParam *return_vals;
int nreturn_vals;
guchar *value;
gchar *value;
return_vals = gimp_run_procedure ("gimp_gimprc_query", &nreturn_vals,
PARAM_STRING, key, PARAM_END);
@ -179,7 +179,7 @@ static int palette_dialog() {
gchar **argv;
gint argc;
GtkWidget *dialog;
guchar *directory, *data;
gchar *directory, *data;
argc = 1;
argv = g_new (gchar *, 1);

View File

@ -66,7 +66,7 @@ typedef struct _PNMInfo {
/* Contains the information needed to write out PNM rows */
typedef struct _PNMRowInfo {
int fd; /* File descriptor */
unsigned char *rowbuf; /* Buffer for writing out rows */
char *rowbuf; /* Buffer for writing out rows */
int xres; /* X resolution */
int np; /* Number of planes */
unsigned char *red; /* Colormap red */
@ -632,7 +632,7 @@ pnmsaverow_raw_indexed (PNMRowInfo *ri,
unsigned char *data)
{
int i;
unsigned char *rbcur = ri->rowbuf;
char *rbcur = ri->rowbuf;
for (i = 0; i < ri->xres; i++)
{
@ -649,7 +649,7 @@ pnmsaverow_ascii (PNMRowInfo *ri,
unsigned char *data)
{
int i;
unsigned char *rbcur = ri->rowbuf;
char *rbcur = ri->rowbuf;
for (i = 0; i < ri->xres*ri->np; i++)
{
@ -665,7 +665,7 @@ pnmsaverow_ascii_indexed (PNMRowInfo *ri,
unsigned char *data)
{
int i;
unsigned char *rbcur = ri->rowbuf;
char *rbcur = ri->rowbuf;
for (i = 0; i < ri->xres; i++)
{
@ -693,7 +693,7 @@ save_image (char *filename,
unsigned char grn[256];
unsigned char blu[256];
unsigned char *data, *d;
unsigned char *rowbuf;
char *rowbuf;
char buf[BUFLEN];
char *temp;
int np;

View File

@ -23,7 +23,7 @@ static void run(char *name,
GParam * param,
int *nreturn_vals,
GParam ** return_vals);
static inline int colours_equal(guchar *col1, gchar *col2, int bytes);
static inline int colours_equal(guchar *col1, guchar *col2, int bytes);
static void do_zcrop(GDrawable *drawable, gint32);
@ -265,7 +265,7 @@ static void do_zcrop(GDrawable *drawable, gint32 image_id)
}
static inline int colours_equal(guchar *col1, gchar *col2, int bytes)
static inline int colours_equal(guchar *col1, guchar *col2, int bytes)
{
int b;

View File

@ -891,7 +891,7 @@ plug_in_parse_gfig_path()
Tkane from gflare plugin
*/
void
gfig_name_encode (gchar *dest, guchar *src)
gfig_name_encode (gchar *dest, gchar *src)
{
int cnt = MAX_LOAD_LINE - 1;
@ -912,7 +912,7 @@ gfig_name_encode (gchar *dest, guchar *src)
Translate "\\040" to SPACE, etc.
*/
void
gfig_name_decode (gchar *dest, guchar *src)
gfig_name_decode (gchar *dest, gchar *src)
{
int cnt = MAX_LOAD_LINE - 1;
int tmp;

View File

@ -202,7 +202,7 @@ void fli_read_header(FILE *f, s_fli_header *fli_header)
}
}
void fli_read_frame(FILE *f, s_fli_header *fli_header, guchar *framebuf, gchar *cmap)
void fli_read_frame(FILE *f, s_fli_header *fli_header, guchar *framebuf, guchar *cmap)
{
s_fli_frame fli_frame;
unsigned long framepos;

View File

@ -177,7 +177,7 @@ guchar back_color[3];
/***** Functions *****/
/****/
MAIN ();
MAIN ()
/****/
/*************************/
@ -616,7 +616,7 @@ static int do_dialog (void) {
gtk_signal_connect (GTK_OBJECT (button), "toggled",
(GtkSignalFunc) dialog_toggle_update,
(gpointer) i + 5);
(gpointer) (i + 5));
gtk_box_pack_start (GTK_BOX (orhbox2), button, TRUE, FALSE, 0);
gtk_widget_show (button);
@ -745,7 +745,7 @@ static void init_calculation () {
static void do_curl_effect (void) {
gint x, y, color_image;
guint x1, y1, k;
gint x1, y1, k;
guint alpha_pos, progress, max_progress;
gdouble intensity, alpha;
vector_t v, dl, dr;

View File

@ -24,7 +24,7 @@ static void run (char *name, int nparams, GParam *param, int *nreturn_vals,
GPlugInInfo PLUG_IN_INFO = { NULL, NULL, query, run, };
static int running= FALSE;
static guchar *filename; /* Filename of palette file */
static gchar *filename; /* Filename of palette file */
MAIN ()
@ -63,10 +63,10 @@ static int palette_dialog();
/* AFAIK This should be part of libgimp (sigh) */
static guchar* gimp_gimprc_query(guchar *key) {
static gchar* gimp_gimprc_query(gchar *key) {
GParam *return_vals;
int nreturn_vals;
guchar *value;
gchar *value;
return_vals = gimp_run_procedure ("gimp_gimprc_query", &nreturn_vals,
PARAM_STRING, key, PARAM_END);
@ -179,7 +179,7 @@ static int palette_dialog() {
gchar **argv;
gint argc;
GtkWidget *dialog;
guchar *directory, *data;
gchar *directory, *data;
argc = 1;
argv = g_new (gchar *, 1);

View File

@ -66,7 +66,7 @@ typedef struct _PNMInfo {
/* Contains the information needed to write out PNM rows */
typedef struct _PNMRowInfo {
int fd; /* File descriptor */
unsigned char *rowbuf; /* Buffer for writing out rows */
char *rowbuf; /* Buffer for writing out rows */
int xres; /* X resolution */
int np; /* Number of planes */
unsigned char *red; /* Colormap red */
@ -632,7 +632,7 @@ pnmsaverow_raw_indexed (PNMRowInfo *ri,
unsigned char *data)
{
int i;
unsigned char *rbcur = ri->rowbuf;
char *rbcur = ri->rowbuf;
for (i = 0; i < ri->xres; i++)
{
@ -649,7 +649,7 @@ pnmsaverow_ascii (PNMRowInfo *ri,
unsigned char *data)
{
int i;
unsigned char *rbcur = ri->rowbuf;
char *rbcur = ri->rowbuf;
for (i = 0; i < ri->xres*ri->np; i++)
{
@ -665,7 +665,7 @@ pnmsaverow_ascii_indexed (PNMRowInfo *ri,
unsigned char *data)
{
int i;
unsigned char *rbcur = ri->rowbuf;
char *rbcur = ri->rowbuf;
for (i = 0; i < ri->xres; i++)
{
@ -693,7 +693,7 @@ save_image (char *filename,
unsigned char grn[256];
unsigned char blu[256];
unsigned char *data, *d;
unsigned char *rowbuf;
char *rowbuf;
char buf[BUFLEN];
char *temp;
int np;

View File

@ -34,6 +34,26 @@
* Revision History:
*
* $Log$
* Revision 1.6 1998/04/11 05:07:46 yosh
* * app/app_procs.c: fixed up idle handler for file open (look like testgtk
* idle demo)
*
* * app/colomaps.c: fixup for visual test and use of gdk_color_alloc for some
* fixed colors (from Owen Taylor)
*
* * app/errors.h
* * app/errors.c
* * app/main.c
* * libgimp/gimp.c: redid the signal handlers so we only get a debug prompt on
* SIGSEGV, SIGBUS, and SIGFPE.
*
* * applied gimp-jbuhler-980408-0 and gimp-joke-980409-0 (warning fixups)
*
* * applied gimp-monnaux-980409-0 for configurable plugin path for multiarch
* setups
*
* -Yosh
*
* Revision 1.5 1998/04/07 03:41:15 yosh
* configure.in: fix for $srcdir != $builddir for data. Tightened check for
* random() and add -lucb on systems that need it. Fix for xdelta.h check. Find
@ -131,8 +151,11 @@
* (currently 720) to avoid problems...
*/
int error[2][4][11*720+4] = { { { 0 } } };
int error[2][4][11*720+4] =
{
{ { 0 }, { 0 }, { 0 } , { 0 } },
{ { 0 }, { 0 }, { 0 } , { 0 } }
};
/*
* 'dither_black()' - Dither grayscale pixels to black.

View File

@ -84,7 +84,7 @@ ltrace_1 (LISP fcn_name, LISP env)
else if (TYPE (fcn) == tc_closure_traced)
;
else
err ("not a closure, cannot trace", fcn);
my_err ("not a closure, cannot trace", fcn);
return (NIL);
}
@ -105,7 +105,7 @@ luntrace_1 (LISP fcn)
else if (TYPE (fcn) == tc_closure_traced)
fcn->type = tc_closure;
else
err ("not a closure, cannot untrace", fcn);
my_err ("not a closure, cannot untrace", fcn);
return (NIL);
}

View File

@ -84,7 +84,7 @@ ltrace_1 (LISP fcn_name, LISP env)
else if (TYPE (fcn) == tc_closure_traced)
;
else
err ("not a closure, cannot trace", fcn);
my_err ("not a closure, cannot trace", fcn);
return (NIL);
}
@ -105,7 +105,7 @@ luntrace_1 (LISP fcn)
else if (TYPE (fcn) == tc_closure_traced)
fcn->type = tc_closure;
else
err ("not a closure, cannot untrace", fcn);
my_err ("not a closure, cannot untrace", fcn);
return (NIL);
}

View File

@ -34,6 +34,26 @@
* Revision History:
*
* $Log$
* Revision 1.6 1998/04/11 05:07:49 yosh
* * app/app_procs.c: fixed up idle handler for file open (look like testgtk
* idle demo)
*
* * app/colomaps.c: fixup for visual test and use of gdk_color_alloc for some
* fixed colors (from Owen Taylor)
*
* * app/errors.h
* * app/errors.c
* * app/main.c
* * libgimp/gimp.c: redid the signal handlers so we only get a debug prompt on
* SIGSEGV, SIGBUS, and SIGFPE.
*
* * applied gimp-jbuhler-980408-0 and gimp-joke-980409-0 (warning fixups)
*
* * applied gimp-monnaux-980409-0 for configurable plugin path for multiarch
* setups
*
* -Yosh
*
* Revision 1.5 1998/04/07 03:41:18 yosh
* configure.in: fix for $srcdir != $builddir for data. Tightened check for
* random() and add -lucb on systems that need it. Fix for xdelta.h check. Find
@ -265,7 +285,7 @@ run(char *name, /* I - Name of filter program. */
if (compression < 0 || compression > 2)
values[0].data.d_status = STATUS_CALLING_ERROR;
};
}
break;
case RUN_WITH_LAST_VALS :
@ -278,7 +298,7 @@ run(char *name, /* I - Name of filter program. */
default :
break;
};
}
if (values[0].data.d_status == STATUS_SUCCESS)
{
@ -287,7 +307,7 @@ run(char *name, /* I - Name of filter program. */
gimp_set_data("file_sgi_save", &compression, sizeof(compression));
else
values[0].data.d_status = STATUS_EXECUTION_ERROR;
};
}
}
else
values[0].data.d_status = STATUS_EXECUTION_ERROR;
@ -329,7 +349,7 @@ load_image(char *filename) /* I - File to load */
{
g_print("can't open image file\n");
gimp_quit();
};
}
if (strrchr(filename, '/') != NULL)
sprintf(progress, "Loading %s:", strrchr(filename, '/') + 1);
@ -363,14 +383,14 @@ load_image(char *filename) /* I - File to load */
image_type = RGB;
layer_type = RGBA_IMAGE;
break;
};
}
image = gimp_image_new(sgip->xsize, sgip->ysize, image_type);
if (image == -1)
{
g_print("can't allocate new image\n");
gimp_quit();
};
}
gimp_image_set_filename(image, filename);
@ -422,7 +442,7 @@ load_image(char *filename) /* I - File to load */
count = 0;
gimp_progress_update((double)y / (double)sgip->ysize);
};
}
for (i = 0; i < sgip->zsize; i ++)
if (sgiGetRow(sgip, rows[i], sgip->ysize - 1 - y, i) < 0)
@ -448,8 +468,8 @@ load_image(char *filename) /* I - File to load */
for (x = 0, pptr = pixels[count]; x < sgip->xsize; x ++)
for (i = 0; i < sgip->zsize; i ++, pptr ++)
*pptr = (unsigned)(rows[i][x] + 32768) >> 8;
};
};
}
}
/*
* Do the last n rows (count always > 0)
@ -527,7 +547,7 @@ save_image(char *filename, /* I - File to save to */
case RGBA_IMAGE :
zsize = 4;
break;
};
}
/*
* Open the file for writing...
@ -539,7 +559,7 @@ save_image(char *filename, /* I - File to save to */
{
g_print("can't create image file\n");
gimp_quit();
};
}
if (strrchr(filename, '/') != NULL)
sprintf(progress, "Saving %s:", strrchr(filename, '/') + 1);
@ -594,10 +614,10 @@ save_image(char *filename, /* I - File to save to */
for (j = 0; j < zsize; j ++)
sgiPutRow(sgip, rows[j], drawable->height - 1 - y - i, j);
};
}
gimp_progress_update((double)y / (double)drawable->height);
};
}
/*
* Done with the file...
@ -748,7 +768,7 @@ save_dialog(void)
(gpointer)((long)i));
gtk_box_pack_start(GTK_BOX(vbox), button, FALSE, FALSE, 0);
gtk_widget_show(button);
};
}
/*
* Show everything and go...

View File

@ -37,6 +37,26 @@
* Revision History:
*
* $Log$
* Revision 1.4 1998/04/11 05:07:50 yosh
* * app/app_procs.c: fixed up idle handler for file open (look like testgtk
* idle demo)
*
* * app/colomaps.c: fixup for visual test and use of gdk_color_alloc for some
* fixed colors (from Owen Taylor)
*
* * app/errors.h
* * app/errors.c
* * app/main.c
* * libgimp/gimp.c: redid the signal handlers so we only get a debug prompt on
* SIGSEGV, SIGBUS, and SIGFPE.
*
* * applied gimp-jbuhler-980408-0 and gimp-joke-980409-0 (warning fixups)
*
* * applied gimp-monnaux-980409-0 for configurable plugin path for multiarch
* setups
*
* -Yosh
*
* Revision 1.3 1998/04/01 22:14:53 neo
* Added checks for print spoolers to configure.in as suggested by Michael
* Sweet. The print plug-in still needs some changes to Makefile.am to make
@ -111,19 +131,19 @@ sgiClose(sgi_t *sgip) /* I - SGI image */
i --, offset ++)
if (putlong(offset[0], sgip->file) < 0)
return (-1);
};
}
if (sgip->table != NULL)
{
free(sgip->table[0]);
free(sgip->table);
};
}
if (sgip->length != NULL)
{
free(sgip->length[0]);
free(sgip->length);
};
}
if (sgip->comp == SGI_COMP_ARLE)
free(sgip->arle_row);
@ -176,7 +196,7 @@ sgiGetRow(sgi_t *sgip, /* I - SGI image */
{
for (x = sgip->xsize; x > 0; x --, row ++)
*row = getshort(sgip->file);
};
}
break;
case SGI_COMP_RLE :
@ -189,7 +209,7 @@ sgiGetRow(sgi_t *sgip, /* I - SGI image */
else
return (read_rle16(sgip->file, row, sgip->xsize));
break;
};
}
return (0);
}
@ -224,13 +244,13 @@ sgiOpen(char *filename, /* I - File to open */
{
free(sgip);
return (NULL);
};
}
if ((sgip->file = fopen(filename, "rb")) == NULL)
{
free(sgip);
return (NULL);
};
}
sgip->mode = SGI_READ;
@ -240,7 +260,7 @@ sgiOpen(char *filename, /* I - File to open */
fclose(sgip->file);
free(sgip);
return (NULL);
};
}
sgip->comp = getc(sgip->file);
sgip->bpp = getc(sgip->file);
@ -267,7 +287,7 @@ sgiOpen(char *filename, /* I - File to open */
for (i = 0; i < sgip->zsize; i ++)
for (j = 0; j < sgip->ysize; j ++)
sgip->table[i][j] = getlong(sgip->file);
};
}
break;
case SGI_WRITE :
@ -280,13 +300,13 @@ sgiOpen(char *filename, /* I - File to open */
{
free(sgip);
return (NULL);
};
}
if ((sgip->file = fopen(filename, "wb+")) == NULL)
{
free(sgip);
return (NULL);
};
}
sgip->mode = SGI_WRITE;
@ -306,7 +326,7 @@ sgiOpen(char *filename, /* I - File to open */
{
putlong(-32768, sgip->file); /* Minimum pixel */
putlong(32767, sgip->file); /* Maximum pixel */
};
}
putlong(0, sgip->file); /* Reserved */
memset(name, 0, sizeof(name));
@ -336,7 +356,7 @@ sgiOpen(char *filename, /* I - File to open */
{
for (i = xsize * ysize * zsize; i > 0; i --)
putshort(0, sgip->file);
};
}
break;
case SGI_COMP_ARLE : /* Aggressive RLE */
@ -362,13 +382,13 @@ sgiOpen(char *filename, /* I - File to open */
for (i = 1; i < sgip->zsize; i ++)
sgip->length[i] = sgip->length[0] + i * sgip->ysize;
break;
};
}
break;
default :
free(sgip);
return (NULL);
};
}
return (sgip);
}
@ -415,7 +435,7 @@ sgiPutRow(sgi_t *sgip, /* I - SGI image */
{
for (x = sgip->xsize; x > 0; x --, row ++)
putshort(*row, sgip->file);
};
}
break;
case SGI_COMP_ARLE :
@ -437,8 +457,8 @@ sgiPutRow(sgi_t *sgip, /* I - SGI image */
sgip->table[z][y] = sgip->arle_offset;
sgip->length[z][y] = sgip->arle_length;
return (0);
};
};
}
}
/*
* If that didn't match, search all the previous rows...
@ -455,7 +475,7 @@ sgiPutRow(sgi_t *sgip, /* I - SGI image */
{
x = 0;
break;
};
}
for (x = 0; x < sgip->xsize; x ++)
if (row[x] != sgip->arle_row[x])
@ -472,14 +492,14 @@ sgiPutRow(sgi_t *sgip, /* I - SGI image */
{
x = 0;
break;
};
}
for (x = 0; x < sgip->xsize; x ++)
if (row[x] != sgip->arle_row[x])
break;
}
while (x < sgip->xsize);
};
}
if (x == sgip->xsize)
{
@ -509,13 +529,13 @@ sgiPutRow(sgi_t *sgip, /* I - SGI image */
sgip->arle_offset = offset;
sgip->arle_length = x;
memcpy(sgip->arle_row, row, sgip->xsize * sizeof(short));
};
}
sgip->nextrow = ftell(sgip->file);
sgip->length[z][y] = x;
return (x);
};
}
return (0);
}
@ -627,8 +647,8 @@ read_rle8(FILE *fp, /* I - File to read from */
length ++;
for (i = 0; i < count; i ++, row ++, xsize --)
*row = ch;
};
};
}
}
return (xsize > 0 ? -1 : length);
}
@ -672,8 +692,8 @@ read_rle16(FILE *fp, /* I - File to read from */
length ++;
for (i = 0; i < count; i ++, row ++, xsize --)
*row = ch;
};
};
}
}
return (xsize > 0 ? -1 : length * 2);
}
@ -706,7 +726,7 @@ write_rle8(FILE *fp, /* I - File to write to */
{
row ++;
x --;
};
}
row -= 2;
x += 2;
@ -728,8 +748,8 @@ write_rle8(FILE *fp, /* I - File to write to */
start ++;
i --;
length ++;
};
};
}
}
if (x <= 0)
break;
@ -744,7 +764,7 @@ write_rle8(FILE *fp, /* I - File to write to */
{
row ++;
x --;
};
}
count = row - start;
while (count > 0)
@ -759,8 +779,8 @@ write_rle8(FILE *fp, /* I - File to write to */
if (putc(repeat, fp) == EOF)
return (-1);
length ++;
};
};
}
}
length ++;
@ -798,7 +818,7 @@ write_rle16(FILE *fp, /* I - File to write to */
{
row ++;
x --;
};
}
row -= 2;
x += 2;
@ -820,8 +840,8 @@ write_rle16(FILE *fp, /* I - File to write to */
start ++;
i --;
length ++;
};
};
}
}
if (x <= 0)
break;
@ -836,7 +856,7 @@ write_rle16(FILE *fp, /* I - File to write to */
{
row ++;
x --;
};
}
count = row - start;
while (count > 0)
@ -851,8 +871,8 @@ write_rle16(FILE *fp, /* I - File to write to */
if (putshort(repeat, fp) == EOF)
return (-1);
length ++;
};
};
}
}
length ++;

View File

@ -58,16 +58,16 @@ typedef gdouble colRGBA[4];
* This structure is used for persistent data.
*/
#define B_W 0 /* colors setting */
#define USE_FG_BG 1
#define USE_COLORS 2
#define B_W 0L /* colors setting */
#define USE_FG_BG 1L
#define USE_COLORS 2L
#define LINEAR 0 /* colorization settings */
#define BILINEAR 1
#define SINUS 2
#define LINEAR 0L /* colorization settings */
#define BILINEAR 1L
#define SINUS 2L
#define IDEAL 0 /* Perturbation settings */
#define PERTURBED 1
#define IDEAL 0L /* Perturbation settings */
#define PERTURBED 1L
typedef struct {
gdouble scalex, scaley;
@ -75,9 +75,9 @@ typedef struct {
gdouble blend_power;
gint seed;
gint tiling;
gint perturbation;
gint colorization;
gint colors;
glong perturbation;
glong colorization;
glong colors;
colRGBA col1,col2;
} SinusVals;

View File

@ -23,7 +23,7 @@ static void run(char *name,
GParam * param,
int *nreturn_vals,
GParam ** return_vals);
static inline int colours_equal(guchar *col1, gchar *col2, int bytes);
static inline int colours_equal(guchar *col1, guchar *col2, int bytes);
static void do_zcrop(GDrawable *drawable, gint32);
@ -265,7 +265,7 @@ static void do_zcrop(GDrawable *drawable, gint32 image_id)
}
static inline int colours_equal(guchar *col1, gchar *col2, int bytes)
static inline int colours_equal(guchar *col1, guchar *col2, int bytes)
{
int b;