pub struct CudaEncodeStageAccelerator { /* private fields */ }Expand description
CUDA implementation of selected JPEG 2000 encode stages.
Implementations§
Source§impl CudaEncodeStageAccelerator
impl CudaEncodeStageAccelerator
Sourcepub fn for_auto_host_output() -> Self
pub fn for_auto_host_output() -> Self
Create the measured Auto route for host-output HTJ2K encode.
CUDA keeps the DWT and HT code-block stages, while forward RCT and Tier-2 packetization stay on the CPU for the current host-pixel path.
Sourcepub fn prefer_cpu_forward_rct(self, prefer_cpu_forward_rct: bool) -> Self
pub fn prefer_cpu_forward_rct(self, prefer_cpu_forward_rct: bool) -> Self
Prefer scalar CPU forward RCT while keeping later CUDA stages enabled.
Sourcepub fn prefer_cpu_packetization(self, prefer_cpu_packetization: bool) -> Self
pub fn prefer_cpu_packetization(self, prefer_cpu_packetization: bool) -> Self
Prefer scalar CPU Tier-2 packetization while keeping CUDA Tier-1/HT block coding enabled.
This is useful for batches of many small tiles where launching a CUDA packetization kernel and copying several tiny descriptor buffers per tile costs more than forming the packet body on the host.
Sourcepub fn prefer_cpu_ht_subband(self, prefer_cpu_ht_subband: bool) -> Self
pub fn prefer_cpu_ht_subband(self, prefer_cpu_ht_subband: bool) -> Self
Prefer host sub-band quantization while keeping batched CUDA HT code-block encode enabled.
This avoids launching one CUDA quantize/subband path for every prepared subband in multi-resolution precomputed transcode outputs, where the many tiny launches cost more than CPU quantization.
Sourcepub fn prefer_cpu_quantize_subband(
self,
prefer_cpu_quantize_subband: bool,
) -> Self
pub fn prefer_cpu_quantize_subband( self, prefer_cpu_quantize_subband: bool, ) -> Self
Prefer host sub-band quantization while keeping CUDA HT code-block encode enabled.
Multi-resolution transcode workloads can contain thousands of small subbands; for those, CPU quantization plus one batched HT code-block encode per tile is currently faster than launching CUDA quantization for every subband.
Sourcepub const fn collected_stage_timings(&self) -> CudaEncodeStageTimings
pub const fn collected_stage_timings(&self) -> CudaEncodeStageTimings
Return cumulative CUDA encode stage timings collected by this accelerator.
Sourcepub fn reset_collected_stage_timings(&mut self)
pub fn reset_collected_stage_timings(&mut self)
Clear cumulative CUDA encode stage timings without changing dispatch counters.
Trait Implementations§
Source§impl Clone for CudaEncodeStageAccelerator
impl Clone for CudaEncodeStageAccelerator
Source§fn clone(&self) -> CudaEncodeStageAccelerator
fn clone(&self) -> CudaEncodeStageAccelerator
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for CudaEncodeStageAccelerator
impl Debug for CudaEncodeStageAccelerator
Source§impl Default for CudaEncodeStageAccelerator
impl Default for CudaEncodeStageAccelerator
Source§fn default() -> CudaEncodeStageAccelerator
fn default() -> CudaEncodeStageAccelerator
Auto Trait Implementations§
impl Freeze for CudaEncodeStageAccelerator
impl RefUnwindSafe for CudaEncodeStageAccelerator
impl Send for CudaEncodeStageAccelerator
impl Sync for CudaEncodeStageAccelerator
impl Unpin for CudaEncodeStageAccelerator
impl UnsafeUnpin for CudaEncodeStageAccelerator
impl UnwindSafe for CudaEncodeStageAccelerator
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more