Package omeis.providers.re.codomain
Class ContrastStretchingContext
- java.lang.Object
-
- omeis.providers.re.codomain.CodomainMapContext
-
- omeis.providers.re.codomain.ContrastStretchingContext
-
public class ContrastStretchingContext extends CodomainMapContext
Two pointspStart
andpEnd
define the context of this transformation. We determine the equations of 3 lines (segments to be correct). The first one is a line between the point with coordinates (intervalStart, intervalStart) and (xStart, yStart). The second one between (xStart, yStart) and (xEnd, yEnd). The third one between (xEnd, yEnd) and (intervalEnd, intervalEnd).- Since:
- OME2.2
-
-
Field Summary
-
Fields inherited from class omeis.providers.re.codomain.CodomainMapContext
intervalEnd, intervalStart
-
-
Constructor Summary
Constructors Constructor Description ContrastStretchingContext()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CodomainMapContext
copy()
Implemented as specified by superclass.double
getA0()
Returns the slope of the first line.double
getA1()
Returns the slope of the second line.double
getA2()
Returns the slope of the third line.double
getB0()
Returns the y-intercept of the first line.double
getB1()
Returns the y-intercept of the second line.double
getB2()
Returns the y-intercept of the third line.int
getXEnd()
Returns the x-coordinate of thepEnd
point.int
getXStart()
Returns the x-coordinate of thepStart
point.int
getYEnd()
Returns the y-coordinate of thepEnd
point.int
getYStart()
Returns the y-coordinate of thepStart
point.void
setCoordinates(int xStart, int yStart, int xEnd, int yEnd)
Sets the coordinates of the points used to determine the equations of the lines.void
setXEnd(int v)
Sets the x-coodinate of thepEnd
point.void
setXStart(int v)
Sets the x-coodinate of thepStart
point.void
setYEnd(int v)
Sets the y-coodinate of thepEnd
point.void
setYStart(int v)
Sets the y-coodinate of thepStart
point.-
Methods inherited from class omeis.providers.re.codomain.CodomainMapContext
equals, setCodomain
-
-
-
-
Method Detail
-
copy
public CodomainMapContext copy()
Implemented as specified by superclass.- Specified by:
copy
in classCodomainMapContext
- Returns:
- See above.
- See Also:
CodomainMapContext.copy()
-
setCoordinates
public void setCoordinates(int xStart, int yStart, int xEnd, int yEnd)
Sets the coordinates of the points used to determine the equations of the lines.- Parameters:
xStart
- The x-coodinate of thepStart
point.yStart
- The y-coodinate of thepStart
point.xEnd
- The x-coodinate of thepEnd
point.yEnd
- The y-coodinate of thepEnd
point.
-
setXStart
public void setXStart(int v)
Sets the x-coodinate of thepStart
point.- Parameters:
v
- The value to set.
-
setXEnd
public void setXEnd(int v)
Sets the x-coodinate of thepEnd
point.- Parameters:
v
- The value to set.
-
setYStart
public void setYStart(int v)
Sets the y-coodinate of thepStart
point.- Parameters:
v
- The value to set.
-
setYEnd
public void setYEnd(int v)
Sets the y-coodinate of thepEnd
point.- Parameters:
v
- The value to set.
-
getXEnd
public int getXEnd()
Returns the x-coordinate of thepEnd
point.- Returns:
- See above.
-
getXStart
public int getXStart()
Returns the x-coordinate of thepStart
point.- Returns:
- See above.
-
getYEnd
public int getYEnd()
Returns the y-coordinate of thepEnd
point.- Returns:
- See above.
-
getYStart
public int getYStart()
Returns the y-coordinate of thepStart
point.- Returns:
- See above.
-
getA0
public double getA0()
Returns the slope of the first line.- Returns:
- See above.
-
getA1
public double getA1()
Returns the slope of the second line.- Returns:
- See above.
-
getA2
public double getA2()
Returns the slope of the third line.- Returns:
- See above.
-
getB0
public double getB0()
Returns the y-intercept of the first line.- Returns:
- See above.
-
getB1
public double getB1()
Returns the y-intercept of the second line.- Returns:
- See above.
-
getB2
public double getB2()
Returns the y-intercept of the third line.- Returns:
- See above.
-
-