[−][src]Union card10_sys::disp_framebuffer
Framebuffer
The frambuffer stores pixels as RGB565, but byte swapped. That is, for every (x, y)
coordinate, there are two uint8_t
\ s storing 16 bits of pixel data.
.. todo::
Document (x, y) in relation to chirality.
Example: Fill framebuffer with red
.. code-block:: cpp
union disp_framebuffer fb; uint16_t red = 0b1111100000000000; for (int y = 0; y < DISP_HEIGHT; y++) { for (int x = 0; x < DISP_WIDTH; x++) { fb.fb[y][x][0] = red >> 8; fb.fb[y][x][1] = red & 0xFF; } } epic_disp_framebuffer(&fb);
Fields
fb: [[[u8; 2]; 160]; 80]
Coordinate based access (as shown in the example above).
raw: [u8; 25600]
Raw byte-indexed access.
Trait Implementations
impl Copy for disp_framebuffer
[src]
impl Clone for disp_framebuffer
[src]
fn clone(&self) -> disp_framebuffer
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Auto Trait Implementations
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,