[−][src]Struct framebuffer::Framebuffer
Struct that should be used to work with the framebuffer. Direct usage of frame
should not be
necessary.
Fields
device: File
frame: Mmap
var_screen_info: VarScreeninfo
fix_screen_info: FixScreeninfo
Methods
impl Framebuffer
[src]
pub fn new<P: AsRef<Path>>(
path_to_device: P
) -> Result<Framebuffer, FramebufferError>
[src]
path_to_device: P
) -> Result<Framebuffer, FramebufferError>
pub fn write_frame(&mut self, frame: &[u8])
[src]
Writes a frame to the Framebuffer.
pub fn get_fix_screeninfo(
device: &File
) -> Result<FixScreeninfo, FramebufferError>
[src]
device: &File
) -> Result<FixScreeninfo, FramebufferError>
Creates a FixScreeninfo struct and fills it using ioctl.
pub fn get_var_screeninfo(
device: &File
) -> Result<VarScreeninfo, FramebufferError>
[src]
device: &File
) -> Result<VarScreeninfo, FramebufferError>
Creates a VarScreeninfo struct and fills it using ioctl.
pub fn put_var_screeninfo(
device: &File,
screeninfo: &VarScreeninfo
) -> Result<i32, FramebufferError>
[src]
device: &File,
screeninfo: &VarScreeninfo
) -> Result<i32, FramebufferError>
pub fn set_kd_mode(kd_mode: KdMode) -> Result<i32, FramebufferError>
[src]
Sets the tty graphics mode. Make sure to change it back to KdMode::Text after the program is done!
pub fn set_kd_mode_ex<P: AsRef<Path>>(
path_to_device: P,
kd_mode: KdMode
) -> Result<i32, FramebufferError>
[src]
path_to_device: P,
kd_mode: KdMode
) -> Result<i32, FramebufferError>
Allows setting tty mode from non-terminal session by explicitly specifying device name
Trait Implementations
Auto Trait Implementations
impl Send for Framebuffer
impl Sync for Framebuffer
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
🔬 This is a nightly-only experimental API. (
try_from
)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> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,