Struct skia_bindings::SkCanvas
source · #[repr(C)]pub struct SkCanvas {Show 13 fields
pub vtable_: *const SkCanvas__bindgen_vtable,
pub fMCRecStorage: [isize; 384],
pub fMCStack: SkDeque,
pub fMCRec: *mut SkCanvas_MCRec,
pub fBaseDevice: sk_sp<SkBaseDevice>,
pub fProps: SkSurfaceProps,
pub fSaveCount: c_int,
pub fAllocator: u64,
pub fSurfaceBase: *mut SkSurface_Base,
pub fClipRestrictionRect: SkIRect,
pub fClipRestrictionSaveCount: c_int,
pub fQuickRejectBounds: SkRect,
pub fScratchGlyphRunBuilder: u64,
}
Fields§
§vtable_: *const SkCanvas__bindgen_vtable
§fMCRecStorage: [isize; 384]
§fMCStack: SkDeque
§fMCRec: *mut SkCanvas_MCRec
§fBaseDevice: sk_sp<SkBaseDevice>
§fProps: SkSurfaceProps
§fSaveCount: c_int
§fAllocator: u64
§fSurfaceBase: *mut SkSurface_Base
§fClipRestrictionRect: SkIRect
§fClipRestrictionSaveCount: c_int
§fQuickRejectBounds: SkRect
§fScratchGlyphRunBuilder: u64
Implementations§
source§impl SkCanvas
impl SkCanvas
pub unsafe fn MakeRasterDirect( info: *const SkImageInfo, pixels: *mut c_void, rowBytes: usize, props: *const SkSurfaceProps ) -> u64
pub unsafe fn imageInfo(&self) -> SkImageInfo
pub unsafe fn getProps(&self, props: *mut SkSurfaceProps) -> bool
pub unsafe fn getBaseProps(&self) -> SkSurfaceProps
pub unsafe fn getTopProps(&self) -> SkSurfaceProps
pub unsafe fn flush(&mut self)
pub unsafe fn makeSurface( &mut self, info: *const SkImageInfo, props: *const SkSurfaceProps ) -> sk_sp<SkSurface>
pub unsafe fn getSurface(&self) -> *mut SkSurface
pub unsafe fn accessTopLayerPixels( &mut self, info: *mut SkImageInfo, rowBytes: *mut usize, origin: *mut SkIPoint ) -> *mut c_void
pub unsafe fn accessTopRasterHandle(&self) -> SkRasterHandleAllocator_Handle
pub unsafe fn peekPixels(&mut self, pixmap: *mut SkPixmap) -> bool
pub unsafe fn readPixels( &mut self, dstInfo: *const SkImageInfo, dstPixels: *mut c_void, dstRowBytes: usize, srcX: c_int, srcY: c_int ) -> bool
pub unsafe fn readPixels1( &mut self, pixmap: *const SkPixmap, srcX: c_int, srcY: c_int ) -> bool
pub unsafe fn readPixels2( &mut self, bitmap: *const SkBitmap, srcX: c_int, srcY: c_int ) -> bool
pub unsafe fn writePixels( &mut self, info: *const SkImageInfo, pixels: *const c_void, rowBytes: usize, x: c_int, y: c_int ) -> bool
pub unsafe fn writePixels1( &mut self, bitmap: *const SkBitmap, x: c_int, y: c_int ) -> bool
pub unsafe fn save(&mut self) -> c_int
pub unsafe fn saveLayer( &mut self, bounds: *const SkRect, paint: *const SkPaint ) -> c_int
pub unsafe fn saveLayerAlphaf( &mut self, bounds: *const SkRect, alpha: f32 ) -> c_int
pub unsafe fn saveLayer1( &mut self, layerRec: *const SkCanvas_SaveLayerRec ) -> c_int
pub unsafe fn restore(&mut self)
pub unsafe fn getSaveCount(&self) -> c_int
pub unsafe fn restoreToCount(&mut self, saveCount: c_int)
pub unsafe fn translate(&mut self, dx: SkScalar, dy: SkScalar)
pub unsafe fn scale(&mut self, sx: SkScalar, sy: SkScalar)
pub unsafe fn rotate(&mut self, degrees: SkScalar)
pub unsafe fn rotate1(&mut self, degrees: SkScalar, px: SkScalar, py: SkScalar)
pub unsafe fn skew(&mut self, sx: SkScalar, sy: SkScalar)
pub unsafe fn concat(&mut self, matrix: *const SkMatrix)
pub unsafe fn concat1(&mut self, arg1: *const SkM44)
pub unsafe fn setMatrix(&mut self, matrix: *const SkM44)
pub unsafe fn setMatrix1(&mut self, matrix: *const SkMatrix)
pub unsafe fn resetMatrix(&mut self)
pub unsafe fn clipRect( &mut self, rect: *const SkRect, op: SkClipOp, doAntiAlias: bool )
pub unsafe fn androidFramework_setDeviceClipRestriction( &mut self, rect: *const SkIRect )
pub unsafe fn clipRRect( &mut self, rrect: *const SkRRect, op: SkClipOp, doAntiAlias: bool )
pub unsafe fn clipPath( &mut self, path: *const SkPath, op: SkClipOp, doAntiAlias: bool )
pub unsafe fn clipShader(&mut self, arg1: sk_sp<SkShader>, arg2: SkClipOp)
pub unsafe fn clipRegion(&mut self, deviceRgn: *const SkRegion, op: SkClipOp)
pub unsafe fn quickReject(&self, rect: *const SkRect) -> bool
pub unsafe fn quickReject1(&self, path: *const SkPath) -> bool
pub unsafe fn getLocalClipBounds(&self) -> SkRect
pub unsafe fn getDeviceClipBounds(&self) -> SkIRect
pub unsafe fn drawColor(&mut self, color: *const SkColor4f, mode: SkBlendMode)
pub unsafe fn drawPaint(&mut self, paint: *const SkPaint)
pub unsafe fn drawPoints( &mut self, mode: SkCanvas_PointMode, count: usize, pts: *const SkPoint, paint: *const SkPaint )
pub unsafe fn drawPoint( &mut self, x: SkScalar, y: SkScalar, paint: *const SkPaint )
pub unsafe fn drawLine( &mut self, x0: SkScalar, y0: SkScalar, x1: SkScalar, y1: SkScalar, paint: *const SkPaint )
pub unsafe fn drawRect(&mut self, rect: *const SkRect, paint: *const SkPaint)
pub unsafe fn drawRegion( &mut self, region: *const SkRegion, paint: *const SkPaint )
pub unsafe fn drawOval(&mut self, oval: *const SkRect, paint: *const SkPaint)
pub unsafe fn drawRRect(&mut self, rrect: *const SkRRect, paint: *const SkPaint)
pub unsafe fn drawDRRect( &mut self, outer: *const SkRRect, inner: *const SkRRect, paint: *const SkPaint )
pub unsafe fn drawCircle( &mut self, cx: SkScalar, cy: SkScalar, radius: SkScalar, paint: *const SkPaint )
pub unsafe fn drawArc( &mut self, oval: *const SkRect, startAngle: SkScalar, sweepAngle: SkScalar, useCenter: bool, paint: *const SkPaint )
pub unsafe fn drawRoundRect( &mut self, rect: *const SkRect, rx: SkScalar, ry: SkScalar, paint: *const SkPaint )
pub unsafe fn drawPath(&mut self, path: *const SkPath, paint: *const SkPaint)
pub unsafe fn drawImage( &mut self, arg1: *const SkImage, x: SkScalar, y: SkScalar, arg2: *const SkSamplingOptions, arg3: *const SkPaint )
pub unsafe fn drawImageRect( &mut self, arg1: *const SkImage, src: *const SkRect, dst: *const SkRect, arg2: *const SkSamplingOptions, arg3: *const SkPaint, arg4: SkCanvas_SrcRectConstraint )
pub unsafe fn drawImageRect1( &mut self, arg1: *const SkImage, dst: *const SkRect, arg2: *const SkSamplingOptions, arg3: *const SkPaint )
pub unsafe fn drawImageNine( &mut self, image: *const SkImage, center: *const SkIRect, dst: *const SkRect, filter: SkFilterMode, paint: *const SkPaint )
pub unsafe fn drawImageLattice( &mut self, image: *const SkImage, lattice: *const SkCanvas_Lattice, dst: *const SkRect, filter: SkFilterMode, paint: *const SkPaint )
pub unsafe fn experimental_DrawEdgeAAQuad( &mut self, rect: *const SkRect, clip: *const SkPoint, aaFlags: SkCanvas_QuadAAFlags, color: *const SkColor4f, mode: SkBlendMode )
pub unsafe fn experimental_DrawEdgeAAImageSet( &mut self, imageSet: *const SkCanvas_ImageSetEntry, cnt: c_int, dstClips: *const SkPoint, preViewMatrices: *const SkMatrix, arg1: *const SkSamplingOptions, paint: *const SkPaint, constraint: SkCanvas_SrcRectConstraint )
pub unsafe fn drawSimpleText( &mut self, text: *const c_void, byteLength: usize, encoding: SkTextEncoding, x: SkScalar, y: SkScalar, font: *const SkFont, paint: *const SkPaint )
pub unsafe fn drawGlyphs( &mut self, count: c_int, glyphs: *const SkGlyphID, positions: *const SkPoint, clusters: *const u32, textByteCount: c_int, utf8text: *const c_char, origin: SkPoint, font: *const SkFont, paint: *const SkPaint )
pub unsafe fn drawGlyphs1( &mut self, count: c_int, glyphs: *const SkGlyphID, positions: *const SkPoint, origin: SkPoint, font: *const SkFont, paint: *const SkPaint )
pub unsafe fn drawGlyphs2( &mut self, count: c_int, glyphs: *const SkGlyphID, xforms: *const SkRSXform, origin: SkPoint, font: *const SkFont, paint: *const SkPaint )
pub unsafe fn drawTextBlob( &mut self, blob: *const SkTextBlob, x: SkScalar, y: SkScalar, paint: *const SkPaint )
pub unsafe fn drawPicture( &mut self, picture: *const SkPicture, matrix: *const SkMatrix, paint: *const SkPaint )
pub unsafe fn drawVertices( &mut self, vertices: *const SkVertices, mode: SkBlendMode, paint: *const SkPaint )
pub unsafe fn drawVertices1( &mut self, vertices: *const sk_sp<SkVertices>, mode: SkBlendMode, paint: *const SkPaint )
pub unsafe fn drawMesh( &mut self, mesh: *const SkMesh, blender: sk_sp<SkBlender>, paint: *const SkPaint )
pub unsafe fn drawPatch( &mut self, cubics: *const SkPoint, colors: *const SkColor, texCoords: *const SkPoint, mode: SkBlendMode, paint: *const SkPaint )
pub unsafe fn drawAtlas( &mut self, atlas: *const SkImage, xform: *const SkRSXform, tex: *const SkRect, colors: *const SkColor, count: c_int, mode: SkBlendMode, sampling: *const SkSamplingOptions, cullRect: *const SkRect, paint: *const SkPaint )
pub unsafe fn drawDrawable( &mut self, drawable: *mut SkDrawable, matrix: *const SkMatrix )
pub unsafe fn drawDrawable1( &mut self, drawable: *mut SkDrawable, x: SkScalar, y: SkScalar )
pub unsafe fn drawAnnotation( &mut self, rect: *const SkRect, key: *const c_char, value: *mut SkData )
pub unsafe fn getLocalToDevice(&self) -> SkM44
pub unsafe fn getTotalMatrix(&self) -> SkMatrix
pub unsafe fn temporary_internal_getRgnClip(&mut self, region: *mut SkRegion)
pub unsafe fn private_draw_shadow_rec( &mut self, arg1: *const SkPath, arg2: *const SkDrawShadowRec )
pub unsafe fn new() -> Self
pub unsafe fn new1( width: c_int, height: c_int, props: *const SkSurfaceProps ) -> Self
pub unsafe fn new2(device: sk_sp<SkBaseDevice>) -> Self
pub unsafe fn new3(bitmap: *const SkBitmap) -> Self
pub unsafe fn new4( bitmap: *const SkBitmap, props: *const SkSurfaceProps ) -> Self
pub unsafe fn new5(bounds: *const SkIRect) -> Self
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for SkCanvas
impl !Send for SkCanvas
impl !Sync for SkCanvas
impl Unpin for SkCanvas
impl UnwindSafe for SkCanvas
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more