Class ExtractToRGB
Object
org.anchoranalysis.bean.AnchorBean<ChannelConvertStyle>
org.anchoranalysis.plugin.image.task.bean.format.convertstyle.ChannelConvertStyle
org.anchoranalysis.plugin.image.task.bean.format.convertstyle.ExtractToRGB
public class ExtractToRGB extends ChannelConvertStyle
Extracts three channels to make an RGB image.
If the expected red/blue/green names in RGBChannelNames exist, these channels are
used. Any other channels are ignored.
Otherwise, if exactly three channels exist, without the expected-names then the underlying order is used from the set.
If more than three channel exist, the first three are arbitrarily according by the underlying set ordering (usually alphabetical).
If a single-channel exists only, it is triplicated to form an RGB.
If two channels-exists, a blank is left in the green channel, and the blue and red channel are chosen by the underlying set ordering (usually alphabetical).
- Author:
- Owen Feehan
-
Constructor Summary
Constructors Constructor Description ExtractToRGB() -
Method Summary
Modifier and Type Method Description org.anchoranalysis.image.core.stack.named.NamedStacksconvert(Set<String> channelNames, ChannelGetterForTimepoint channelGetter, org.anchoranalysis.core.log.Logger logger)Converts a particular set of channels.ChannelConvertStylegetFallback()If a channel doesn't match an RGB pattern, this conversion-style can be used instead.voidsetFallback(ChannelConvertStyle fallback)If a channel doesn't match an RGB pattern, this conversion-style can be used instead.
-
Constructor Details
-
ExtractToRGB
public ExtractToRGB()
-
-
Method Details
-
convert
public org.anchoranalysis.image.core.stack.named.NamedStacks convert(Set<String> channelNames, ChannelGetterForTimepoint channelGetter, org.anchoranalysis.core.log.Logger logger) throws org.anchoranalysis.core.exception.OperationFailedExceptionDescription copied from class:ChannelConvertStyleConverts a particular set of channels.- Specified by:
convertin classChannelConvertStyle- Parameters:
channelNames- a set of names of the channels to convert.channelGetter- gets a particular channel at a particular time-point.logger- the logger.- Returns:
- the results of the conversion.
- Throws:
org.anchoranalysis.core.exception.OperationFailedException- if the conversion fails to successfully complete.
-
getFallback
If a channel doesn't match an RGB pattern, this conversion-style can be used instead.If unset, an error is instead thrown in this circumstances
-
setFallback
If a channel doesn't match an RGB pattern, this conversion-style can be used instead.If unset, an error is instead thrown in this circumstances
-