Documentation
¶
Overview ¶
Package camera opens the RAW files of digital cameras.
A camera writes a JPEG of each photo into its RAW file, often at full size. A document gives these JPEG images as its previews (D11), and the largest one is the image that a person reviews. ivy does not decode the raw data of the sensor. A document also says the make and the model of the camera, and the date of the photo.
The package reads CR2, NEF, NRW, ARW, SRF, SR2, DNG, ORF, RW2, PEF and SRW, which are forms of TIFF, RAF of Fujifilm, and CR3 of Canon, which is a form of ISO BMFF. An ORF file keeps its large preview in the maker notes of Olympus, which the package reads too. It registers CR2, CR3, ORF, RW2 and RAF with the package image, so that image.Decode returns the largest preview. The other formats start as a plain TIFF file does, so the package does not register them, and a program opens them with Open.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var Format = ivy.Format{ Name: "camera", Mimes: []string{ "image/x-canon-cr2", "image/x-canon-cr3", "image/x-nikon-nef", "image/x-nikon-nrw", "image/x-sony-arw", "image/x-sony-srf", "image/x-sony-sr2", "image/x-adobe-dng", "image/x-olympus-orf", "image/x-panasonic-rw2", "image/x-pentax-pef", "image/x-samsung-srw", "image/x-fuji-raf", }, Exts: []string{"cr2", "cr3", "nef", "nrw", "arw", "srf", "sr2", "dng", "orf", "rw2", "pef", "srw", "raf"}, Open: func(ctx context.Context, src ivy.Source, cfg ivy.Config) (ivy.Document, error) { return Open(ctx, src, WithConfig(cfg)) }, }
Format describes the package for the registry of a program.
Functions ¶
Types ¶
type Document ¶
type Document struct {
// contains filtered or unexported fields
}
Document is an open RAW file.
func Open ¶
Open opens a RAW file. It returns an error that wraps ivy.ErrFormat if src is not a RAW file that the package reads. A file that holds no JPEG that the package decodes opens, and lists no preview.