public interface DisplayIntensityRanges
This interface aggregates ChannelIntensityRanges objects, one per channel,
into a single value object. It is used as a bulk convenience argument to
DisplaySettings.Builder.intensityScaling(DisplayIntensityRanges), which applies
all channel ranges in one call instead of setting each channel individually.
Each channel in turn holds per-component ranges (see ChannelIntensityRanges).
For a grayscale display with multiple channels each channel has one component;
for an RGB image each channel has three components (red=0, green=1, blue=2).
Note: this interface is write-only in the sense that
DisplaySettings does not expose a corresponding getIntensityScaling()
getter; ranges are stored inside the per-channel / per-component
ComponentDisplaySettings accessible via
DisplaySettings.getChannelSettings(int) →
ChannelDisplaySettings.getComponentSettings(int).
Instances are immutable. Use builder() or copyBuilder() to
construct one.
| Modifier and Type | Interface and Description |
|---|---|
static interface |
DisplayIntensityRanges.Builder
Builder for
DisplayIntensityRanges. |
| Modifier and Type | Method and Description |
|---|---|
static DisplayIntensityRanges.Builder |
builder()
Returns a new builder with no channels or components set (all defaults).
|
DisplayIntensityRanges.Builder |
copyBuilder()
Returns a builder pre-populated with all channel ranges from this instance.
|
java.util.List<ChannelIntensityRanges> |
getAllChannelRanges()
Returns all channel ranges as a list.
|
java.util.List<ComponentIntensityRange> |
getAllComponentRanges(int channel)
Returns all explicitly-set component ranges for the given channel as a list.
|
int |
getChannelNumberOfComponents(int channel)
Returns the number of components for which ranges have been explicitly set
in the given channel.
|
ChannelIntensityRanges |
getChannelRanges(int channel)
Returns the
ChannelIntensityRanges for the given channel. |
java.util.List<java.lang.Long> |
getComponentMaxima(int channel)
Returns the maximum values for all explicitly-set components of the given channel.
|
long |
getComponentMaximum(int channel,
int component)
Returns the maximum intensity (white point) for the given channel and component.
|
java.util.List<java.lang.Long> |
getComponentMinima(int channel)
Returns the minimum values for all explicitly-set components of the given channel.
|
long |
getComponentMinimum(int channel,
int component)
Returns the minimum intensity (black point) for the given channel and component.
|
ComponentIntensityRange |
getComponentRange(int channel,
int component)
Returns the range for the given channel and component as a
ComponentIntensityRange. |
int |
getNumberOfChannels()
Returns the number of channels for which ranges have been set.
|
static DisplayIntensityRanges.Builder builder()
DisplayIntensityRanges.Builder copyBuilder()
int getNumberOfChannels()
int getChannelNumberOfComponents(int channel)
channel - zero-based channel indexlong getComponentMinimum(int channel,
int component)
channel - zero-based channel indexcomponent - zero-based component indexlong getComponentMaximum(int channel,
int component)
channel - zero-based channel indexcomponent - zero-based component indexLong.MAX_VALUE if not explicitly set,
meaning "use the full camera bit-depth range"ComponentIntensityRange getComponentRange(int channel, int component)
ComponentIntensityRange.channel - zero-based channel indexcomponent - zero-based component indexChannelIntensityRanges getChannelRanges(int channel)
ChannelIntensityRanges for the given channel.channel - zero-based channel indexjava.util.List<ComponentIntensityRange> getAllComponentRanges(int channel)
channel - zero-based channel indexgetChannelNumberOfComponents(int)java.util.List<java.lang.Long> getComponentMinima(int channel)
channel - zero-based channel indexjava.util.List<java.lang.Long> getComponentMaxima(int channel)
channel - zero-based channel indexjava.util.List<ChannelIntensityRanges> getAllChannelRanges()
ChannelIntensityRanges, one per channel