summaryrefslogtreecommitdiff
path: root/README
blob: 242a0a26afa277ce96ec1b45b66bed094dfd0593 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
Copyright
=========

libopenraw is Copyright (c) 2005-2024 Hubert Figuière and
other contributors. See the respective files.
It is licensed under LGPLv3 or later. See files COPYING
and COPYING.LESSER

Code below src/mp4/parse is released under MPL-2.0 license. See the
MPL-2.0 file.  It is a modified version of
https://github.com/mozilla/mp4parse-rust

Code of Conduct:
================

Contributors to this project agree to the Freedesktop.org Code of
Conduct:

  https://www.freedesktop.org/wiki/CodeOfConduct/

Prerequistes to build:
======================

    - a C++ 11 compiler (tested on gcc 4.7 and up)
    - libboost 1.33.1 (Boost.String, Boost.Test, Boost.Variant)
    - libjpeg
    - libxml > 2.5.0 (for the test suite)
    - libcurl (option for the test suite bootstrap)
    - Rust 1.64

If building from the git tree you also need:

    - automake/autoconf
    - autoconf-archive
    - pkg-config for the associated m4 macros

Optional Gnome support

    - gdkpixbuf

## Rust crate

Starting with 0.4.0, libopenraw is developed as a Rust native crate
with a C API. There the standard layout for a Rust crate applies, and
`lib/` contains the crate part to build the dynamic library for the C
API.

Supported file format:
======================

Here are the supported file formats. For details per-camera, see
below:

    - Canon CR2
    - Canon CR3
    - Canon CRW (not those coming from CHDK firmware like A610)
    - Nikon NEF and NRW
    - Olympus ORF
    - Pentax PEF
    - Epson ERF
    - DNG
    - GoPro GPR
    - Sony ARW and SR2
    - Minolta MRW
    - Panasonic RAW and RW2
    - Fujifilm RAF

How to build:
=============

  Using automake/autoconf:

    $ ./autogen.sh
    $ ./configure --prefix=...
    $ make
    $ make install DESTDIR=...


Supported formats:
==================

  T  Tested and proven to work. (I have a sample.)
  Y  Yes, it is there. (Untested as I do not have a sample but the format
     is known to be similar.) Yes, it is for the whole format.
  N  Not supported.
  B  Known to be Broken. (Needs to be fixed. I have a sample but further
     work is required.)
  X  Not needed.
  #  Sample file needed.

                          ThNail
                         /  CFA compressed bitstream
                         | /  CFA decompress
                         | | /  Orientation Tag
                         | | | /  Bayer Type
                         | | | | /  Type ID
                         | | | | | /  Active Area (ROI)
                         | | | | | | /  Color Matrices
                         | | | | | | | /  Exif and MakerNotes
                         | | | | | | | | /  Rendering
                         | | | | | | | | | /
                         | | | | | | | | | |
Canon CR2                Y Y Y Y Y Y Y Y Y Y
Canon CR3                Y Y N Y Y Y Y Y Y N
Canon CRW                Y Y Y Y Y Y Y Y Y B

Canon CRW CHDK           N N N N N N N N N N
(unofficial firmware)


Nikon NEF                Y Y Y Y Y Y N Y Y
Nikon NRW                Y         Y N Y Y
Olympus ORF              Y Y Y Y Y Y N Y Y
Adobe DNG                Y Y B Y Y Y Y Y Y Y
GoPro GPR                Y Y N Y Y Y Y Y X N
Sony SR2                 Y Y N Y N Y N Y   B
Sony ARW                 Y Y N Y N Y N Y Y
Pentax PEF               Y Y N Y Y Y N Y Y Y
Epson ERF                Y Y Y Y Y Y N Y Y Y
Minolta MRW              Y Y Y N Y Y N Y Y Y
Panasonic RAW            Y Y N Y Y Y Y N Y B
Panasonic RW2            Y Y N Y Y Y Y N Y N
FujiFilm RAF             Y Y N Y N Y N T Y B


Unsupported
-----------
Sony SRF                 N N N N N N N N
Kodak DCR                N N N N N N N N
Kodak KDC                N N N N N N N N
Foveon X3F               N N N N N N N N
Mamiya MEF               N N N N N N N N
Samsung SRW              N N N N N N N N


Test suite
==========

There is a test suite driven by an XML file. It require you to provide
your own RAW files and configure it.  testsuite/testsuite.xml is an
example of valid XML configuration file that works on my local
machine.

TODO2: provide a better description of the test file.

TODO3: fix ordiag to allow outputting a test case in XML.

Running the testsuite
---------------------

$ make check

This will run it automatically.

If you need to bootstrap the testsuite, you can go as follow:

WARNING: The bootstrap will download "random" files from the
internet. They currently aren't validated.

$ make
$ cd testsuite
$ ./testsuite -b -d directory

Here directory is the existing directory where files will be
downloded.  If you build in a different directory than the source
directory, you need to set the `srcdir` environment to the path where
the testsuite binary is build.


References
==========

Many online resources, including open source software were used (list
non exhaustive):

dcraw was the first open source effort out there. We all owe its
authors and contributor a lot.

CR3
---
Mozilla MP4 Rust parser, that is being used:
  https://github.com/mozilla/mp4parse-rust/
Laurent Clevy CR3 documentation, provided lot of information:
  https://github.com/lclevy/canon_cr3

Exif & MakerNote
----------------
ExifTool is used to provide documentation and the tag table:
  https://exiftool.org/
  https://exiftool.org/makernote_types.html
Exiv2 knowledge:
  https://www.exiv2.org/makernote.html
libexif:
  https://libexif.github.io/
exifprobe:
  https://github.com/hfiguiere/exifprobe/