Enum sdl2_sys::SDL_BlendMode
source · [−]#[repr(u32)]
pub enum SDL_BlendMode {
SDL_BLENDMODE_NONE,
SDL_BLENDMODE_BLEND,
SDL_BLENDMODE_ADD,
SDL_BLENDMODE_MOD,
SDL_BLENDMODE_MUL,
SDL_BLENDMODE_INVALID,
}
Expand description
\brief The blend mode used in SDL_RenderCopy() and drawing operations.
Variants
SDL_BLENDMODE_NONE
< no blending dstRGBA = srcRGBA
SDL_BLENDMODE_BLEND
< alpha blending dstRGB = (srcRGB * srcA) + (dstRGB * (1-srcA)) dstA = srcA + (dstA * (1-srcA))
SDL_BLENDMODE_ADD
< additive blending dstRGB = (srcRGB * srcA) + dstRGB dstA = dstA
SDL_BLENDMODE_MOD
< color modulate dstRGB = srcRGB * dstRGB dstA = dstA
SDL_BLENDMODE_MUL
< color multiply dstRGB = (srcRGB * dstRGB) + (dstRGB * (1-srcA)) dstA = (srcA * dstA) + (dstA * (1-srcA))
SDL_BLENDMODE_INVALID
Trait Implementations
sourceimpl Clone for SDL_BlendMode
impl Clone for SDL_BlendMode
sourcefn clone(&self) -> SDL_BlendMode
fn clone(&self) -> SDL_BlendMode
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for SDL_BlendMode
impl Debug for SDL_BlendMode
sourceimpl Hash for SDL_BlendMode
impl Hash for SDL_BlendMode
sourceimpl PartialEq<SDL_BlendMode> for SDL_BlendMode
impl PartialEq<SDL_BlendMode> for SDL_BlendMode
impl Copy for SDL_BlendMode
impl Eq for SDL_BlendMode
impl StructuralEq for SDL_BlendMode
impl StructuralPartialEq for SDL_BlendMode
Auto Trait Implementations
impl RefUnwindSafe for SDL_BlendMode
impl Send for SDL_BlendMode
impl Sync for SDL_BlendMode
impl Unpin for SDL_BlendMode
impl UnwindSafe for SDL_BlendMode
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more