head 1.5; access; symbols pkgsrc-2013Q2:1.5.0.6 pkgsrc-2013Q2-base:1.5 pkgsrc-2012Q4:1.5.0.4 pkgsrc-2012Q4-base:1.5 pkgsrc-2011Q4:1.5.0.2 pkgsrc-2011Q4-base:1.5 pkgsrc-2011Q3:1.4.0.6 pkgsrc-2011Q3-base:1.4 pkgsrc-2011Q2:1.4.0.4 pkgsrc-2011Q2-base:1.4 pkgsrc-2011Q1:1.4.0.2 pkgsrc-2011Q1-base:1.4 pkgsrc-2010Q4:1.2.0.2 pkgsrc-2010Q4-base:1.2 pkgsrc-2010Q3:1.1.0.4 pkgsrc-2010Q3-base:1.1 pkgsrc-2010Q2:1.1.0.2 pkgsrc-2010Q2-base:1.1; locks; strict; comment @# @; 1.5 date 2011.10.16.17.47.49; author adam; state dead; branches; next 1.4; 1.4 date 2011.01.29.16.29.03; author adam; state Exp; branches; next 1.3; 1.3 date 2011.01.15.16.31.18; author wiz; state Exp; branches; next 1.2; 1.2 date 2010.10.16.15.50.21; author wiz; state Exp; branches; next 1.1; 1.1 date 2010.06.13.22.44.46; author wiz; state Exp; branches; next ; desc @@ 1.5 log @Changes 1.8.0: * Various extensions to Local Minima and Maxima (3D algorithms, on-the-fly thresholding). * Added vigra::BucketQueue, vigra::MappedBucketQueue. * Refactored and extended 2D watershed algorithms (especially watershedsRegionGrowing()). * Added the vigra::Quaternion class. * Added Unsupervised Decomposition. * Added mathematical functions (even(), odd(), gamma(), loggamma(), legendre(), besselJ(), besselY(), linearSequence(), indexSort(), inversePermutation(), applyPermutation(), checksum()) * Implemented wrapper of the FFTW library to support arbitrary dimensional Fourier transforms (see fourierTransform() and vigra::FFTWPlan) and FFT-based convolution (see convolveFFT() and vigra::FFTWConvolvePlan) and refactored vigra::FFTWComplex. * Added cannyEdgelListThreshold(), cannyEdgelList3x3Threshold(). * Added capability to handle subarrays and anisotropic resolution to separableConvolveMultiArray() and related Gaussian filters. Added windowRatio parameters to vigra::Kernel1D::initGaussian() and vigra::Kernel1D::initGaussianDerivative() * Added vigra::StridedScanOrderIterator and corresponding vigra::MultiArrayView::begin(). * Extended vigra::MultiArrayView. Added vigra::Shape1 ... vigra::Shape5 convenience typedefs. * Implemented vigra::multi_math (arithmetic and algebraic functions for multi-dimensional arrays). * Extended the vigra::HDF5File class. * Improved and documented the Timing macros for runtime measurements. * Added support for the OpenEXR image format and multi-page TIFF. Improved support for the SIF format. * vigranumpy: added axistags and completly re-implemented VigraArray and the conversion between Python and C++ arrays in terms of axistags. * Minor improvements and bug fixes in the code and documentation. @ text @$NetBSD: patch-ab,v 1.4 2011/01/29 16:29:03 adam Exp $ --- src/impex/png.cxx.orig 2011-01-29 15:14:21.000000000 +0000 +++ src/impex/png.cxx @@@@ -320,7 +320,7 @@@@ namespace vigra { #if (PNG_LIBPNG_VER > 10008) && defined(PNG_READ_iCCP_SUPPORTED) char * dummyName; int dummyCompType; - char * profilePtr; + png_bytep profilePtr; png_uint_32 profileLen; if (png_get_valid( png, info, PNG_INFO_iCCP )) { png_get_iCCP(png, info, &dummyName, &dummyCompType, &profilePtr, &profileLen) ; @@@@ -592,7 +592,7 @@@@ namespace vigra { // set icc profile if (iccProfile.size() > 0) { png_set_iCCP(png, info, (png_charp)("icc"), 0, - (png_charp)iccProfile.begin(), (png_uint_32)iccProfile.size()); + (png_bytep)iccProfile.begin(), (png_uint_32)iccProfile.size()); } #endif @ 1.4 log @Changes 1.7.1: * Fixed the build process for MacOS X. * Re-activeted vigra-config (script to query VIGRA installation information) and added VigraConfig.cmake (query VIGRA installation information from within cmake). * Added CDash support (nightly builds and tests). * Added convexHull(). * Added vigra::Box. * Added vigra::Sampler class to sample given data in various ways. * Added much new functionality to the vigra::RandomForest class (e.g. more split strategies, variable importance measures, feature selection) * Added readSIF() (reader for the Andor SIF file format). * Added vigra::HDF5File for easier navigation in HDF5 files. * Added recursive approximation of the Gaussian filter (recursiveGaussianFilterX(), recursiveGaussianFilterY()) * vigranumpy: added Gabor filtering. * Fixed multi-threading bugs at various places. * Minor improvements and bug fixes in the code and documentation. @ text @d1 1 a1 1 $NetBSD$ @ 1.3 log @Fix build with png-1.5. @ text @d1 1 a1 1 $NetBSD: patch-ab,v 1.2 2010/10/16 15:50:21 wiz Exp $ d3 1 a3 4 Fix compilation with png-1.4, already included upstream. Fix build with png-1.5. --- src/impex/png.cxx.orig 2010-04-20 16:29:02.000000000 +0000 d5 1 a5 86 @@@@ -75,7 +75,11 @@@@ extern "C" { static void PngError( png_structp png_ptr, png_const_charp error_msg ) { png_error_message = std::string(error_msg); +#if (PNG_LIBPNG_VER < 10500) longjmp( png_ptr->jmpbuf, 1 ); +#else + png_longjmp( png_ptr, 1 ); +#endif } // called on non-fatal errors @@@@ -207,7 +211,7 @@@@ namespace vigra { vigra_postcondition( png != 0, "could not create the read struct." ); // create info struct - if (setjmp(png->jmpbuf)) { + if (setjmp(png_jmpbuf(png))) { png_destroy_read_struct( &png, &info, NULL ); vigra_postcondition( false, png_error_message.insert(0, "error in png_create_info_struct(): ").c_str() ); } @@@@ -215,14 +219,14 @@@@ namespace vigra { vigra_postcondition( info != 0, "could not create the info struct." ); // init png i/o - if (setjmp(png->jmpbuf)) { + if (setjmp(png_jmpbuf(png))) { png_destroy_read_struct( &png, &info, NULL ); vigra_postcondition( false, png_error_message.insert(0, "error in png_init_io(): ").c_str() ); } png_init_io( png, file.get() ); // specify that the signature was already read - if (setjmp(png->jmpbuf)) { + if (setjmp(png_jmpbuf(png))) { png_destroy_read_struct( &png, &info, NULL ); vigra_postcondition( false, png_error_message.insert(0, "error in png_set_sig_bytes(): ").c_str() ); } @@@@ -238,13 +242,13 @@@@ namespace vigra { void PngDecoderImpl::init() { // read all chunks up to the image data - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_read_info(): ").c_str() ); png_read_info( png, info ); // pull over the header fields int interlace_method, compression_method, filter_method; - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_get_IHDR(): ").c_str() ); png_get_IHDR( png, info, &width, &height, &bit_depth, &color_type, &interlace_method, &compression_method, &filter_method ); @@@@ -258,7 +262,7 @@@@ namespace vigra { // transform palette to rgb if ( color_type == PNG_COLOR_TYPE_PALETTE) { - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_palette_to_rgb(): ").c_str() ); png_set_palette_to_rgb(png); color_type = PNG_COLOR_TYPE_RGB; @@@@ -267,9 +271,9 @@@@ namespace vigra { // expand gray values to at least one byte size if ( color_type == PNG_COLOR_TYPE_GRAY && bit_depth < 8 ) { - if (setjmp(png->jmpbuf)) - vigra_postcondition( false,png_error_message.insert(0, "error in png_set_gray_1_2_4_to_8(): ").c_str()); - png_set_gray_1_2_4_to_8(png); + if (setjmp(png_jmpbuf(png))) + vigra_postcondition( false,png_error_message.insert(0, "error in png_set_expand_gray_1_2_4_to_8(): ").c_str()); + png_set_expand_gray_1_2_4_to_8(png); bit_depth = 8; } @@@@ -277,7 +281,7 @@@@ namespace vigra { #if 0 // strip alpha channel if ( color_type & PNG_COLOR_MASK_ALPHA ) { - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_set_strip_alpha(): ").c_str() ); png_set_strip_alpha(png); color_type ^= PNG_COLOR_MASK_ALPHA; @@@@ -319,9 +323,9 @@@@ namespace vigra { d10 1 a10 1 + png_byte * profilePtr; d12 1 a12 2 - if (info->valid & PNG_INFO_iCCP) { + if (png_get_valid(png, info, PNG_INFO_iCCP)) { d14 1 a14 98 iccProfilePtr = (unsigned char *) profilePtr; iccProfileLength = profileLen; @@@@ -334,7 +338,7 @@@@ namespace vigra { // image gamma double image_gamma = 0.45455; if ( png_get_valid( png, info, PNG_INFO_gAMA ) ) { - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_get_gAMA(): ").c_str() ); png_get_gAMA( png, info, &image_gamma ); } @@@@ -343,26 +347,26 @@@@ namespace vigra { double screen_gamma = 2.2; // set gamma correction - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_set_gamma(): ").c_str() ); png_set_gamma( png, screen_gamma, image_gamma ); #endif // interlace handling, get number of read passes needed - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false,png_error_message.insert(0, "error in png_set_interlace_handling(): ").c_str()); n_interlace_passes = png_set_interlace_handling(png); // update png library state to reflect any changes that were made - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_read_update_info(): ").c_str() ); png_read_update_info( png, info ); - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false,png_error_message.insert(0, "error in png_get_channels(): ").c_str()); n_channels = png_get_channels(png, info); - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false,png_error_message.insert(0, "error in png_get_rowbytes(): ").c_str()); rowsize = png_get_rowbytes(png, info); @@@@ -373,7 +377,7 @@@@ namespace vigra { void PngDecoderImpl::nextScanline() { for (int i=0; i < n_interlace_passes; i++) { - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false,png_error_message.insert(0, "error in png_read_row(): ").c_str()); png_read_row(png, row_data.begin(), NULL); } @@@@ -539,7 +543,7 @@@@ namespace vigra { vigra_postcondition( png != 0, "could not create the write struct." ); // create info struct - if (setjmp(png->jmpbuf)) { + if (setjmp(png_jmpbuf(png))) { png_destroy_write_struct( &png, &info ); vigra_postcondition( false, png_error_message.insert(0, "error in png_info_struct(): ").c_str() ); } @@@@ -550,7 +554,7 @@@@ namespace vigra { } // init png i/o - if (setjmp(png->jmpbuf)) { + if (setjmp(png_jmpbuf(png))) { png_destroy_write_struct( &png, &info ); vigra_postcondition( false, png_error_message.insert(0, "error in png_init_io(): ").c_str() ); } @@@@ -565,7 +569,7 @@@@ namespace vigra { void PngEncoderImpl::finalize() { // write the IHDR - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_set_IHDR(): ").c_str() ); png_set_IHDR( png, info, width, height, bit_depth, color_type, PNG_INTERLACE_NONE, PNG_COMPRESSION_TYPE_DEFAULT, @@@@ -573,7 +577,7 @@@@ namespace vigra { // set resolution if (x_resolution > 0 && y_resolution > 0) { - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_set_pHYs(): ").c_str() ); png_set_pHYs(png, info, (png_uint_32) (x_resolution / 0.0254 + 0.5), (png_uint_32) (y_resolution / 0.0254 + 0.5), @@@@ -582,7 +586,7 @@@@ namespace vigra { // set offset if (position.x > 0 && position.y > 0) { - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_set_oFFs(): ").c_str() ); png_set_oFFs(png, info, position.x, position.y, PNG_OFFSET_PIXEL); } @@@@ -591,12 +595,12 @@@@ namespace vigra { d17 2 a18 2 png_set_iCCP(png, info, const_cast("icc"), 0, - (char *)iccProfile.begin(), (png_uint_32)iccProfile.size()); a22 19 // write the info struct - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_write_info(): ").c_str() ); png_write_info( png, info ); @@@@ -628,10 +632,10 @@@@ namespace vigra { } // write the whole image - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_write_image(): ").c_str() ); png_write_image( png, row_pointers.begin() ); - if (setjmp(png->jmpbuf)) + if (setjmp(png_jmpbuf(png))) vigra_postcondition( false, png_error_message.insert(0, "error in png_write_end(): ").c_str() ); png_write_end(png, info); } @ 1.2 log @Update to 1.7.0, changes undocumented. Switch to cmake build system. Add comment to patch. @ text @d1 1 a1 1 $NetBSD: patch-ab,v 1.1 2010/06/13 22:44:46 wiz Exp $ d4 1 d6 1 a6 1 --- src/impex/png.cxx.orig 2008-08-13 13:15:45.000000000 +0000 d8 65 a72 1 @@@@ -270,8 +270,8 @@@@ namespace vigra { d75 1 a75 1 if (setjmp(png->jmpbuf)) d78 1 d84 144 @ 1.1 log @Bump PKGREVISION for libpng shlib name change. Also add some patches to remove use of deprecated symbols and fix other problems when looking for or compiling against libpng-1.4.x. @ text @d1 3 a3 1 $NetBSD$ @