Location renderer: fix indicator minimum size #171
This commit is contained in:
parent
bc0bbcb4b5
commit
9b460b0f3b
@ -28,6 +28,11 @@ import org.oscim.utils.math.Interpolation;
|
|||||||
import static org.oscim.backend.GLAdapter.gl;
|
import static org.oscim.backend.GLAdapter.gl;
|
||||||
|
|
||||||
public class LocationRenderer extends LayerRenderer {
|
public class LocationRenderer extends LayerRenderer {
|
||||||
|
|
||||||
|
private static final long ANIM_RATE = 50;
|
||||||
|
private static final long INTERVAL = 2000;
|
||||||
|
|
||||||
|
private static final float CIRCLE_SIZE = 60;
|
||||||
private static final int SHOW_ACCURACY_ZOOM = 16;
|
private static final int SHOW_ACCURACY_ZOOM = 16;
|
||||||
|
|
||||||
public enum Shader {SHADER_1, SHADER_2}
|
public enum Shader {SHADER_1, SHADER_2}
|
||||||
@ -42,11 +47,6 @@ public class LocationRenderer extends LayerRenderer {
|
|||||||
private int hPhase;
|
private int hPhase;
|
||||||
private int hDirection;
|
private int hDirection;
|
||||||
|
|
||||||
private static final float CIRCLE_SIZE = 60;
|
|
||||||
|
|
||||||
private static final long ANIM_RATE = 50;
|
|
||||||
private static final long INTERVAL = 2000;
|
|
||||||
|
|
||||||
private final Point mIndicatorPosition = new Point();
|
private final Point mIndicatorPosition = new Point();
|
||||||
|
|
||||||
private final Point mScreenPoint = new Point();
|
private final Point mScreenPoint = new Point();
|
||||||
@ -199,8 +199,9 @@ public class LocationRenderer extends LayerRenderer {
|
|||||||
if (!mLocationIsVisible /* || pos.zoomLevel < SHOW_ACCURACY_ZOOM */) {
|
if (!mLocationIsVisible /* || pos.zoomLevel < SHOW_ACCURACY_ZOOM */) {
|
||||||
//animate(true);
|
//animate(true);
|
||||||
} else {
|
} else {
|
||||||
if (v.pos.zoomLevel >= mShowAccuracyZoom && mRadius > 0)
|
if (v.pos.zoomLevel >= mShowAccuracyZoom)
|
||||||
radius = (float) (mRadius * v.pos.scale);
|
radius = (float) (mRadius * v.pos.scale);
|
||||||
|
radius = Math.max(CIRCLE_SIZE, radius);
|
||||||
|
|
||||||
viewShed = true;
|
viewShed = true;
|
||||||
//animate(false);
|
//animate(false);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user