Class Align
Align the bounding-box to the
larger without resizing.- Author:
- Owen Feehan
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected BoundingBoxalignAfterCheck(BoundingBox smaller, BoundingBox larger) protected BoundingBoxalignAfterCheck(Extent smaller, BoundingBox larger) protected BoundingBoxalignAfterCheck(Extent smaller, Extent larger) alignCorner(BoundingBox smaller, Extent larger) The minimum corner at which the entity should be locate after alignment, ignoring the space to the left.voidcheckMisconfigured(BeanInstanceMap defaultInstances) Checks that a bean's properties conform to expectations.Creates a new bean that deep-copies every property value.Indicates how to align the image across the X-axis (i.e. horizontally): one ofleft, right, center.Indicates how to align the image across the Y-axis (i.e. vertically): one oftop, bottom, center.Indicates how to align the image across the Z-axis: one oftop, bottom, center, repeat.voidIndicates how to align the image across the X-axis (i.e. horizontally): one ofleft, right, center.voidIndicates how to align the image across the Y-axis (i.e. vertically): one oftop, bottom, center.voidIndicates how to align the image across the Z-axis: one oftop, bottom, center, repeat.Methods inherited from class org.anchoranalysis.image.bean.spatial.arrange.align.BoxAligner
align, align, alignMethods inherited from class org.anchoranalysis.bean.AnchorBean
describeBean, describeChildren, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
-
Constructor Details
-
Align
Creates with alignment text for each axis.- Parameters:
alignX- indicates how to align the image across the X-axis: one oftop, bottom, center.alignY- indicates how to align the image across the Y-axis (i.e. vertically): one oftop, bottom, center.alignZ- indicates how to align the image across the Z-axis: one oftop, bottom, center, repeat. SeealignZ.
-
Align
public Align()
-
-
Method Details
-
checkMisconfigured
Description copied from class:AnchorBeanChecks that a bean's properties conform to expectations.- Overrides:
checkMisconfiguredin classAnchorBean<BoxAligner>- Parameters:
defaultInstances- all available default instances if theDefaultInstanceannotation is used- Throws:
BeanMisconfiguredException- if the bean has not been configured properly as XML
-
alignAfterCheck
Description copied from class:BoxAligner- Specified by:
alignAfterCheckin classBoxAligner- Parameters:
smaller- the smaller bounding-box, relative to the minimum-corner oflarger. Often this is(0, 0, 0)if it sits at the minimum corner oflarger.larger- the larger bounding-box absolute coordinates.- Returns:
- absolute coordinates for
smaller, while remaining insidelarger.
-
alignAfterCheck
protected BoundingBox alignAfterCheck(Extent smaller, Extent larger) throws OperationFailedException Description copied from class:BoxAligner- Specified by:
alignAfterCheckin classBoxAligner- Parameters:
smaller- the smaller bounding-box, relative to the minimum-corner oflarger. Often this is(0, 0, 0)if it sits at the minimum corner oflarger.larger- the larger bounding-box absolute coordinates.- Returns:
- absolute coordinates for
smaller, while remaining insidelarger. - Throws:
OperationFailedException- if an unrecognized parameter or illegal state exists preventing successful alignment.
-
alignAfterCheck
protected BoundingBox alignAfterCheck(Extent smaller, BoundingBox larger) throws OperationFailedException Description copied from class:BoxAligner- Specified by:
alignAfterCheckin classBoxAligner- Parameters:
smaller- the smaller bounding-box, relative to the minimum-corner oflarger. Often this is(0, 0, 0)if it sits at the minimum corner oflarger.larger- the larger bounding-box absolute coordinates.- Returns:
- absolute coordinates for
smaller, while remaining insidelarger. - Throws:
OperationFailedException- if an unrecognized parameter or illegal state exists preventing successful alignment.
-
alignCorner
The minimum corner at which the entity should be locate after alignment, ignoring the space to the left.- Parameters:
smaller- the smaller size to align withlarger.larger- the larger size to align against as a reference.- Returns:
- the minimum corner to use for the aligned box, newly-created.
-
duplicateBean
Description copied from class:AnchorBeanCreates a new bean that deep-copies every property value.Any state that is not a
BeanFieldis ignored.- Overrides:
duplicateBeanin classAnchorBean<BoxAligner>- Returns:
- the newly created bean
-
getAlignX
Indicates how to align the image across the X-axis (i.e. horizontally): one ofleft, right, center. -
setAlignX
Indicates how to align the image across the X-axis (i.e. horizontally): one ofleft, right, center. -
getAlignY
Indicates how to align the image across the Y-axis (i.e. vertically): one oftop, bottom, center. -
setAlignY
Indicates how to align the image across the Y-axis (i.e. vertically): one oftop, bottom, center. -
getAlignZ
Indicates how to align the image across the Z-axis: one oftop, bottom, center, repeat.repeatis a special-case where a single z-slice overlay will be duplicated across the z-dimension of the stack onto which it is overlayed. -
setAlignZ
Indicates how to align the image across the Z-axis: one oftop, bottom, center, repeat.repeatis a special-case where a single z-slice overlay will be duplicated across the z-dimension of the stack onto which it is overlayed.
-