pub struct OpticastSettings {
pub xres: u32,
pub yres: u32,
pub y_start: u32,
pub y_end: u32,
pub hx: f32,
pub hy: f32,
pub hz: f32,
pub anginc: f32,
pub mip_levels: u32,
pub mip_scan_dist: i32,
pub max_scan_dist: i32,
}Expand description
Per-frame settings the renderer forwards through its passes. Most
fields map onto a classic raycaster control: (hx, hy, hz) are the
pinhole projection centre + focal length (the voxlap setcamera
dahx/dahy/dahz), mip_* drive the distance-mip ladder, and
max_scan_dist bounds the ray.
y_start..y_end is the strip-render iteration bound. Default is the
full framebuffer (0..yres). Tile / strip callers set a sub-range
to render only that horizontal strip; the projection centre stays in
absolute screen coords, only the viewport edges shrink.
Fields§
§xres: u32§yres: u32§y_start: u32First y-row this render call covers (inclusive). 0 for
full-frame.
y_end: u32One past the last y-row (exclusive). yres for full-frame.
hx: f32§hy: f32§hz: f32§anginc: f32§mip_levels: u32§mip_scan_dist: i32§max_scan_dist: i32Implementations§
Source§impl OpticastSettings
impl OpticastSettings
Sourcepub fn for_oracle_framebuffer(width: u32, height: u32) -> Self
pub fn for_oracle_framebuffer(width: u32, height: u32) -> Self
Default settings for a width × height framebuffer with the
convention (hx, hy, hz) = (w/2, h/2, w/2) and anginc = 1.
Renders the full frame (y_start = 0, y_end = height).
Sourcepub fn with_y_range(self, y_start: u32, y_end: u32) -> Self
pub fn with_y_range(self, y_start: u32, y_end: u32) -> Self
Restrict this settings struct to the [y_start, y_end)
horizontal strip. Used by the per-strip parallel dispatch — each
strip clones the base settings and clamps the y-range. Caller is
responsible for ensuring y_start < y_end <= yres.
Trait Implementations§
Source§impl Clone for OpticastSettings
impl Clone for OpticastSettings
Source§fn clone(&self) -> OpticastSettings
fn clone(&self) -> OpticastSettings
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for OpticastSettings
Auto Trait Implementations§
impl Freeze for OpticastSettings
impl RefUnwindSafe for OpticastSettings
impl Send for OpticastSettings
impl Sync for OpticastSettings
impl Unpin for OpticastSettings
impl UnsafeUnpin for OpticastSettings
impl UnwindSafe for OpticastSettings
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