Expand description
§flashraw-camera-db
Static camera database compiled from data/cameras.json at build time
(see build.rs). Lookups are binary searches over a sorted, normalised key
index — no parsing happens at runtime.
The database adds per-camera knowledge (crops, masked areas, black/white levels, CFA layout, colour matrices, decoder hints). Decoders must not require an entry to decode a file: standards-based metadata comes first, the database refines it.
Structs§
- Alias
Group - Rebadged / regional model names sharing a canonical model’s data.
- Camera
- A camera database entry.
- Camera
Orientation - Per-camera orientation data (see
orientationin docs/camera-db.md). - Fallback
Matrix - Fallback colour data (prefix matched), used when no exact camera entry has a matrix.
- Image
Crop - The image area a camera produces from an active area of
areasize. - Orientation
Rule - Orientation policy for a canonical make, optionally narrowed by a model prefix.
- Sensor
Info - Per-ISO sensor levels.
- Size
Rule - Sensor geometry selected by exact raw buffer size (bodies without margin metadata).
Statics§
Functions§
- all
- All entries.
- base_
model - Map a rebadged / regional model name to its canonical model (case-insensitive);
returns
modelunchanged when it is not an alias. - canonical_
make - Normalise a maker string to its canonical brand name.
- find
- Look up a camera by EXIF make/model and decoder mode. Falls back to the
default mode (
"") when no mode-specific entry exists. - find_
any - Look up a camera ignoring mode: returns the first entry for make/model.
- find_
matrix - Fallback matrix lookup by canonical make and model (first prefix match in table order, preferring the longest prefix on ties of the same make).
- orientation_
policy - Orientation policy name for a camera: its own override, else the longest matching
make/model-prefix rule, else
"exif-only". - size_
rule - Geometry rule for a canonical make and exact raw buffer size.