public class RatioZoomContext extends ContinuousZoomContext implements ZoomContext
HINT_ID
Constructor and Description |
---|
RatioZoomContext(double initialScale,
double ratio)
Create a zoom context where zoom level 0 has a scale denominator of
initial , and each
subsequent level is ratio times that. |
RatioZoomContext(int initialLevel,
double initialScale,
double ratio)
Create a zoom context where zoom level
initialLevel has a scale denominator of initial , and each subsequent level is ratio times that. |
Modifier and Type | Method and Description |
---|---|
protected double |
getMedialScale(int level)
Get a scale between the given zoom level and the next
|
protected double |
getScaleDenominator(double level)
Find the reciprocal of the scale at a specified zoom level in this context.
|
boolean |
isInRange(int level)
Is the given level within the range for which the context has clearly defined scales.
|
getScaleDenominator
getRange
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getRange, getScaleDenominator
public RatioZoomContext(double initialScale, double ratio)
initial
, and each
subsequent level is ratio
times that.initilScalel
- scale denominator at level 0ratio
- ratio between zoom levelspublic RatioZoomContext(int initialLevel, double initialScale, double ratio)
initialLevel
has a scale denominator of initial
, and each subsequent level is ratio
times that.initialLevel
- Level to use as initialinitialScale
- scale denominator at level initialLevel
ratio
- ratio between the scale at consecutive zoom levels. Zoom level z+1 has a scale
ratio times that of z and a scale denominator 1/ratio times that of z.protected double getScaleDenominator(double level)
ContinuousZoomContext
getScaleDenominator
in class ContinuousZoomContext
level
- The levelprotected double getMedialScale(int level)
ContinuousZoomContext
getMedialScale
in class ContinuousZoomContext
public boolean isInRange(int level)
ZoomContext
isInRange
in interface ZoomContext
Copyright © 1996–2019 Geotools. All rights reserved.