Expand description
Shared traits and value types for the signinum workspace.
Codec crates use this crate to expose common pixel formats, decode outcomes, row sinks, caller-owned scratch pools, and CPU/GPU backend selection contracts without depending on each other.
Re-exports§
pub use accelerator::AcceleratorSession;pub use accelerator::BackendFailureKind;pub use accelerator::DeviceMemoryRange;pub use accelerator::ExecutionStats;pub use accelerator::GpuAbi;pub use accelerator::SurfaceResidency;pub use backend::BackendCapabilities;pub use backend::BackendKind;pub use backend::BackendRequest;pub use backend::CpuFeatures;pub use batch::collect_indexed_batch_results;pub use batch::tile_batch_worker_count;pub use batch::IndexedBatchResult;pub use batch::TileBatchError;pub use batch::TileBatchOptions;pub use batch::TileDecodeJob;pub use batch::TileRegionDecodeJob;pub use batch::TileRegionScaledDecodeJob;pub use batch::TileScaledDecodeJob;pub use context::CacheStats;pub use context::CodecContext;pub use context::DecoderContext;pub use device::validate_cuda_surface_backend_request;pub use error::BufferError;pub use error::CodecError;pub use error::InputError;pub use error::NotImplemented;pub use error::Unsupported;pub use passthrough::CompressedPayloadKind;pub use passthrough::CompressedTransferSyntax;pub use passthrough::PassthroughCandidate;pub use passthrough::PassthroughDecision;pub use passthrough::PassthroughRejectReason;pub use passthrough::PassthroughRequirements;pub use pixel::PixelFormat;pub use pixel::PixelLayout;pub use row_sink::RowSink;pub use sample::Sample;pub use sample::SampleType;pub use scale::Downscale;pub use scratch::ScratchPool;pub use traits::submit_ready_device;pub use traits::DecodeRowsError;pub use traits::DeviceSubmission;pub use traits::DeviceSubmitSession;pub use traits::DeviceSurface;pub use traits::ImageCodec;pub use traits::ImageDecode;pub use traits::ImageDecodeDevice;pub use traits::ImageDecodeRows;pub use traits::ImageDecodeSubmit;pub use traits::ReadySubmission;pub use traits::TileBatchDecode;pub use traits::TileBatchDecodeDevice;pub use traits::TileBatchDecodeManyDevice;pub use traits::TileBatchDecodeSubmit;pub use traits::TileDecompress;pub use types::CodedUnitLayout;pub use types::Colorspace;pub use types::DecodeOutcome;pub use types::DecodeRequest;pub use types::Info;pub use types::Rect;pub use types::TileLayout;pub use types::WarningKind;
Modules§
- accelerator
- Shared accelerator runtime contracts.
- backend
- Backend selection and capability discovery.
- batch
- Shared helpers for ordered tile-batch work.
- context
- Reusable codec context wrappers.
- device
- Shared device-output request policies.
- error
- Common error classifications and helper error types.
- passthrough
- Compressed-byte passthrough eligibility checks.
- pixel
- Pixel layout and format descriptors.
- row_
sink - Row-streaming output sink trait.
- sample
- Integer sample type descriptors.
- scale
- Decode downscale options.
- scratch
- Caller-owned scratch pool trait.
- traits
- Facade traits implemented by codec crates.
- types
- Shared metadata and geometry types.
Constants§
- DEFAULT_
MAX_ HOST_ ALLOCATION_ BYTES - Default cap for host-side codec-owned allocations.
Functions§
- copy_
tight_ pixels_ to_ strided_ output - Copy tightly packed pixel rows into a caller-provided strided output buffer.
- ensure_
allocation_ within_ cap - Returns
lenif it is at or belowcap. - strided_
output_ len - Returns the number of bytes required for a strided image output buffer.
- strided_
output_ len_ capped - Returns the strided output byte length, rejecting requests over
cap. - validate_
strided_ output_ buffer - Validates that
out_lenandstridecan hold an image output.