RoadShieldIconProvider

Provides road shield and exit sign images.

It automatically scales images based on the device's display density. To generate images at a specific DPI, create a custom configuration context:

private const val TARGET_DPI = 240

val customConfig = applicationContext.resources.configuration.apply {
densityDpi = TARGET_DPI
}
val provider = RoadShieldIconProvider(
context = applicationContext.createConfigurationContext(customConfig)
)

Parameters

context

The application context.

Constructors

Link copied to clipboard
constructor(context: Context)

Properties

Link copied to clipboard

Style mode used when generating road shield or exit sign images.

Functions

Link copied to clipboard

Generates an exit sign image based on an exit sign reference and the associated exit number, for example Signpost.exitIconReference and Signpost.exitNumber.

Link copied to clipboard

Generates a road shield image based on a RoadShield.iconReference and the associated RoadShield.shieldContent.