TextureWarmer

open class TextureWarmer

A class that schedules a background draw of a Layout or Drawable. Drawing a Layout in the background ensures that the glyph caches are warmed up and ready for drawing the same Layout on a real Canvas. This will substantially reduce drawing times for big chunks of text. On the other hand over-using text warming might rotate the glyphs cache too quickly and diminish the optimization. Similarly, for Drawable starting on art it will be put in a texture cache of RenderNode, which will speed up drawing.

Types

Link copied to clipboard
open class WarmDrawable

Functions

Link copied to clipboard
Link copied to clipboard
Schedules a Drawable to be drawn in the background.
Link copied to clipboard
open fun warmLayout(layout: Layout)
Schedules a Layout to be drawn in the background.