pub struct VolumeRenderParamsBuilder { /* private fields */ }Expand description
Fluent builder for VolumeRenderParams.
Implementations§
Source§impl VolumeRenderParamsBuilder
impl VolumeRenderParamsBuilder
Sourcepub fn blend_mode(self, blend_mode: BlendMode) -> Self
pub fn blend_mode(self, blend_mode: BlendMode) -> Self
Set the blend mode.
Sourcepub fn interpolation(self, interpolation: Interpolation) -> Self
pub fn interpolation(self, interpolation: Interpolation) -> Self
Set the texture interpolation mode.
Sourcepub fn shading(self, params: ShadingParams) -> Self
pub fn shading(self, params: ShadingParams) -> Self
Enable Phong shading with the given parameters.
Sourcepub fn no_shading(self) -> Self
pub fn no_shading(self) -> Self
Disable shading.
Sourcepub fn step_size_factor(self, step: f32) -> Self
pub fn step_size_factor(self, step: f32) -> Self
Set the raycasting step size factor.
Sourcepub fn color_tf(self, tf: ColorTransferFunction) -> Self
pub fn color_tf(self, tf: ColorTransferFunction) -> Self
Set the colour transfer function.
Sourcepub fn opacity_tf(self, tf: OpacityTransferFunction) -> Self
pub fn opacity_tf(self, tf: OpacityTransferFunction) -> Self
Set the opacity transfer function.
Sourcepub fn gradient_opacity_tf(self, tf: OpacityTransferFunction) -> Self
pub fn gradient_opacity_tf(self, tf: OpacityTransferFunction) -> Self
Set the gradient-based opacity modulation transfer function.
Sourcepub fn window_level(self, wl: WindowLevel) -> Self
pub fn window_level(self, wl: WindowLevel) -> Self
Set the window/level mapping.
Sourcepub fn cropping_bounds(self, bounds: Aabb) -> Self
pub fn cropping_bounds(self, bounds: Aabb) -> Self
Set an axis-aligned cropping box in world coordinates.
Sourcepub fn clip_plane(self, plane: ClipPlane) -> Self
pub fn clip_plane(self, plane: ClipPlane) -> Self
Add a clip plane.
Sourcepub fn background(self, rgba: [f32; 4]) -> Self
pub fn background(self, rgba: [f32; 4]) -> Self
Set the background colour.
Sourcepub fn build(self) -> VolumeRenderParams
pub fn build(self) -> VolumeRenderParams
Finalise and return the VolumeRenderParams.
Trait Implementations§
Source§impl Debug for VolumeRenderParamsBuilder
impl Debug for VolumeRenderParamsBuilder
Source§impl Default for VolumeRenderParamsBuilder
impl Default for VolumeRenderParamsBuilder
Source§fn default() -> VolumeRenderParamsBuilder
fn default() -> VolumeRenderParamsBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for VolumeRenderParamsBuilder
impl RefUnwindSafe for VolumeRenderParamsBuilder
impl Send for VolumeRenderParamsBuilder
impl Sync for VolumeRenderParamsBuilder
impl Unpin for VolumeRenderParamsBuilder
impl UnsafeUnpin for VolumeRenderParamsBuilder
impl UnwindSafe for VolumeRenderParamsBuilder
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
Mutably borrows from an owned value. Read more