Package globus.glmap

Class ImageManager

java.lang.Object
globus.glmap.ImageManager

@ParametersAreNonnullByDefault
public class ImageManager
extends java.lang.Object
ImageManager renders images from svgpb format and load images from resources.
  • Field Summary

    Fields 
    Modifier and Type Field Description
    float screenScale  
  • 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

    Modifier and Type Method Description
    android.graphics.Bitmap open​(java.lang.String path, float scaleForVector, int tintColor)
    Opens image from assetManager

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • ImageManager

      public ImageManager​(android.content.res.AssetManager assetManager, float screenScale)
      Constructor of ImageManager.
      Parameters:
      assetManager - AssetManager used to load image data
      screenScale - Scale to use while loading vector images
    • ImageManager

      public ImageManager​(android.content.res.AssetManager assetManager, android.view.Display display)
      Constructor of ImageManager.
      Parameters:
      assetManager - AssetManager used to load image data
      display - Display to use to calculate scale
  • Method Details

    • open

      @Nullable public android.graphics.Bitmap open​(java.lang.String path, float scaleForVector, int tintColor)
      Opens image from assetManager
      Parameters:
      path - path to image
      scaleForVector - 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