Skip to main content

Module preview

Module preview 

Source
Expand description

The bench’s session: one decode, many previews of it.

A darkroom does not re-read the photograph every time the timer moves. The app used to: each preview decoded the camera file, resized it, rendered and wrote a PNG, and the window decoded the PNG again. The decode was the cost — a 26-megapixel file takes longer to read than a bench-sized render takes to draw — and it bought nothing, because every preview of one strip is the same photograph.

A session is that knowledge held for as long as the strip is on the bench. It decodes once, meters once, and hands back the pixels of any development, print exposure, filter pack or heat glass. It also keeps the last few frames: dragging the ruler past a time and back again is a thing people do, and the frame they saw a moment ago is already made.

What a session returns is the print the model would write, not an approximation of it: crate::render_image runs the same pipeline, and kallo_io::to_rgba8 is the encoding kallo_io::save uses.

Structs§

PreviewFrame
One bench frame, already encoded the way a window wants it.
PreviewRequest
What a preview session is opened on.
PreviewSession
A photograph held on the bench, ready to be printed at any setting.