fovea-display
fovea-display provides display strategies, GPU texture metadata, and optional debug windows for fovea images.
[]
= "0.1.1"
= "0.1.1"
Enable the development-only window viewer with:
[]
= { = "0.1.1", = ["debug-window"] }
Features
| Feature | Enabled APIs | Dependencies | Intended use |
|---|---|---|---|
| (default) | DisplayStrategy, Identity, LinearToDisplay, AutoContrast, TextureSource |
fovea, log |
Conversion and rendering integration without a windowing dependency. |
debug-window |
show, DebugDisplay, histogram debug windows |
winit, softbuffer |
Quick local inspection during development. |
Quick start
Convert a typed fovea pixel to a display-ready Srgba8 value with an explicit strategy:
use ;
use ;
let px = new;
let display = Identity.to_display;
assert_eq!;
With the debug-window feature enabled, inspect an image interactively:
use Image;
use Srgb8;
use ;
let img = fill;
show;
Display strategies
Every display operation names how image data becomes screen-ready RGBA pixels. There is no silent default mapping for high-bit-depth, linear-light, or HDR data.
| Strategy | Use case |
|---|---|
Identity |
sRGB pixels that are already display encoded. |
LinearToDisplay |
Linear-light pixels that need sRGB gamma encoding for a standard display. |
AutoContrast |
Scan an image and stretch its value range for debugging or inspection. |
FixedRange |
Map a caller-specified numeric range into display values. |
Design notes
show()accepts anyImageView, so owned images, ROIs, and custom image backends can be displayed.TextureSourcerequires contiguous byte access viaPlainImage, which is the stronger bound needed for GPU upload.- Display conversion is strategy-based to keep colour-space and range decisions explicit.
Part of the fovea project
- Core crate:
fovea - Codec support:
fovea-io - End-to-end demos:
fovea-examples
License
Licensed under the MIT License.