public enum DpiType extends Enum<DpiType>
Enum Constant and Description |
---|
HDPI
High pixel density (scale factor 1.5).
|
LDPI
Low pixel density (scale factor 0.75).
|
MDPI
Baseline pixel density (scale factor 1.0).
|
XHDPI
Extra high pixel density (scale factor 2.0).
|
XXHDPI
Extra extra high pixel density (scale factor 3.0).
|
Modifier and Type | Method and Description |
---|---|
static DpiType |
from(Resolution baseline,
Resolution target)
Get the DPI type from resolution difference.
|
static DpiType |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static DpiType[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final DpiType LDPI
public static final DpiType MDPI
public static final DpiType HDPI
public static final DpiType XHDPI
public static final DpiType XXHDPI
public static DpiType[] values()
for (DpiType c : DpiType.values()) System.out.println(c);
public static DpiType valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static DpiType from(Resolution baseline, Resolution target)
baseline
- The baseline resolution.target
- The target resolution.Copyright © 2017 Byron 3D Games Studio. All rights reserved.