LibRaw technical support

Stable LibRaw versions: technical support, errors, API questions

random Crash with CRW file in memory stream

Hi.
I've found a random crash with MemoryStream and CR2.
The file is downloaded from edsdk api and i use open_buffer to unpack image.
I try to found it. It's like datastream make memory erro whith cr2 file. Crash always appear on memchr in libraw_datastream.h :

int get_ljpeg_byte() {
        if(offt<next_ff) return buf[offt++];
        int ret = buf[offt++];
        if(ret == 0xff) { if(buf[offt]==0x00) offt++; else return 0;}
        // find next 0xff
        unsigned char *p = (unsigned char*) memchr(buf+offt,0xff,size-offt);
        if(p)
            next_ff = p-buf;

Forums: 

need help making local port on OSX

I would like to make a local build of libraw into my macports distribution. If anyone can help, I would appreciate it. The portfile is:
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4
# $Id$
PortSystem 1.0
name LibRaw
version 0.13.0-Beta3
categories graphics
platforms darwin
maintainers wyatt \
digitalcave.ca:wyatt

Forums: 

Build of 0.13-beta3 on most recent Mac OSX 10.6

When I run ./configure, the package files built for libraw and libraw_r still have the line "Requires: @PACKAGE_REQUIRES@" still in them (in other words, PACKAGE_REQUIRES has not been set). Is there something wrong with the automake scripts?

I am running with the latest macports and OSX versions. I am compiling with the standard gcc, not gcc4.5.

Forums: 

LibRaw using CodeBlocks

Hi all,

I am currently trying to compile the test examples mem_image.cpp with code::blocks software and I get some undefined reference problems:

undefined reference to `__getreent'
undefined reference to `__errno'
undefined reference to `fseeko'
undefined reference to `ftello'
undefined reference to `getc_unlocked'

I was wondering if there was any compiler flag I have to add to code blocks mingw compiler to resolve them, but I can't find any lib in CodeBlocks/MinGW folder that solves the problem.

Forums: 

[patch] fix build with lcms2

The attached patch fixes the build with lcms2.

The issue was that configure created variables LCMS_* or LCMS2_* depending on the lcms/lcms2 version, but the Makefile was always expecting LCMS_*. I've fixed it by always setting LCMS_*. This is allowed as per the PKG_CHECK_MODULES documentation (http://www.flameeyes.eu/autotools-mythbuster/pkgconfig/pkg_check_modules...) and keeps the Makefile simple.

Forums: 

link order

compiling from git gives following error:
g++ -fPIC -fopenmp -L/opt/local/lib64 -llcms2 -o bin/raw-identify samples/bin_raw_identify-raw-identify.o -Llib/ -lm -lraw
lib//libraw.a(lib_libraw_a-dcraw_fileio.o): In function `LibRaw::apply_profile(char const*, char const*)':
dcraw_fileio.cpp:(.text+0xae9): undefined reference to `cmsOpenProfileFromFile'
dcraw_fileio.cpp:(.text+0xb1c): undefined reference to `cmsOpenProfileFromMem'
dcraw_fileio.cpp:(.text+0xb60): undefined reference to `cmsCreate_sRGBProfile'

Forums: 

libraw in a DSO plug-in

Happy new year to all,

The Oyranos project has some plugins, which work as shared libraries. These libraries need to link in libraw.a, in order to use the LibRaw functionality for conversion and ICC profile assignment.

However on 64-bit machines the gcc compiler says:
linux/bin/ld: /usr/lib64/libraw.a(lib_libraw_a-libraw_cxx.o): relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC

The issue is nicely described here:
http://www.gentoo.org/proj/en/base/amd64/howtos/index.xml?part=1&chap=3

Forums: 

[patch] pkg-config fixes

Attached you can find a patch that fixes the following problems with the pkg-config files:

* The version number was fixed at 0.9.1. It is now taken from ./version.sh.
* The "Requires:" field was fixed to "lcms" even if lcms2 or nothing is used. It is now set to "lcms", "lcms2" or empty as appropriate.
* The lcms dependency libraries were duplicated in the "Libs" field. This is not necessary, the "Requires" field takes care of that.

Forums: 

crash decoding SIGMA DP1 .X3F image

The application I am working on (Luminance HDR) crashes trying to decode a RAW image from SIGMA DP1 camera (file extension .X3F).

Library version is LibRaw-0.12.0-Beta4 with LibRaw-demosaic-pack-GPL2-0.12.0-Beta4

Here is the gdb output:

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x7fffeab37710 (LWP 21659)]
LibRaw::foveon_interpolate (this=0x7fffeab09ad0) at ../LibRaw-demosaic-pack-GPL2-0.12.0-Beta4/dcraw_foveon.c:389
389 FORC3 ddft[i+1]

[1] += (short) image[row*width+col][c];
 
 
Hope this can help you

Forums: 

Pages

Subscribe to RSS - LibRaw technical support