次の方法で共有


RecordingCanvas Class

Definition

A Canvas implementation that records view system drawing operations for deferred rendering.

[Android.Runtime.Register("android/graphics/RecordingCanvas", ApiSince=29, DoNotGenerateAcw=true)]
public sealed class RecordingCanvas : Android.Graphics.Canvas
[<Android.Runtime.Register("android/graphics/RecordingCanvas", ApiSince=29, DoNotGenerateAcw=true)>]
type RecordingCanvas = class
    inherit Canvas
Inheritance
RecordingCanvas
Attributes

Remarks

A Canvas implementation that records view system drawing operations for deferred rendering. This is used in combination with RenderNode. This class keeps a list of all the Paint and Bitmap objects that it draws, preventing the backing memory of Bitmaps from being released while the RecordingCanvas is still holding a native reference to the memory.

This is obtained by calling RenderNode#beginRecording() and is valid until the matching RenderNode#endRecording() is called. It must not be retained beyond that as it is internally reused.

Java documentation for android.graphics.RecordingCanvas.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Properties

Class

Returns the runtime class of this Object.

(Inherited from Object)
ClipBounds

Retrieve the bounds of the current clip (in local coordinates).

(Inherited from Canvas)
Density

Returns the target density of the canvas. -or- Specifies the density for this Canvas' backing bitmap.

(Inherited from Canvas)
DrawFilter (Inherited from Canvas)
GL (Inherited from Canvas)
Handle

The handle to the underlying Android instance.

(Inherited from Object)
Height

Returns the height of the current drawing layer

(Inherited from Canvas)
IsHardwareAccelerated

Indicates whether this Canvas uses hardware acceleration.

(Inherited from Canvas)
IsOpaque

Return true if the device that the current layer draws into is opaque (that is, it does not support per-pixel alpha).

(Inherited from Canvas)
JniIdentityHashCode (Inherited from Object)
JniPeerMembers
Matrix
Obsolete.

Return a new matrix with a copy of the canvas' current transformation matrix. -or- Completely replace the current matrix with the specified matrix.

(Inherited from Canvas)
MaximumBitmapHeight

Returns the maximum allowed height for bitmaps drawn with this canvas.

(Inherited from Canvas)
MaximumBitmapWidth

Returns the maximum allowed width for bitmaps drawn with this canvas.

(Inherited from Canvas)
PeerReference (Inherited from Object)
SaveCount

Returns the number of matrix/clip states on the Canvas' private stack.

(Inherited from Canvas)
ThresholdClass

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

(Inherited from Canvas)
ThresholdType

This API supports the Mono for Android infrastructure and is not intended to be used directly from your code.

(Inherited from Canvas)
Width

Returns the width of the current drawing layer

(Inherited from Canvas)

Methods

ClipOutPath(Path)

Set the clip to the difference of the current clip and the specified path.

(Inherited from Canvas)
ClipOutRect(Int32, Int32, Int32, Int32)

Set the clip to the difference of the current clip and the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipOutRect(Rect)

Set the clip to the difference of the current clip and the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipOutRect(RectF)

Set the clip to the difference of the current clip and the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipOutRect(Single, Single, Single, Single)

Set the clip to the difference of the current clip and the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipPath(Path, Region+Op)

Intersect the current clip with the specified path.

(Inherited from Canvas)
ClipPath(Path)

Intersect the current clip with the specified path.

(Inherited from Canvas)
ClipRect(Int32, Int32, Int32, Int32)

Intersect the current clip with the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipRect(Rect, Region+Op)

Intersect the current clip with the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipRect(Rect)

Intersect the current clip with the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipRect(RectF, Region+Op)

Intersect the current clip with the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipRect(RectF)

Intersect the current clip with the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipRect(Single, Single, Single, Single, Region+Op)

Intersect the current clip with the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipRect(Single, Single, Single, Single)

Intersect the current clip with the specified rectangle, which is expressed in local coordinates.

(Inherited from Canvas)
ClipRegion(Region, Region+Op)
Obsolete.

Modify the current clip with the specified region.

(Inherited from Canvas)
ClipRegion(Region)
Obsolete.

Intersect the current clip with the specified region.

(Inherited from Canvas)
Clone()

Creates and returns a copy of this object.

(Inherited from Object)
Concat(Matrix)

Preconcat the current matrix with the specified matrix.

(Inherited from Canvas)
DisableZ()

Disables Z support, preventing any RenderNodes drawn after this point from being visually reordered or having shadows rendered.

(Inherited from Canvas)
Dispose() (Inherited from Object)
Dispose(Boolean) (Inherited from Object)
DrawArc(RectF, Single, Single, Boolean, Paint)
DrawArc(Single, Single, Single, Single, Single, Single, Boolean, Paint)
DrawARGB(Int32, Int32, Int32, Int32)
DrawBitmap(Bitmap, Matrix, Paint)
DrawBitmap(Bitmap, Rect, Rect, Paint)
DrawBitmap(Bitmap, Rect, RectF, Paint)
DrawBitmap(Bitmap, Single, Single, Paint)
DrawBitmap(Int32[], Int32, Int32, Int32, Int32, Int32, Int32, Boolean, Paint)
DrawBitmap(Int32[], Int32, Int32, Single, Single, Int32, Int32, Boolean, Paint)
DrawBitmapMesh(Bitmap, Int32, Int32, Single[], Int32, Int32[], Int32, Paint)
DrawCircle(Single, Single, Single, Paint)
DrawColor(Color, BlendMode)
DrawColor(Color, PorterDuff+Mode)
DrawColor(Color)
DrawColor(Int64, BlendMode)
DrawColor(Int64)

Fill the entire canvas' bitmap (restricted to the current clip) with the specified color, using srcover porterduff mode.

(Inherited from Canvas)
DrawDoubleRoundRect(RectF, Single, Single, RectF, Single, Single, Paint)
DrawDoubleRoundRect(RectF, Single[], RectF, Single[], Paint)
DrawGlyphs(Int32[], Int32, Single[], Int32, Int32, Font, Paint)

Draw array of glyphs with specified font.

(Inherited from Canvas)
DrawLine(Single, Single, Single, Single, Paint)
DrawLines(Single[], Int32, Int32, Paint)
DrawLines(Single[], Paint)
DrawMesh(Mesh, BlendMode, Paint)
DrawMesh(Mesh, BlendMode, Paint) (Inherited from Canvas)
DrawOval(RectF, Paint)
DrawOval(Single, Single, Single, Single, Paint)
DrawPaint(Paint)
DrawPatch(NinePatch, Rect, Paint)
DrawPatch(NinePatch, RectF, Paint)
DrawPath(Path, Paint)
DrawPicture(Picture, Rect)
DrawPicture(Picture, RectF)
DrawPicture(Picture)
DrawPoint(Single, Single, Paint)
DrawPoints(Single[], Int32, Int32, Paint)
DrawPoints(Single[], Paint)
DrawPosText(Char[], Int32, Int32, Single[], Paint)
DrawPosText(String, Single[], Paint)
DrawRect(Rect, Paint)
DrawRect(RectF, Paint)
DrawRect(Single, Single, Single, Single, Paint)
DrawRenderNode(RenderNode)

Draws the given RenderNode.

(Inherited from Canvas)
DrawRGB(Int32, Int32, Int32)
DrawRoundRect(RectF, Single, Single, Paint)
DrawRoundRect(Single, Single, Single, Single, Single, Single, Paint)
DrawText(Char[], Int32, Int32, Single, Single, Paint)
DrawText(ICharSequence, Int32, Int32, Single, Single, Paint)
DrawText(String, Int32, Int32, Single, Single, Paint)
DrawText(String, Single, Single, Paint)
DrawTextOnPath(Char[], Int32, Int32, Path, Single, Single, Paint)
DrawTextOnPath(String, Path, Single, Single, Paint)
DrawTextRun(Char[], Int32, Int32, Int32, Int32, Single, Single, Boolean, Paint)
DrawTextRun(ICharSequence, Int32, Int32, Int32, Int32, Single, Single, Boolean, Paint)
DrawTextRun(MeasuredText, Int32, Int32, Int32, Int32, Single, Single, Boolean, Paint)

Draw a run of text, all in a single direction, with optional context for complex text shaping.

(Inherited from Canvas)
DrawTextRun(String, Int32, Int32, Int32, Int32, Single, Single, Boolean, Paint)

Draw a run of text, all in a single direction, with optional context for complex text shaping.

(Inherited from Canvas)
DrawVertices(Canvas+VertexMode, Int32, Single[], Int32, Single[], Int32, Int32[], Int32, Int16[], Int32, Int32, Paint)
EnableZ()

Enables Z support which defaults to disabled.

(Inherited from Canvas)
Equals(Object)

Indicates whether some other object is "equal to" this one.

(Inherited from Object)
GetClipBounds(Rect)

Return the bounds of the current clip (in local coordinates) in the bounds parameter, and return true if it is non-empty.

(Inherited from Canvas)
GetHashCode()

Returns a hash code value for the object.

(Inherited from Object)
GetMatrix(Matrix)
Obsolete.

Return, in ctm, the current transformation matrix.

(Inherited from Canvas)
JavaFinalize()

Called by the garbage collector on an object when garbage collection determines that there are no more references to the object.

(Inherited from Object)
Notify()

Wakes up a single thread that is waiting on this object's monitor.

(Inherited from Object)
NotifyAll()

Wakes up all threads that are waiting on this object's monitor.

(Inherited from Object)
QuickReject(Path, Canvas+EdgeType)

Return true if the specified rectangle, after being transformed by the current matrix, would lie completely outside of the current clip.

(Inherited from Canvas)
QuickReject(Path)

Return true if the specified path, after being transformed by the current matrix, would lie completely outside of the current clip.

(Inherited from Canvas)
QuickReject(RectF, Canvas+EdgeType)

Return true if the specified rectangle, after being transformed by the current matrix, would lie completely outside of the current clip.

(Inherited from Canvas)
QuickReject(RectF)

Return true if the specified rectangle, after being transformed by the current matrix, would lie completely outside of the current clip.

(Inherited from Canvas)
QuickReject(Single, Single, Single, Single, Canvas+EdgeType)

Return true if the specified rectangle, after being transformed by the current matrix, would lie completely outside of the current clip.

(Inherited from Canvas)
QuickReject(Single, Single, Single, Single)

Return true if the specified rectangle, after being transformed by the current matrix, would lie completely outside of the current clip.

(Inherited from Canvas)
Restore()

This call balances a previous call to save(), and is used to remove all modifications to the matrix/clip state since the last save call.

(Inherited from Canvas)
RestoreToCount(Int32)

Efficient way to pop any calls to save() that happened after the save count reached saveCount.

(Inherited from Canvas)
Rotate(Single, Single, Single)

Preconcat the current matrix with the specified rotation.

(Inherited from Canvas)
Rotate(Single)

Preconcat the current matrix with the specified rotation.

(Inherited from Canvas)
Save()

Saves the current matrix and clip onto a private stack.

(Inherited from Canvas)
Save(SaveFlags)

Based on saveFlags, can save the current matrix and clip onto a private stack.

(Inherited from Canvas)
SaveLayer(RectF, Paint, SaveFlags)

This behaves the same as save(), but in addition it allocates and redirects drawing to an offscreen bitmap.

(Inherited from Canvas)
SaveLayer(RectF, Paint)

This behaves the same as save(), but in addition it allocates and redirects drawing to an offscreen rendering target.

(Inherited from Canvas)
SaveLayer(Single, Single, Single, Single, Paint, SaveFlags)

Helper version of saveLayer() that takes 4 values rather than a RectF.

(Inherited from Canvas)
SaveLayer(Single, Single, Single, Single, Paint)

Convenience for #saveLayer(RectF, Paint) that takes the four float coordinates of the bounds rectangle.

(Inherited from Canvas)
SaveLayerAlpha(RectF, Int32, SaveFlags)

This behaves the same as save(), but in addition it allocates and redirects drawing to an offscreen bitmap.

(Inherited from Canvas)
SaveLayerAlpha(RectF, Int32)

Convenience for #saveLayer(RectF, Paint) but instead of taking a entire Paint object it takes only the alpha parameter.

(Inherited from Canvas)
SaveLayerAlpha(Single, Single, Single, Single, Int32, SaveFlags)

Helper for saveLayerAlpha() that takes 4 values instead of a RectF.

(Inherited from Canvas)
SaveLayerAlpha(Single, Single, Single, Single, Int32)

Convenience for #saveLayerAlpha(RectF, int) that takes the four float coordinates of the bounds rectangle.

(Inherited from Canvas)
Scale(Single, Single, Single, Single)

Preconcat the current matrix with the specified scale.

(Inherited from Canvas)
Scale(Single, Single)

Preconcat the current matrix with the specified scale.

(Inherited from Canvas)
SetBitmap(Bitmap)

Specify a bitmap for the canvas to draw into.

(Inherited from Canvas)
SetHandle(IntPtr, JniHandleOwnership)

Sets the Handle property.

(Inherited from Object)
SetViewport(Int32, Int32) (Inherited from Canvas)
Skew(Single, Single)

Preconcat the current matrix with the specified skew.

(Inherited from Canvas)
ToArray<T>() (Inherited from Object)
ToString()

Returns a string representation of the object.

(Inherited from Object)
Translate(Single, Single)

Preconcat the current matrix with the specified translation

(Inherited from Canvas)
UnregisterFromRuntime() (Inherited from Object)
Wait()

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>.

(Inherited from Object)
Wait(Int64, Int32)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)
Wait(Int64)

Causes the current thread to wait until it is awakened, typically by being <em>notified</em> or <em>interrupted</em>, or until a certain amount of real time has elapsed.

(Inherited from Object)

Explicit Interface Implementations

IJavaPeerable.Disposed() (Inherited from Object)
IJavaPeerable.DisposeUnlessReferenced() (Inherited from Object)
IJavaPeerable.Finalized() (Inherited from Object)
IJavaPeerable.JniManagedPeerState (Inherited from Object)
IJavaPeerable.SetJniIdentityHashCode(Int32) (Inherited from Object)
IJavaPeerable.SetJniManagedPeerState(JniManagedPeerStates) (Inherited from Object)
IJavaPeerable.SetPeerReference(JniObjectReference) (Inherited from Object)

Extension Methods

JavaCast<TResult>(IJavaObject)

Performs an Android runtime-checked type conversion.

JavaCast<TResult>(IJavaObject)
GetJniTypeName(IJavaPeerable)

Applies to