SvgDecoder
actual class SvgDecoder(source: ImageSource, options: Options, val useViewBoundsAsIntrinsicSize: Boolean, val renderToBitmap: Boolean) : Decoder
A Decoder that uses AndroidSVG to decode SVG files.
expect class SvgDecoder(source: ImageSource, options: Options, useViewBoundsAsIntrinsicSize: Boolean = true, renderToBitmap: Boolean = true) : Decoder
A Decoder that uses AndroidSVG and SVGDOM to decode SVG files.
Parameters
useViewBoundsAsIntrinsicSize
If true, uses the SVG's view bounds as the intrinsic size for the SVG. If false, uses the SVG's width/height as the intrinsic size for the SVG.
renderToBitmap
If true, renders the SVG to a bitmap immediately after decoding. Else, the SVG will be rendered at draw time. Rendering at draw time is more memory efficient, but depending on the complexity of the SVG, can be slow.
actual class SvgDecoder(source: ImageSource, options: Options, val useViewBoundsAsIntrinsicSize: Boolean, val renderToBitmap: Boolean) : Decoder
Constructors
Link copied to clipboard
actual constructor(source: ImageSource, options: Options, useViewBoundsAsIntrinsicSize: Boolean, renderToBitmap: Boolean)
expect constructor(source: ImageSource, options: Options, useViewBoundsAsIntrinsicSize: Boolean = true, renderToBitmap: Boolean = true)
actual constructor(source: ImageSource, options: Options, useViewBoundsAsIntrinsicSize: Boolean, renderToBitmap: Boolean)
Types
Link copied to clipboard
actual class Factory @JvmOverloads constructor(val useViewBoundsAsIntrinsicSize: Boolean, val renderToBitmap: Boolean) : Decoder.Factory
expect class Factory @JvmOverloads constructor(useViewBoundsAsIntrinsicSize: Boolean = true, renderToBitmap: Boolean = true) : Decoder.Factory
actual class Factory @JvmOverloads constructor(val useViewBoundsAsIntrinsicSize: Boolean, val renderToBitmap: Boolean) : Decoder.Factory