[][src]Struct gba_hal::data::Mosaic

#[repr(transparent)]
pub struct Mosaic(_);

Allows control of the Mosaic effect.

Values are the increase for each top-left pixel to be duplicated in the final result. If you want to duplicate some other pixel than the top-left, you can offset the background or object by an appropriate amount.

  1. No effect (1+0)
  2. Each pixel becomes 2 pixels (1+1)
  3. Each pixel becomes 3 pixels (1+2)
  4. Each pixel becomes 4 pixels (1+3)
  • Bits 0-3: BG mosaic horizontal increase
  • Bits 4-7: BG mosaic vertical increase
  • Bits 8-11: Object mosaic horizontal increase
  • Bits 12-15: Object mosaic vertical increase

Methods

impl Mosaic[src]

pub const fn new() -> Self[src]

A const "zero value" constructor

impl Mosaic[src]

pub const BG_HORIZONTAL_INC_MASK: u16[src]

pub const fn bg_horizontal_inc(self) -> u16[src]

pub const fn with_bg_horizontal_inc(self, bg_horizontal_inc: u16) -> Self[src]

pub const BG_VERTICAL_INC_MASK: u16[src]

pub const fn bg_vertical_inc(self) -> u16[src]

pub const fn with_bg_vertical_inc(self, bg_vertical_inc: u16) -> Self[src]

pub const OBJ_HORIZONTAL_INC_MASK: u16[src]

pub const fn obj_horizontal_inc(self) -> u16[src]

pub const fn with_obj_horizontal_inc(self, obj_horizontal_inc: u16) -> Self[src]

pub const OBJ_VERTICAL_INC_MASK: u16[src]

pub const fn obj_vertical_inc(self) -> u16[src]

pub const fn with_obj_vertical_inc(self, obj_vertical_inc: u16) -> Self[src]

Trait Implementations

impl PartialEq<Mosaic> for Mosaic[src]

impl Eq for Mosaic[src]

impl Debug for Mosaic[src]

impl Copy for Mosaic[src]

impl Clone for Mosaic[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Default for Mosaic[src]

Auto Trait Implementations

impl Send for Mosaic

impl Sync for Mosaic

Blanket Implementations

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]