getDensityDpi

open fun getDensityDpi(@NonNull resources: Resources): Int(source)

Returns the target screen density being rendered to.

Uses Configuration.densityDpi when available, otherwise an approximation is computed and returned.