public class SingleDimensionTransformation extends Object implements MathTransformation
MathTransformation
implementation for single-dimensional operationsModifier and Type | Class and Description |
---|---|
static class |
SingleDimensionTransformation.ConstantTransform
SingleDimensionTransformation extension defining Constant transformations |
Modifier and Type | Field and Description |
---|---|
static SingleDimensionTransformation |
IDENTITY |
protected double |
offset
Offset transformation parameter
|
protected double |
scale
Scale transformation parameter
|
Modifier | Constructor and Description |
---|---|
protected |
SingleDimensionTransformation(double scale,
double offset) |
Modifier and Type | Method and Description |
---|---|
static SingleDimensionTransformation |
create(double scale,
double offset)
Creates a
SingleDimensionTransformation instance based on the input scale and offset |
double |
derivative(double value)
Returns the derivative value of the provided transformation
|
double |
getOffset() |
double |
getScale() |
int |
getSourceDimensions()
Returns the input transformation dimensions
|
int |
getTargetDimensions()
Returns the output transformation dimensions
|
MathTransformation |
inverseTransform()
Returns the inverse transformation of the current transform
|
boolean |
isIdentity()
Indicates whether the transformation is an identity
|
boolean |
isIdentity(double tolerance)
Returns true if the transformation is an identity, with a tolerance value
|
void |
setOffset(double offset) |
void |
setScale(double scale) |
double |
transform(double value)
Transforms input value using the provided transformation
|
Position |
transform(Position ptSrc,
Position ptDst)
|
public static final SingleDimensionTransformation IDENTITY
protected double scale
protected double offset
protected SingleDimensionTransformation(double scale, double offset)
public double getScale()
public void setScale(double scale)
public double getOffset()
public void setOffset(double offset)
public double transform(double value)
MathTransformation
transform
in interface MathTransformation
public double derivative(double value)
MathTransformation
derivative
in interface MathTransformation
public int getSourceDimensions()
MathTransformation
getSourceDimensions
in interface MathTransformation
public int getTargetDimensions()
MathTransformation
getTargetDimensions
in interface MathTransformation
public MathTransformation inverseTransform()
MathTransformation
inverseTransform
in interface MathTransformation
public boolean isIdentity()
MathTransformation
isIdentity
in interface MathTransformation
public boolean isIdentity(double tolerance)
public static SingleDimensionTransformation create(double scale, double offset)
SingleDimensionTransformation
instance based on the input scale and offsetscale
- offset
- public Position transform(Position ptSrc, Position ptDst)
MathTransformation
transform
in interface MathTransformation
Copyright © 2006–2018 GeoSolutions. All rights reserved.