public abstract class LensTransformer extends MutableTransformerDecorator implements MutableTransformer
| Modifier and Type | Class and Description |
|---|---|
protected class |
LensTransformer.ComponentListenerImpl
react to size changes on a component
|
| Modifier and Type | Field and Description |
|---|---|
protected RectangularShape |
lensShape
the area affected by the transform
|
protected float |
magnification |
delegate| Constructor and Description |
|---|
LensTransformer(Component component,
MutableTransformer delegate)
create an instance with a possibly shared transform
|
| Modifier and Type | Method and Description |
|---|---|
double |
getDistanceFromCenter(Point2D p) |
RectangularShape |
getLensShape() |
float |
getMagnification() |
double |
getRatio() |
Point2D |
getViewCenter() |
double |
getViewRadius() |
abstract Point2D |
inverseTransform(Point2D viewPoint)
override base class to un-project the fisheye effect
|
Shape |
inverseTransform(Shape shape)
return the supplied shape, translated to the coordinates
that result from calling inverseTransform on its center
|
void |
setLensShape(RectangularShape ellipse) |
void |
setMagnification(float magnification) |
void |
setToIdentity() |
void |
setViewCenter(Point2D viewCenter) |
void |
setViewRadius(double viewRadius) |
abstract Point2D |
transform(Point2D graphPoint)
override base class transform to project the fisheye effect
|
Shape |
transform(Shape shape)
return the supplied shape, translated to the coordinates
that result from calling transform on its center
|
addChangeListener, concatenate, fireStateChanged, getChangeListeners, getDelegate, getRotation, getScale, getScaleX, getScaleY, getShearX, getShearY, getTransform, getTranslateX, getTranslateY, preConcatenate, removeChangeListener, rotate, rotate, scale, setDelegate, setScale, setTranslate, shear, translateclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitconcatenate, getRotation, getScale, getScaleX, getScaleY, getShearX, getShearY, getTransform, getTranslateX, getTranslateY, preConcatenate, rotate, rotate, scale, setScale, setTranslate, shear, translateaddChangeListener, fireStateChanged, getChangeListeners, removeChangeListenerprotected RectangularShape lensShape
protected float magnification
public LensTransformer(Component component, MutableTransformer delegate)
component - delegate - public float getMagnification()
public void setMagnification(float magnification)
magnification - The magnification to set.public Point2D getViewCenter()
public void setViewCenter(Point2D viewCenter)
viewCenter - The viewCenter to set.public double getViewRadius()
public void setViewRadius(double viewRadius)
viewRadius - The viewRadius to set.public double getRatio()
public void setLensShape(RectangularShape ellipse)
public RectangularShape getLensShape()
public void setToIdentity()
setToIdentity in interface MutableTransformersetToIdentity in class MutableTransformerDecoratorpublic abstract Point2D transform(Point2D graphPoint)
transform in interface BidirectionalTransformertransform in class MutableTransformerDecoratorgraphPoint - graph point to convertpublic abstract Point2D inverseTransform(Point2D viewPoint)
inverseTransform in interface BidirectionalTransformerinverseTransform in class MutableTransformerDecoratorviewPoint - screen point to convertpublic double getDistanceFromCenter(Point2D p)
public Shape transform(Shape shape)
transform in interface BidirectionalTransformertransform in interface ShapeTransformertransform in class MutableTransformerDecoratorpublic Shape inverseTransform(Shape shape)
inverseTransform in interface BidirectionalTransformerinverseTransform in interface ShapeTransformerinverseTransform in class MutableTransformerDecoratorCopyright © 2015. All rights reserved.