Struct libremarkable::fb::Framebuffer [] [src]

pub struct Framebuffer<'a> {
    pub device: File,
    pub frame: MemoryMap,
    pub marker: AtomicU32,
    pub default_font: Font<'a>,
    pub var_screen_info: VarScreeninfo,
    pub fix_screen_info: FixScreeninfo,
}

Framebuffer struct containing the state (latest update marker etc.) along with the var/fix screeninfo structs.

Fields

Trait Implementations

impl<'a> Send for Framebuffer<'a>
[src]

impl<'a> Sync for Framebuffer<'a>
[src]

impl<'a> FramebufferBase<'a> for Framebuffer<'a>
[src]

[src]

Creates a new instance of Framebuffer

[src]

Toggles the EPD Controller (see https://wiki.mobileread.com/wiki/EPD_controller)

[src]

Toggles autoupdate mode

[src]

Toggles update scheme

[src]

Creates a FixScreeninfo struct and fills it using ioctl

[src]

Creates a VarScreeninfo struct and fills it using ioctl

[src]

Makes the proper ioctl call to set the VarScreenInfo. You must first update the contents of self.var_screen_info and then call this function.

impl<'a> FramebufferIO for Framebuffer<'a>
[src]

[src]

Writes an arbitrary length frame into the framebuffer

[src]

Writes a single pixel at (y, x) with value v

[src]

Reads the value of the pixel at (y, x)

[src]

Reads the value at offset ofst from the mmapp'ed framebuffer region

impl<'a> FramebufferDraw for Framebuffer<'a>
[src]

[src]

Draws img at y=top, x=left coordinates with 1:1 scaling

[src]

Draws a straight line

[src]

Draws a circle using Bresenham circle algorithm

[src]

Fills a circle

[src]

Draws a bezier curve begining at startpt, with control point ctrlpt, ending at endpt with color

[src]

Draws text at (y, x) with color using scale

[src]

Fills rectangle of height and width at (y, x)

[src]

Clears the framebuffer however does not perform a refresh

impl<'a> FramebufferRefresh for Framebuffer<'a>
[src]

[src]

  1. PxP must process 8x8 pixel blocks, and all pixels in each block are considered for auto-waveform mode selection. If the update region is not 8x8 aligned, additional unwanted pixels will be considered in auto-waveform mode selection.

  2. PxP input must be 32-bit aligned, so any update address not 32-bit aligned must be shifted to meet the 32-bit alignment. The PxP will thus end up processing pixels outside of the update region to satisfy this alignment restriction, which can affect auto-waveform mode selection.

  3. If input fails 32-bit alignment, and the resulting expansion of the processed region would add at least 8 pixels more per line than the original update line width, the EPDC would cause screen artifacts by incorrectly handling the 8+ pixels at the end of each line.

[src]