#[repr(C)]pub struct DropShadowUniforms {
pub offset: [f32; 2],
pub blur_radius: f32,
pub spread: f32,
pub color: [f32; 4],
pub texel_size: [f32; 2],
pub _pad: [f32; 2],
}Expand description
Uniforms for drop shadow shader
Memory layout (48 bytes total):
- offset:
vec2<f32>(8 bytes) - shadow offset in pixels - blur_radius:
f32(4 bytes) - blur radius - spread:
f32(4 bytes) - spread (expand/contract) - color:
vec4<f32>(16 bytes) - shadow color RGBA - texel_size:
vec2<f32>(8 bytes) - inverse texture size - _pad:
vec2<f32>(8 bytes) - padding for alignment
Fields§
§offset: [f32; 2]Shadow offset in pixels (x, y)
blur_radius: f32Blur radius
spread: f32Spread (positive expands, negative contracts)
color: [f32; 4]Shadow color (RGBA)
texel_size: [f32; 2]Inverse texture size (1/width, 1/height)
_pad: [f32; 2]Padding for 16-byte alignment
Trait Implementations§
Source§impl Clone for DropShadowUniforms
impl Clone for DropShadowUniforms
Source§fn clone(&self) -> DropShadowUniforms
fn clone(&self) -> DropShadowUniforms
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for DropShadowUniforms
impl Debug for DropShadowUniforms
Source§impl Default for DropShadowUniforms
impl Default for DropShadowUniforms
impl Copy for DropShadowUniforms
impl Pod for DropShadowUniforms
Auto Trait Implementations§
impl Freeze for DropShadowUniforms
impl RefUnwindSafe for DropShadowUniforms
impl Send for DropShadowUniforms
impl Sync for DropShadowUniforms
impl Unpin for DropShadowUniforms
impl UnsafeUnpin for DropShadowUniforms
impl UnwindSafe for DropShadowUniforms
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
Source§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
Source§type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern.Source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self.