Questions tagged [libraw]

LibRaw is a library for reading RAW files from digital photo cameras (CRW/CR2, NEF, RAF, DNG, MOS, KDC, DCR, etc.; virtually all RAW formats are supported).

LibRaw is a library for reading RAW files from digital photo cameras (CRW/CR2, NEF, RAF, DNG, MOS, KDC, DCR, etc.; virtually all RAW formats are supported). It pays special attention to correct retrieval of data required for subsequent RAW conversion.

The library is intended for embedding in RAW converters, data analyzers, and other programs using RAW files as the initial data.

Home: http://www.libraw.org/

26 questions
7
votes
3 answers

Why is cv::Mat::data always pointing to a uchar?

I try to read a NEF file using LibRaw and then put it in a cv::Mat. The NEF file stores data as 12bit, this means I need 16 bit, so I ought to use CV_16UC4 like this: Mat img1(height, width, CV_16UC4); Libraw stores data as ushort*[4], so I thought…
Andrei
  • 961
  • 1
  • 9
  • 29
6
votes
1 answer

Libraw is making my images too bright compared to nikons own converter

It seems that nikons own tool and photoshop has the option to open the image as they was taken. but using libraws dcraw processor I cant figure this out. here is my implementation. CV_EXPORTS_W int load_image(const char * path, cv::Mat &…
Poul K. Sørensen
  • 16,950
  • 21
  • 126
  • 283
4
votes
0 answers

DeBayering a Canon CR2 image with OpenCV

What I'm trying to do is read a .cr2 RAW file taken on my Canon Rebel T5 1200D. I'm able to load and display the image using LibRaw and OpenCV, but the image appears to be slightly too bright and a bit more yellow than it does when I open the file…
mynameisjohnj
  • 421
  • 4
  • 12
4
votes
2 answers

Python rawkit how read metadata values from RAW file?

I'm writing python script and I need to obtain exif information from raw photo file (.CR2 for example). I found Python Rawkit offer the ability to do that. with Raw(filename=image_path) as raw: print…
zipper
  • 58
  • 1
  • 6
3
votes
1 answer

Rawpy raw image pattern

I'm trying to read and demosaic raw images in Python using the RawPy module. Unfortunately the module does not provide simple demosaic method, but a complete postprocess function which is not suitable for my case since I want to keep the floating…
Zarrie
  • 325
  • 2
  • 16
2
votes
2 answers

How to wrap external paths (include, lib) and definitions into a target in cmake

Rather than providing a target, some libraries like LibRaw generate variables that contain information about include paths, library paths and compile definitions. In the case of LibRaw, vcpkg recommends the following…
DrPepperJo
  • 632
  • 1
  • 5
  • 19
2
votes
2 answers

Understanding the output of raw_pattern in rawpy

I have the following two examples when loading 2 different raw images (one with Nikon and another with Sony Both having Bayer filters): Can someone please explain the meaning of the output of the raw_pattern here along with difference in the…
KCK
  • 2,015
  • 2
  • 17
  • 35
2
votes
1 answer

LibRaw and OpenCV

I use a Canon EOS 1200D. This camera creates JPEG files with a resolution of 5184 x 3456. The camera creates also CR2 files. I use LibRaw to open this file. LibRaw processor; processor.open_file("test1.CR2"); If i debug my program i can…
artoon
  • 729
  • 2
  • 14
  • 41
1
vote
0 answers

Reading Raw image with libraw and converting to DNG with libtiff

I am reading RAW files (usually NEF format) using Libraw and everything seems ok. After some processing, I need to save the RAW image as a DNG file. However, when I open the DNG file with Photoshop, the colors seem wrong. For finding the CFA…
user3178756
  • 555
  • 1
  • 5
  • 17
1
vote
2 answers

Convert Raw image to JPG

I have the following issues when I try to run: the input would be something like file=/Downloads/canon_eos_70d_20.CR2 with Raw(file) as raw_image: buffered_image = np.array(raw_image.to_buffer()) im = Image.frombuffer('RGB',…
1
vote
1 answer

Meaning of output_bps in rawpy.Params

I am new to image processing world and want to use the rawpy library for processing some images. I came across output_bps param in the postprocess function which does not have any explanation associated in the docs:…
KCK
  • 2,015
  • 2
  • 17
  • 35
1
vote
0 answers

How to demosaic a picamera raw image with rawpy?

I am attempting to stack long exposures from a Pi NoIR camera. The picamera raw format can be unpacked into a numpy array based on the example: http://picamera.readthedocs.io/en/release-1.10/recipes2.html#raw-bayer-data-captures How can this numpy…
Ian
  • 21
  • 4
1
vote
0 answers

Node-gyp trying to compile libraw as a dependency

I'm trying to compile libraw as a dependency for my node.js project. I have two different .gyp files: ./binding.gyp and ./vendor/raw.gyp I have downloaded the current version of libraw and the demosaicing packs, all of them can be found on the…
m0g
  • 115
  • 1
  • 14
0
votes
1 answer

ImageMagick won't thumbnail .cr3 photos. Libraw not working?

So I am having some trouble with ImageMagick. It won't work with raw images for. I was told I need to install Libraw. After reporting a bug on Github was told that Libraw wasn't installed I have tried this commands to install Libraw and still…
0
votes
0 answers

Undefined refrences to '__imp' and '__cxa' when linking libraw

I'm trying to link the c++ library, libraw, into my c program. windows 10 msys2. Using clion, but also trying to compile from mingw64 terminal using gcc and clang At first, I was using the version of libraw that i got from msys2 pacman. The issue is…
1
2