Package cn.mapway.common.geo.geotools
Class GenerateThumbnail
java.lang.Object
cn.mapway.common.geo.geotools.GenerateThumbnail
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic org.geotools.styling.StylecreatePolygonStyle(Color outlineColor, float strokeWidth, Color fillColor, float opacity) static voidgenerateRaster(File imageUrl, File labelUrl, File thumbnailUrl) 生成缩略图static voidgenerateRaster(File imageUrl, File labelUrl, File thumbnailUrl, int width, int height) static booleangenerateVector(File rasterFile, String geojsons, int splitSize, File exportUrl, boolean gcsFlag) 导出缩略图static booleangenerateVector(File rasterFile, String geojsons, int splitSize, File exportUrl, double quality, String imageFormat, boolean gcsFlag) static voidstatic BufferedImagestatic byte[]readPixelValues(org.gdal.gdal.Band band) static byte[]readPixelValues(org.gdal.gdal.Band band, int dataType, Double min, Double max) static byte[]readPixelValues(org.gdal.gdal.Band band, Double min, Double max) static byte[]
-
Constructor Details
-
GenerateThumbnail
public GenerateThumbnail()
-
-
Method Details
-
generateRaster
public static void generateRaster(File imageUrl, File labelUrl, File thumbnailUrl, int width, int height) throws IOException - Throws:
IOException
-
generateRaster
public static void generateRaster(File imageUrl, File labelUrl, File thumbnailUrl) throws IOException 生成缩略图- Parameters:
imageUrl- 栅格底图文件labelUrl- 栅格标注文件thumbnailUrl- 缩略图文件- Throws:
IOException
-
generateVector
public static boolean generateVector(File rasterFile, String geojsons, int splitSize, File exportUrl, boolean gcsFlag) throws IOException 导出缩略图- Parameters:
rasterFile- 栅格底图文件geojsons- 矢量geojson信息splitSize- 切片大小exportUrl- 导出路径, 导出路径最后不要带有后缀- Returns:
- Throws:
IOException
-
generateVector
public static boolean generateVector(File rasterFile, String geojsons, int splitSize, File exportUrl, double quality, String imageFormat, boolean gcsFlag) throws IOException - Throws:
IOException
-
createPolygonStyle
-
readImage
-
readPixelValues
public static byte[] readPixelValues(org.gdal.gdal.Band band) -
readPixelValues
-
readPixelValues
-
stretch
-
main
- Throws:
IOException
-