Recent comments

Reply to: ImageMagick signatures are different when using 0.20.2 vs 0.21.1   1 year 5 months ago

Yes, one of *image pointer in libraw_rawdata_t will be non-zero after LibRaw::unpack() and will contain imgdata.sizes.raw_height rows, imgdata.sizes.raw_width items each, with imgdata.sizes.raw_pitch byte pitch.

Reply to: Not able to use Libraw 0.21.1 for intel mac   1 year 5 months ago

it looks like 'your file from another computer' is dynamically linked with libraw.23.dylib

We do not provide dynamic LibRaw for macOS, make -f Makefile.dist will also create static library only.

Please contact the 'file from another computer' vendor for libraw.23.dylib library

Reply to: ImageMagick signatures are different when using 0.20.2 vs 0.21.1   1 year 5 months ago

Ahh thanks, I think you just helped me understand something.

I haven't checked, but I'm almost certain you're right about it using the rendered image. My understanding is that ImageMagick delegates all the decoding to libraw, libjpeg, libtiff, libpng, etc., and in my case it doesn't necessarily know it's dealing with a RAW image by the time it creates the signature.

So let's say I wanted to write my own signature program using LibRaw that only operates on the image data, leaving the metadata completely out of it. After a quick look at the API, my best guess is that I'd want to hash the contents of libraw_rawdata_t. Does that sound right?

Reply to: ImageMagick signatures are different when using 0.20.2 vs 0.21.1   1 year 5 months ago

Sorry, we do not know how identify -verbose tool works. Is that possible that it checksums not RAW data but rendered image?

Reply to: Panasonic Lumix DC GH6 raw RW2 support   1 year 5 months ago

We'll release LibRaw with GH6 support on schedule: https://www.libraw.org/#updatepolicy

Reply to: Panasonic Lumix DC GH6 raw RW2 support   1 year 5 months ago

If you download a trial of RawDigger at https://www.rawdigger.com/download you can open a GH6 raw file now. RawDigger is a for-purchase product of LibRaw, correct (it says LibRaw LLC in the footer of the site page).

Any chance someone from LibRaw can answer the question, "if RawDigger now supports GH6, does that mean that a current or soon to be released update to LibRaw will have support for the GH6 .RW2 format?"

Reply to: Fuji X-Trans files opening slow   1 year 5 months ago

> Processing X-Trans files takes much longer than processing Bayer files.

This is expected. If lower quality is acceptable for your task you may switch from (default) 3-pass Markesteijn to 1-pass or to linear approximation.

Reply to: Fuji X-Trans files opening slow   1 year 5 months ago

Hi,
I'm having the same issues with libraw. Processing X-Trans files takes much longer than processing Bayer files.
I'm using the C-API version "0.19.5-Release".
I used the default params (I don't now which interpolation algorithm it is using). I tried digging into the source code to see whats going on, but couldn't figure out what exactly takes that much time in the libraw_dcraw_process call.
Here a few logs:

Opening file: "test.RAF"
libraw_open_file: 2.4638ms
libraw_unpack: 331.530498ms
libraw_dcraw_process: 18.465117336s
libraw_dcraw_make_mem_image: 258.297201ms
tiff.write_image: 64.792601ms (not libraw-function)

Opening file: "test.CR2"
libraw_open_file: 3.3209ms
libraw_unpack: 657.3599ms
libraw_dcraw_process: 720.410201ms
libraw_dcraw_make_mem_image: 63.3256ms
tiff.write_image: 50.7873ms (not libraw-function)

Has anyone looked into this problem already?

Thanks in advance

Reply to: Libraw Android Port on GitHub   1 year 5 months ago

How can I install this library on Android Studio? What documents or folders should I copy or import?

Reply to: lossy compression decoding   1 year 5 months ago

Thank you. I understand.

Reply to: lossy compression decoding   1 year 5 months ago

Yes, pixel values are above 16383 and this is normal for this type of files.

Reply to: lossy compression decoding   1 year 5 months ago

The original data already exceeds 16383,
Data:
======x:3078,y:1969,pSrcPix:16404,pDstPix:80
======x:3080,y:1969,pSrcPix:16404,pDstPix:80
======x:3082,y:1969,pSrcPix:16404,pDstPix:80
======x:3084,y:1969,pSrcPix:16404,pDstPix:80
======x:3086,y:1969,pSrcPix:16404,pDstPix:80
======x:3088,y:1969,pSrcPix:16404,pDstPix:80
======x:3073,y:1970,pSrcPix:16404,pDstPix:80
======x:3075,y:1970,pSrcPix:16404,pDstPix:80
======x:3077,y:1970,pSrcPix:16404,pDstPix:80
======x:3079,y:1970,pSrcPix:16404,pDstPix:80
======x:3081,y:1970,pSrcPix:16404,pDstPix:80
======x:3083,y:1970,pSrcPix:16404,pDstPix:80
======x:3085,y:1970,pSrcPix:16404,pDstPix:80
======x:2962,y:1971,pSrcPix:16404,pDstPix:80
======x:2964,y:1971,pSrcPix:16404,pDstPix:80
======x:2966,y:1971,pSrcPix:16404,pDstPix:80
======x:2968,y:1971,pSrcPix:16404,pDstPix:80
======x:2970,y:1971,pSrcPix:16404,pDstPix:80
======x:2972,y:1971,pSrcPix:16404,pDstPix:80
======x:2965,y:1972,pSrcPix:16404,pDstPix:80

Reply to: lossy compression decoding   1 year 5 months ago

I did not perform any operations on the data

Are you absolutely sure? What do you think the bitwise left shift operator does?

Reply to: lossy compression decoding   1 year 5 months ago

In fact, I did not perform any operations on the data.

int bitOffset = 2;
int out_height = 4024;
int out_width= 6024;
int out_rect.y = 0;
int out_rect.x = 0;
int dwBufLen = out_width * 3 * out_height;

unsigned char *szImgBuff = new (nothrow) unsigned char[dwBufLen];
unsigned short *pSrc = (unsigned short *)rawProcessor->imgdata.rawdata.raw_image;
if (!pSrc)
{
printf("error raw_image is null\n");
return false;
}

unsigned short *pDst = (unsigned short *)szImgBuff;
unsigned short *pDstPix = NULL;
unsigned short *pSrcPix = NULL;
pSrc += out_rect.y * raw_width + out_rect.x;
pDstPix = (unsigned short *)szImgBuff;
for (int y = 0; y < out_height; y++)
{
pSrcPix = pSrc;
pDstPix = pDst;
for (int x = 0; x < out_width; x++, pSrcPix++, pDstPix++)
{
*pDstPix = (*pSrcPix << bitOffset);
}

pSrc += raw_width;
pDst += out_width;
}
outfile.close();
FILE *fp1 = fopen("DSC07102", "wb+");
fwrite(szImgBuff, 1, dwBufLen, fp1);
fclose(fp1);

Reply to: lossy compression decoding   1 year 5 months ago

I think you need to remove data scaling from your code or adjust it based on real source data range, not any assumptions.

In this particular case: assuming that source data is within 0..2^14-1 range is incorrect.

Reply to: lossy compression decoding   1 year 5 months ago

Thank you, I think I need to take a look RawDigger.

Reply to: lossy compression decoding   1 year 5 months ago

This is RawDigger settings, described in RD user manual.

If you use LibRaw's imgdata.rawdata.raw_image values: this is unaltered values, no scaling, no black subtraction.

And, indeed, data range for the file you sent is 0...16500, not 0....65535(and above), so please remove scaling from the code you use.

Reply to: lossy compression decoding   1 year 5 months ago

What do I need to do to open (black subtraction is on)

Reply to: lossy compression decoding   1 year 5 months ago

Sorry I didn't understand your question

Reply to: lossy compression decoding   1 year 5 months ago

(black subtraction is off) Will opening improve,How to open it ?

Reply to: lossy compression decoding   1 year 5 months ago

Here is RawDigger's 'Overexposure areas' with overexposure level set to 16383 (black subtraction is off), looks very similar to the photo you sent me: https://www.dropbox.com/s/y9he0u67dm1bgvs/Screenshot%202023-04-24%2012.0...

Reply to: lossy compression decoding   1 year 5 months ago

Here is RAW data histogram of the RAW image you sent: https://www.dropbox.com/s/bapkupc7bw3m220/Screenshot%202023-04-24%2012.0...
(black subtraction is turned off).

As you can see, the maximum value is 16500, slightly above 16383 (2^14-1)

If you scale data before recording by multiplying to 4 (to get 65535 range you mentioned above) this will result into 16-bit overflow.

If you do NOT scale data you'll never see ~65535 range because camera data range is (about) 0-2^14

Reply to: lossy compression decoding   1 year 5 months ago

get unsigned short* pSrc = rawProcessor->imgdata.rawdata.raw_image, Loop through length and width, and offset pSrc by two bytes to the left. I will send a photo of the results to your email.

Reply to: lossy compression decoding   1 year 5 months ago

Here is your file converted via dcraw_emu -T -w: https://www.dropbox.com/s/ipedoyrum83pfqp/DSC07102.ARW.tif?dl=0

I do not see any problem with decoding/rendering.

I do not know how your decoded file is created, have not seen into it, so could not comment.

Reply to: lossy compression decoding   1 year 5 months ago

The email has been successfully sent.
Original file: DSC07102.ARW
Decoded Files: DSC07102 ,Decoding files can be opened using imagej. width x height 6024x4024

Pages