Update polyline auto scaling width.
This commit is contained in:
parent
6ae4e88d23
commit
bc70c4267d
@ -22,11 +22,17 @@ public class PaintUtils {
|
|||||||
* @param width
|
* @param width
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
public static int getStrokeWidth(int width, byte zoomLevel) {
|
public static float getStrokeWidth(int width, byte zoomLevel) {
|
||||||
int mul = 2;
|
float mul = 1;
|
||||||
if (zoomLevel < 8) {
|
if (zoomLevel < 6) {
|
||||||
mul = 1;
|
mul = 1;
|
||||||
}
|
}
|
||||||
|
else if (zoomLevel < 10) {
|
||||||
|
mul += (zoomLevel - 5) * 0.5;
|
||||||
|
}
|
||||||
|
else if (zoomLevel < 13) {
|
||||||
|
mul = 3.5f;
|
||||||
|
}
|
||||||
else {
|
else {
|
||||||
mul += 2 * (zoomLevel - 8) / 3;
|
mul += 2 * (zoomLevel - 8) / 3;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user