* io-png.c (png_simple_error_callback): libpng error handlers must
not return to their callers, thus longjmp out. This prevents
annoying stderr output from the default error handler.
* io-png.c (gdk_pixbuf__png_image_stop_load): Don't leak info_ptr.
* io-png.c (gdk_pixbuf__png_image_load): Get rid of unused
end_info. Also call png_read_end to check proper ending of the png
file and catch text chunks after the image data.
* io-tiff.c (tiff_image_parse): Don't leak pixbuf on error.
* io-gif.c (gdk_pixbuf__gif_image_load_increment): Don't leak
context->buf on error.
* gdk-pixbuf-loader.c (gdk_pixbuf_loader_close): Make sure to call
stop_load even for short images to prevent memleaks.
* io-png.c (setup_png_transformations): Changed signature to
return success and set a GError parameter, adjusted all callers.
Also work around a possible FPE in libpng and always check that
the new info is sane.
* io-wbmp.c (gdk_pixbuf__wbmp_image_load_increment):
context->updated_func is NULL during a nonincremental load.
(gdk_pixbuf__wbmp_image_load): Stop reading after the first error.
* io-tga.c (try_colormap, gdk_pixbuf__tga_stop_load): Avoid a
double free error if reading the colormap fails.
* io-tiff.c (tiff_image_parse): Make TIFFReadRGBAImage stop on
errors, since it may otherwise segfault on certain bad TIFFs.
Wed Mar 20 16:36:08 2002 Owen Taylor <otaylor@redhat.com>
* gtk/*.c: Patch from Erwann Chenede, #73900 fixing
a lot of warnings with Forte CC, mostly implicit
casts between void * and function pointers.
* gdk/gdkevents.c (gdk_event_get_state): GdkEventVisibility's
state field is not a GdkModifierType. (Also #73900)
* io-tga.c: Fix assumptions on rowstride by manually allocating a
contiguous pixel buffer. Catch buffer overruns in RLE-modi.
Support grayscale + alpha (which can be written, but not read (!)
by the Gimp).
* test-images.h: Add valid_ras_test and invalid_bmp_1.
* test-loaders.c (main): Add random tests for ras and pnm and an
invalid bmp which was a crasher until my 2002-03-12 commit.
* io-pnm.c (gdk_pixbuf__pnm_image_load_increment): Don't unref the
pixbuf on errors.
* io-ras.c: Handle some errors.
2002-03-12 Sven Neumann <sven@gimp.org>
* gdk-pixbuf.c (gdk_pixbuf_fill): use sequential writes instead of
calling memcpy(). Simpler and potentially faster. (#70332)
Sat Mar 2 22:11:10 2002 Owen Taylor <otaylor@redhat.com>
* gdk-pixbuf-io.c (_gdk_pixbuf_load_module): If we
can't load the module using the g_module_build_path()
filename, try loading it as a .la file.
* test-loaders.c: Look for modules in current directory
rather than .libs, so we find the right .la files.
* test-loaders.c: Back out some accidental commits.
2002-03-03 Tor Lillqvist <tml@iki.fi>
* gtk-pixbuf.rc.in: Remove.
* gdk_pixbuf.rc.in: Name like this instead (wrong name used by
mistake by Hans).
* makefile.msc: Corresponding changes.
* Makefile.am: Use gdk_pixbuf.rc on Win32. Distribute it.
Sat Mar 2 14:32:50 2002 Owen Taylor <otaylor@redhat.com>
* configure.in: Default to --disable-gtk-doc (avoid Jade
breakage) and --disable-static (static linking causes
problems with Xft changes.)
* autogen.sh: Add --enable-gtk-doc by default.
* Makefile.am: Add a 'mydistcheck' rule that passes
--enable-gtk-doc to the configure since that is needed
for 'make dist'.
* docs/tutorial/Makefile.am (dist-hook): Don't distribute
the PDF file. (Rule doesn't work on my system, plus it's
big.)
* gtk/Makefile.am: 'make dist' fixes.
Wed Feb 27 18:33:04 2002 Owen Taylor <otaylor@redhat.com>
* gdk-pixdata.c (gdk_pixdata_to_csource): Use {} not
() to group around string assigned to char[]. (#72767,
Tomas gren)
2002-02-21 Havoc Pennington <hp@pobox.com>
* gdk-pixbuf-loader.c (gdk_pixbuf_loader_load_module): remove
C++-commented debug spew, reported by David L. Cooper
* docs/tutorial/gtk-tut.sgml, examples/paned/paned.c,
examples/paned/Makefile: Make the paned example deprecation-clean.
* various ChangeLog files: correct my email.
* pixops/pixops.c (correct_total): New function to make sure
that the weights sum up to the correct total without introducing
negative weights.
(tile_make_weights, bilinear_make_fast_weights,
bilinear_make_weights): Use correct_total.
* test-images.h (tiff1_test_3), test-loaders.c (main): Add a
(#ifdef 0'ed) test provoking a segfault in TIFFReadDirectory().
* io-ico.c (DecodeHeader): Check that pixbuf could be allocated.
* test-images.h (ico_test_2), test-loaders.c (main): Test the
previous change.
* io-wbmp.c (gdk_pixbuf__wbmp_image_load_increment): Don't write
beyond the end of buffer if width % 8 != 0.
* io-tga.c (try_preload): Enforce that ctx->hdr->type is one of
the supported types, otherwise parse_data_for_row () will not make
any progress, leading to an infinite loop.
Fri Feb 8 23:11:15 2002 Owen Taylor <otaylor@redhat.com>
* pixops/pixops.c: Force all weight arrays to sum exactly
to 65535. (Fixes#70971, reported by Federico Mena Quintero)
* Makefile.am (libgdk_pixbuf_1_3_la_DEPENDENCIES): Add
libpixops.la.
* io-ico.c: Merge 16- and 32-bit ico support from the stable
branch. (#61179)
* io-gif.c: Recomposite all images if the animation size changes
while loading. (#70055)
* gdk-pixbuf.c (gdk-pixbuf-fill): Make it work for subpixbufs.
(#70055)
Sat Jan 19 20:49:20 2002 Manish Singh <yosh@gimp.org>
* io-jpeg.c, io-png.c: Made sure all the error cases involving
jpeg or png load/saves clean themselves up properly. Marked some
variables needed for cleanup volatile so they aren't clobbered by
setjmp.
Fri Jan 11 18:05:07 2002 Owen Taylor <otaylor@redhat.com>
* pixops/pixops.c: Fix integer overflow for the values
passed to the pixel functions. (#55148)
Fri Jan 11 17:53:58 2002 Owen Taylor <otaylor@redhat.com>
* pixops/pixops.c (pixops_scale_nearest): Remove meaningless
FIXME.
* pixops/pixops.c (pixops_process): Comment the computation
of run_end_index and fix some edge cases.
* pixops/{scale_line_22_33_mmx.S, composite_line_22_4a4_mmx.S:
composite_line_color_22_4a4_mmx.S}: Handle the case where
dest <= dest_end properly. (#52001)
Wed Jan 9 11:29:44 2002 Owen Taylor <otaylor@redhat.com>
* Makefile.am (s-enum-types-h): Include glib-object.h,
Add G_BEGIN_DECLS/END_DECLS to gdk-pixbuf-enum-types.h. (#68325,
Mikael Hermansson)
* *.h: G_BEGIN_DECLS cleanups.
Tue Jan 8 10:58:04 2002 Owen Taylor <otaylor@redhat.com>
* gdk-pixbuf-util.c (gdk_pixbuf_saturate_and_pixelate):
- Massive cleanup, make actually legible.
- Fix some clamp-to-range bugs found by Jim Cape (#68231).
- Add a g_return_if_fail() if src and dest alpha don't match.
- Allow for src_rowstride != dest_rowstride.
Thu Jan 3 19:31:58 2002 Owen Taylor <otaylor@redhat.com>
* pixops/pixops.c (scale_line_22_33): Fix and uncomment
non-MMX version.
* pixops/pixops.c (pixops_composite_nearest): Remove a
division.
* pixops/pixops.c (pixops_composite): Add some docs
about the parameters.
* pixops/README: Add notes about the correct algorithms
for alpha compositing and how to implement them quickly.