public class MBTilesLoaderUtils
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected static java.util.Map<java.lang.String,java.sql.Connection> |
connectionsMap |
static java.lang.String |
SQLITE_JDBC_DRIVER |
Constructor and Description |
---|
MBTilesLoaderUtils() |
Modifier and Type | Method and Description |
---|---|
protected static processing.core.PImage |
getAsImage(byte[] bytes)
Converts the byte array into a PImage.
|
static processing.core.PImage |
getMBTile(int column,
int row,
int zoomLevel,
java.lang.String jdbcConnectionString)
Loads the tile for given parameters as image.
|
protected static byte[] |
getMBTileData(int column,
int row,
int zoomLevel,
java.lang.String jdbcConnectionString)
Loads the MBTile data from the database as blob, and returns it as byte array.
|
public static final java.lang.String SQLITE_JDBC_DRIVER
protected static java.util.Map<java.lang.String,java.sql.Connection> connectionsMap
public static processing.core.PImage getMBTile(int column, int row, int zoomLevel, java.lang.String jdbcConnectionString)
column
- The column of the tile.row
- The row of the tile.zoomLevel
- The zoom level of the tile.jdbcConnectionString
- The path to the MBTiles database.protected static byte[] getMBTileData(int column, int row, int zoomLevel, java.lang.String jdbcConnectionString) throws java.lang.Exception
column
- The column of the tile.row
- The row of the tile.zoomLevel
- The zoom level of the tile.java.lang.Exception
protected static processing.core.PImage getAsImage(byte[] bytes)
bytes
- The image information as byte array.