Package globus.glmap
Class ImageManager
- java.lang.Object
-
- globus.glmap.ImageManager
-
public class ImageManager extends java.lang.ObjectImageManagerrenders images from svg format and load images from resources.
-
-
Field Summary
Fields Modifier and Type Field Description floatscreenScale
-
Constructor Summary
Constructors Constructor Description ImageManager(android.content.res.AssetManager assetManager, float screenScale)Constructor of ImageManager.ImageManager(android.content.res.AssetManager assetManager, android.view.Display display)Constructor of ImageManager.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description android.graphics.Bitmapopen(java.lang.String path, float scaleForVector, int tintColor)Opens image from assetManager
-
-
-
Constructor Detail
-
ImageManager
public ImageManager(@NonNull android.content.res.AssetManager assetManager, float screenScale)Constructor of ImageManager.- Parameters:
assetManager- AssetManager used to load image datascreenScale- Scale to use while loading vector images
-
ImageManager
public ImageManager(@NonNull android.content.res.AssetManager assetManager, android.view.Display display)Constructor of ImageManager.- Parameters:
assetManager- AssetManager used to load image datadisplay- Display to use to calculate scale
-
-
Method Detail
-
open
@Nullable public android.graphics.Bitmap open(@NonNull java.lang.String path, float scaleForVector, int tintColor)Opens image from assetManager- Parameters:
path- path to imagescaleForVector- additional scale to use for vector image (actual scale will be screenScale*scaleForVector)tintColor- tint color to use for vector images- Returns:
- Loaded bitmap or null
-
-