Default

Struct Default 

Source
pub struct Default;
Expand description

Default graphics api end-point, ZST.

All calls approximately costs ~3 derefs.

Trait Implementations§

Source§

impl Api for Default

Source§

fn new_bitmap( &self, ) -> unsafe extern "C" fn(width: c_int, height: c_int, bgcolor: LCDColor) -> *mut LCDBitmap

Source§

fn free_bitmap(&self) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap)

Source§

fn load_bitmap( &self, ) -> unsafe extern "C" fn(path: *const c_char, outerr: *mut *const c_char) -> *mut LCDBitmap

Source§

fn copy_bitmap( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap) -> *mut LCDBitmap

Source§

fn load_into_bitmap( &self, ) -> unsafe extern "C" fn(path: *const c_char, bitmap: *mut LCDBitmap, out_err: *mut *const c_char)

Source§

fn get_bitmap_data( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, width: *mut c_int, height: *mut c_int, row_bytes: *mut c_int, mask: *mut *mut u8, data: *mut *mut u8)

Source§

fn clear_bitmap( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, bgcolor: LCDColor)

Source§

fn rotated_bitmap( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, rotation: c_float, x_scale: c_float, y_scale: c_float, allocedSize: *mut c_int) -> *mut LCDBitmap

Source§

fn set_bitmap_mask( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, mask: *mut LCDBitmap) -> c_int

Source§

fn get_bitmap_mask( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap) -> *mut LCDBitmap

Source§

fn draw_bitmap( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, x: c_int, y: c_int, flip: LCDBitmapFlip)

Source§

fn tile_bitmap( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, x: c_int, y: c_int, width: c_int, height: c_int, flip: LCDBitmapFlip)

Source§

fn draw_rotated_bitmap( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, x: c_int, y: c_int, rotation: c_float, center_x: c_float, center_y: c_float, x_scale: c_float, y_scale: c_float)

Source§

fn draw_scaled_bitmap( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, x: c_int, y: c_int, x_scale: c_float, y_scale: c_float)

Source§

fn check_mask_collision( &self, ) -> unsafe extern "C" fn(bitmap1: *mut LCDBitmap, x1: c_int, y1: c_int, flip1: LCDBitmapFlip, bitmap2: *mut LCDBitmap, x2: c_int, y2: c_int, flip2: LCDBitmapFlip, rect: LCDRect) -> c_int

Source§

fn set_color_to_pattern( &self, ) -> unsafe extern "C" fn(color: *mut LCDColor, bitmap: *mut LCDBitmap, x: c_int, y: c_int)

Source§

fn get_pixel( &self, ) -> unsafe extern "C" fn(bitmap: *mut LCDBitmap, x: c_int, y: c_int) -> LCDSolidColor

Source§

impl Api for Default

Source§

fn new_bitmap_table( &self, ) -> unsafe extern "C" fn(count: c_int, width: c_int, height: c_int) -> *mut LCDBitmapTable

Source§

fn free_bitmap_table(&self) -> unsafe extern "C" fn(table: *mut LCDBitmapTable)

Source§

fn load_bitmap_table( &self, ) -> unsafe extern "C" fn(path: *const c_char, out_err: *mut *const c_char) -> *mut LCDBitmapTable

Source§

fn load_into_bitmap_table( &self, ) -> unsafe extern "C" fn(path: *const c_char, table: *mut LCDBitmapTable, out_err: *mut *const c_char)

Source§

fn get_table_bitmap( &self, ) -> unsafe extern "C" fn(table: *mut LCDBitmapTable, idx: c_int) -> *mut LCDBitmap

Source§

fn get_bitmap_table_info( &self, ) -> unsafe extern "C" fn(table: *mut LCDBitmapTable, count: *mut c_int, width: *mut c_int)

Source§

impl Api for Default

Source§

fn draw_text( &self, ) -> unsafe extern "C" fn(text: *const c_void, len: usize, encoding: PDStringEncoding, x: c_int, y: c_int) -> c_int

Source§

fn draw_text_in_rect( &self, ) -> unsafe extern "C" fn(text: *const c_void, len: usize, encoding: PDStringEncoding, x: c_int, y: c_int, width: c_int, height: c_int, wrap: PDTextWrappingMode, align: PDTextAlignment)

Source§

fn get_text_width( &self, ) -> unsafe extern "C" fn(font: *mut LCDFont, text: *const c_void, len: usize, encoding: PDStringEncoding, tracking: c_int) -> c_int

Source§

fn get_font_height(&self) -> unsafe extern "C" fn(font: *mut LCDFont) -> u8

Source§

fn set_font(&self) -> unsafe extern "C" fn(font: *mut LCDFont)

Source§

fn set_text_tracking(&self) -> unsafe extern "C" fn(tracking: c_int)

Source§

fn get_text_tracking(&self) -> unsafe extern "C" fn() -> c_int

Source§

fn get_glyph_kerning( &self, ) -> unsafe extern "C" fn(glyph: *mut LCDFontGlyph, glyphcode: u32, nextcode: u32) -> c_int

Source§

fn load_font( &self, ) -> unsafe extern "C" fn(path: *const c_char, outErr: *mut *const c_char) -> *mut LCDFont

Source§

fn get_font_page( &self, ) -> unsafe extern "C" fn(font: *mut LCDFont, c: u32) -> *mut LCDFontPage

Source§

fn get_page_glyph( &self, ) -> unsafe extern "C" fn(page: *mut LCDFontPage, c: u32, bitmap: *mut *mut LCDBitmap, advance: *mut c_int) -> *mut LCDFontGlyph

Source§

fn make_font_from_data( &self, ) -> unsafe extern "C" fn(data: *mut LCDFontData, wide: c_int) -> *mut LCDFont

Source§

fn set_text_leading(&self) -> unsafe extern "C" fn(lineHeightAdjustment: c_int)

Source§

impl Api for Default

Source§

fn video<VApi: Api + From<*const playdate_video>>(&self) -> VApi

Source§

fn clear(&self) -> unsafe extern "C" fn(color: LCDColor)

Source§

fn set_background_color(&self) -> unsafe extern "C" fn(color: LCDSolidColor)

Source§

fn set_stencil(&self) -> unsafe extern "C" fn(stencil: *mut LCDBitmap)

Source§

fn set_draw_mode( &self, ) -> unsafe extern "C" fn(mode: LCDBitmapDrawMode) -> LCDBitmapDrawMode

Source§

fn set_draw_offset(&self) -> unsafe extern "C" fn(dx: c_int, dy: c_int)

Source§

fn set_clip_rect( &self, ) -> unsafe extern "C" fn(x: c_int, y: c_int, width: c_int, height: c_int)

Source§

fn clear_clip_rect(&self) -> unsafe extern "C" fn()

Source§

fn set_line_cap_style( &self, ) -> unsafe extern "C" fn(endCapStyle: LCDLineCapStyle)

Source§

fn push_context(&self) -> unsafe extern "C" fn(target: *mut LCDBitmap)

Source§

fn pop_context(&self) -> unsafe extern "C" fn()

Source§

fn draw_line( &self, ) -> unsafe extern "C" fn(x1: c_int, y1: c_int, x2: c_int, y2: c_int, width: c_int, color: LCDColor)

Source§

fn fill_triangle( &self, ) -> unsafe extern "C" fn(x1: c_int, y1: c_int, x2: c_int, y2: c_int, x3: c_int, y3: c_int, color: LCDColor)

Source§

fn draw_rect( &self, ) -> unsafe extern "C" fn(x: c_int, y: c_int, width: c_int, height: c_int, color: LCDColor)

Source§

fn fill_rect( &self, ) -> unsafe extern "C" fn(x: c_int, y: c_int, width: c_int, height: c_int, color: LCDColor)

Source§

fn draw_ellipse( &self, ) -> unsafe extern "C" fn(x: c_int, y: c_int, width: c_int, height: c_int, lineWidth: c_int, startAngle: c_float, endAngle: c_float, color: LCDColor)

Source§

fn fill_ellipse( &self, ) -> unsafe extern "C" fn(x: c_int, y: c_int, width: c_int, height: c_int, startAngle: c_float, endAngle: c_float, color: LCDColor)

Source§

fn set_pixel(&self) -> unsafe extern "C" fn(x: c_int, y: c_int, c: LCDColor)

Source§

fn get_frame(&self) -> unsafe extern "C" fn() -> *mut u8

Source§

fn get_display_frame(&self) -> unsafe extern "C" fn() -> *mut u8

Source§

fn get_debug_bitmap(&self) -> Option<unsafe extern "C" fn() -> *mut LCDBitmap>

Source§

fn copy_frame_buffer_bitmap(&self) -> unsafe extern "C" fn() -> *mut LCDBitmap

Source§

fn mark_updated_rows(&self) -> unsafe extern "C" fn(start: c_int, end: c_int)

Source§

fn display(&self) -> unsafe extern "C" fn()

Source§

fn set_screen_clip_rect( &self, ) -> unsafe extern "C" fn(x: c_int, y: c_int, width: c_int, height: c_int)

Source§

fn fill_polygon( &self, ) -> unsafe extern "C" fn(nPoints: c_int, coords: *mut c_int, color: LCDColor, fillrule: LCDPolygonFillRule)

Source§

fn get_display_buffer_bitmap(&self) -> unsafe extern "C" fn() -> *mut LCDBitmap

Source§

fn set_stencil_image( &self, ) -> unsafe extern "C" fn(stencil: *mut LCDBitmap, tile: c_int)

Source§

impl Clone for Default

Source§

fn clone(&self) -> Default

Returns a duplicate of the value. Read more
1.0.0§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Default

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Default

Source§

fn default() -> Default

Returns the “default value” for a type. Read more
Source§

impl Copy for Default

Auto Trait Implementations§

§

impl Freeze for Default

§

impl RefUnwindSafe for Default

§

impl Send for Default

§

impl Sync for Default

§

impl Unpin for Default

§

impl UnwindSafe for Default

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> CloneToUninit for T
where T: Clone,

§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
§

impl<T, U> TryFrom<U> for T
where 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>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where 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>

Performs the conversion.

Layout§

Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...) attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.

Size: 0 bytes