Version: 5.3.3-ice35-b63

OmeroBlitz API
Home Previous Up Next Index

omero::api::RenderingEngine

Overview

[ "ami", "amd" ] interface RenderingEngine extends PyramidService

Defines a service to render a given pixels set. A pixels set is a 5D array that stores the pixels data of an image, that is the pixels intensity values. Every instance of this service is paired up to a pixels set. Use this service to transform planes within the pixels set onto an RGB image. The RenderingEngine allows to fine-tune the settings that define the transformation context — that is, a specification of how raw pixels data is to be transformed into an image that can be displayed on screen. Those settings are referred to as rendering settings or display options. After tuning those settings it is possible to save them to the metadata repository so that they can be used the next time the pixels set is accessed for rendering; for example by another RenderingEngine instance. Note that the display options are specific to the given pixels set and are experimenter scoped — that is, two different users can specify different display options for the same pixels set. (A RenderingEngine instance takes this into account automatically as it is always bound to a given experimenter.) This service is thread-safe.

Operation Index

render
Renders the data selected by def according to the current rendering settings.
renderAsPackedInt
Renders the data selected by def according to the current rendering settings.
renderProjectedAsPackedInt
Performs a projection through selected optical sections of a particular timepoint with the currently active channels and renders the data for display.
renderCompressed
Renders the data selected by def according to the current rendering settings and compresses the resulting RGBA composite image.
renderProjectedCompressed
Performs a projection through selected optical sections of a particular timepoint with the currently active channels, renders the data for display and compresses the resulting RGBA composite image.
getRenderingDefId
Returns the id of the model::RenderingDef loaded by either lookupRenderingDef or loadRenderingDef.
lookupPixels
Loads the Pixels set this Rendering Engine is for.
lookupRenderingDef
Loads the rendering settings associated to the specified pixels set.
loadRenderingDef
Loads a specific set of rendering settings that does not necessarily have to be linked to the given Pixels set.
setOverlays
Informs the rendering engine that it should render a set of overlays on each rendered frame.

Deprecated.

load
Creates an instance of the rendering engine.
setModel
Specifies the model that dictates how transformed raw data has to be mapped onto a color space.
getModel
Returns the model that dictates how transformed raw data has to be mapped onto a color space.
getDefaultZ
Returns the index of the default focal section.
getDefaultT
Returns the default timepoint index.
setDefaultZ
Sets the index of the default focal section.
setDefaultT
Sets the default timepoint index.
getPixels
Returns the model::Pixels set the Rendering engine is for.
getAvailableModels
Returns the list of color models supported by the Rendering engine.
getAvailableFamilies
Returns the list of mapping families supported by the Rendering engine.
setQuantumStrategy
Sets the quantization strategy.
setCodomainInterval
Sets the sub-interval of the device space i.e.
getQuantumDef
Returns the quantization object.
setQuantizationMap
Sets the quantization map, one per channel.
getChannelFamily
Returns the family associated to the specified channel.
getChannelNoiseReduction
Returns true if the noise reduction algorithm used to map the pixels intensity values is turned on, false if the algorithm is turned off.
getChannelStats
getChannelCurveCoefficient
Returns the coefficient identifying a map in the family.
setChannelWindow
Returns the pixels intensity interval.
getChannelWindowStart
Returns the lower bound of the pixels intensity interval.
getChannelWindowEnd
Returns the upper bound of the pixels intensity interval.
setRGBA
Sets the four components composing the color associated to the specified channel.
getRGBA
Returns a 4D-array representing the color associated to the specified channel.
setActive
Maps the specified channel if true, unmaps the channel otherwise.
isActive
Returns true if the channel is mapped, false otherwise.
setChannelLookupTable
getChannelLookupTable
addCodomainMap
Adds the context to the mapping chain.

Deprecated.

updateCodomainMap
Updates the specified context.

Deprecated.

removeCodomainMap
Removes the specified context from the chain.

Deprecated.

addCodomainMapToChannel
Adds the context to the mapping chain.
removeCodomainMapFromChannel
Removes the specified context from the chain.
saveCurrentSettings
Saves the current rendering settings in the database.
saveAsNewSettings
Saves the current rendering settings in the database as a new model::RenderingDef and loads the object into the current RenderingEngine.
resetDefaultSettings
Resets the default settings i.e.
setCompressionLevel
Sets the current compression level for the service.
getCompressionLevel
Returns the current compression level for the service.
isPixelsTypeSigned
Returns true if the pixels type is signed, false otherwise.
getPixelsTypeUpperBound
Returns the minimum value for that channels depending on the pixels type and the original range (globalmax, globalmin) @param w The channel index.
getPixelsTypeLowerBound
Returns the maximum value for that channels depending on the pixels type and the original range (globalmax, globalmin) @param w The channel index.
getCodomainMapContext
Returns the list of codomain contexts for the specified channel.

Operations

romio::RGBBuffer render(romio::PlaneDef def) throws ServerError

Renders the data selected by def according to the current rendering settings. The passed argument selects a plane orthogonal to one of the X, Y, or Z axes. How many wavelengths are rendered and what color model is used depends on the current rendering settings.

Parameters

def
Selects a plane orthogonal to one of the X, Y, or Z axes.

Return Value

An RGB image ready to be displayed on screen.

Exceptions

ValidationException
If def is null.

::Ice::IntSeq renderAsPackedInt(romio::PlaneDef def) throws ServerError

Renders the data selected by def according to the current rendering settings. The passed argument selects a plane orthogonal to one of the X, Y, or Z axes. How many wavelengths are rendered and what color model is used depends on the current rendering settings.

Parameters

def
Selects a plane orthogonal to one of the X, Y, or Z axes.

Return Value

An RGB image ready to be displayed on screen.

Exceptions

ValidationException
If def is null.

See Also

render

::Ice::IntSeq renderProjectedAsPackedInt(constants::projection::ProjectionType algorithm, int timepoint, int stepping, int start, int end) throws ServerError

Performs a projection through selected optical sections of a particular timepoint with the currently active channels and renders the data for display.

Parameters

algorithm
ome::api::IProjection::MAXIMUM_INTENSITY, ome::api::IProjection::MEAN_INTENSITY or ome::api::IProjection::SUM_INTENSITY.
stepping
Stepping value to use while calculating the projection. For example, stepping=1 will use every optical section from start to end where stepping=2 will use every other section from start to end to perform the projection.
start
Optical section to start projecting from.
end
Optical section to finish projecting.

Return Value

A packed-integer RGBA rendered image of the projected pixels.

Exceptions

ValidationException
Where:

See Also

IProjection::projectPixels

::Ice::ByteSeq renderCompressed(romio::PlaneDef def) throws ServerError

Renders the data selected by def according to the current rendering settings and compresses the resulting RGBA composite image.

Parameters

def
Selects a plane orthogonal to one of the X, Y or Z axes.

Return Value

A compressed RGBA JPEG for display.

Exceptions

ValidationException
If def is null.

See Also

render
renderAsPackedInt

::Ice::ByteSeq renderProjectedCompressed(constants::projection::ProjectionType algorithm, int timepoint, int stepping, int start, int end) throws ServerError

Performs a projection through selected optical sections of a particular timepoint with the currently active channels, renders the data for display and compresses the resulting RGBA composite image.

Parameters

algorithm
ome::api::IProjection::MAXIMUM_INTENSITY, ome::api::IProjection::MEAN_INTENSITY or ome::api::IProjection::SUM_INTENSITY.
stepping
Stepping value to use while calculating the projection. For example, stepping=1 will use every optical section from start to end where stepping=2 will use every other section from start to end to perform the projection.
start
Optical section to start projecting from.
end
Optical section to finish projecting.

Return Value

A compressed RGBA rendered JPEG image of the projected pixels.

Exceptions

ValidationException
Where:

See Also

IProjection::projectPixels

long getRenderingDefId() throws ServerError

Returns the id of the model::RenderingDef loaded by either lookupRenderingDef or loadRenderingDef.

void lookupPixels(long pixelsId) throws ServerError

Loads the Pixels set this Rendering Engine is for.

Parameters

pixelsId
The pixels set ID.

bool lookupRenderingDef(long pixelsId) throws ServerError

Loads the rendering settings associated to the specified pixels set.

Parameters

pixelsId
The pixels set ID.

Return Value

true if a RenderingDef exists for the Pixels set, otherwise false.

void loadRenderingDef(long renderingDefId) throws ServerError

Loads a specific set of rendering settings that does not necessarily have to be linked to the given Pixels set. However, the rendering settings must be linked to a compatible Pixels set as defined by IRenderingSettings::sanityCheckPixels.

Parameters

renderingDefId
The rendering definition ID.

Exceptions

ValidationException
If a RenderingDef does not exist with the ID renderingDefId or if the RenderingDef is incompatible due to differing pixels sets.

void setOverlays(RLong tablesId, RLong imageId, LongIntMap rowColorMap) throws ServerError

Informs the rendering engine that it should render a set of overlays on each rendered frame. These are expected to be binary masks.

This operation is deprecated.

Parameters

overlays
Binary mask to color map.

void load() throws ServerError

Creates an instance of the rendering engine.

void setModel(model::RenderingModel model) throws ServerError

Specifies the model that dictates how transformed raw data has to be mapped onto a color space.

Parameters

model
Identifies the color space model.

model::RenderingModel getModel() throws ServerError

Returns the model that dictates how transformed raw data has to be mapped onto a color space.

int getDefaultZ() throws ServerError

Returns the index of the default focal section.

int getDefaultT() throws ServerError

Returns the default timepoint index.

void setDefaultZ(int z) throws ServerError

Sets the index of the default focal section. This index is used to define a default plane.

Parameters

z
The value to set.

void setDefaultT(int t) throws ServerError

Sets the default timepoint index. This index is used to define a default plane.

Parameters

t
The value to set.

model::Pixels getPixels() throws ServerError

Returns the model::Pixels set the Rendering engine is for.

IObjectList getAvailableModels() throws ServerError

Returns the list of color models supported by the Rendering engine.

IObjectList getAvailableFamilies() throws ServerError

Returns the list of mapping families supported by the Rendering engine.

void setQuantumStrategy(int bitResolution) throws ServerError

Sets the quantization strategy. The strategy is common to all channels.

Parameters

bitResolution
The bit resolution defining associated to the strategy.

void setCodomainInterval(int start, int end) throws ServerError

Sets the sub-interval of the device space i.e. a discrete sub-interval of [0, 255].

Parameters

start
The lower bound of the interval.
end
The upper bound of the interval.

model::QuantumDef getQuantumDef() throws ServerError

Returns the quantization object.

void setQuantizationMap(int w, model::Family fam, double coefficient, bool noiseReduction) throws ServerError

Sets the quantization map, one per channel.

Parameters

w
The channel index.
family
The mapping family.
coefficient
The coefficient identifying a curve in the family.
noiseReduction
Pass true to turn the noise reduction algorithm on, false otherwise.

See Also

getAvailableFamilies
getChannelCurveCoefficient
getChannelFamily
getChannelNoiseReduction

model::Family getChannelFamily(int w) throws ServerError

Returns the family associated to the specified channel.

Parameters

w
The channel index.

Return Value

See above.

See Also

getAvailableFamilies

bool getChannelNoiseReduction(int w) throws ServerError

Returns true if the noise reduction algorithm used to map the pixels intensity values is turned on, false if the algorithm is turned off. Each channel has an algorithm associated to it.

Parameters

w
The channel index.

Return Value

See above.

::Ice::DoubleSeq getChannelStats(int w) throws ServerError

double getChannelCurveCoefficient(int w) throws ServerError

Returns the coefficient identifying a map in the family. Each channel has a map associated to it.

Parameters

w
The channel index.

Return Value

See above.

See Also

getChannelFamily

void setChannelWindow(int w, double start, double end) throws ServerError

Returns the pixels intensity interval. Each channel has a pixels intensity interval associated to it.

Parameters

w
The channel index.
start
The lower bound of the interval.
end
The upper bound of the interval.

double getChannelWindowStart(int w) throws ServerError

Returns the lower bound of the pixels intensity interval. Each channel has a pixels intensity interval associated to it.

Parameters

w
The channel index.

double getChannelWindowEnd(int w) throws ServerError

Returns the upper bound of the pixels intensity interval. Each channel has a pixels intensity interval associated to it.

Parameters

w
The channel index.

void setRGBA(int w, int red, int green, int blue, int alpha) throws ServerError

Sets the four components composing the color associated to the specified channel.

Parameters

w
The channel index.
red
The red component. A value between 0 and 255.
green
The green component. A value between 0 and 255.
blue
The blue component. A value between 0 and 255.
alpha
The alpha component. A value between 0 and 255.

::Ice::IntSeq getRGBA(int w) throws ServerError

Returns a 4D-array representing the color associated to the specified channel. The first element corresponds to the red component (value between 0 and 255). The second corresponds to the green component (value between 0 and 255). The third corresponds to the blue component (value between 0 and 255). The fourth corresponds to the alpha component (value between 0 and 255).

Parameters

w
The channel index.

void setActive(int w, bool active) throws ServerError

Maps the specified channel if true, unmaps the channel otherwise.

Parameters

w
The channel index.
active
Pass true to map the channel, false otherwise.

bool isActive(int w) throws ServerError

Returns true if the channel is mapped, false otherwise.

Parameters

w
The channel index.

void setChannelLookupTable(int w, string lookup) throws ServerError

string getChannelLookupTable(int w) throws ServerError

void addCodomainMap(romio::CodomainMapContext mapCtx) throws ServerError

Adds the context to the mapping chain. Only one context of the same type can be added to the chain. The codomain transformations are functions from the device space to device space. Each time a new context is added, the second LUT is rebuilt.

This operation is deprecated.

Parameters

mapCtx
The context to add.

See Also

updateCodomainMap
removeCodomainMap

void updateCodomainMap(romio::CodomainMapContext mapCtx) throws ServerError

Updates the specified context. The codomain chain already contains the specified context. Each time a new context is updated, the second LUT is rebuilt.

This operation is deprecated.

Parameters

mapCtx
The context to update.

See Also

addCodomainMap
removeCodomainMap

void removeCodomainMap(romio::CodomainMapContext mapCtx) throws ServerError

Removes the specified context from the chain. Each time a new context is removed, the second LUT is rebuilt.

This operation is deprecated.

Parameters

mapCtx
The context to remove.

See Also

addCodomainMap
updateCodomainMap

void addCodomainMapToChannel(romio::CodomainMapContext mapCtx, int w) throws ServerError

Adds the context to the mapping chain. Only one context of the same type can be added to the chain. The codomain transformations are functions from the device space to device space. Each time a new context is added, the second LUT is rebuilt.

Parameters

mapCtx
The context to add.
w
The channel to add the context to.

See Also

removeCodomainMapFromChannel

void removeCodomainMapFromChannel(romio::CodomainMapContext mapCtx, int w) throws ServerError

Removes the specified context from the chain. Each time a new context is removed, the second LUT is rebuilt.

Parameters

mapCtx
The context to remove.
w
The channel to remove the context from.

See Also

addCodomainMapToChannel

void saveCurrentSettings() throws ServerError

Saves the current rendering settings in the database.

long saveAsNewSettings() throws ServerError

Saves the current rendering settings in the database as a new model::RenderingDef and loads the object into the current RenderingEngine.

long resetDefaultSettings(bool save) throws ServerError

Resets the default settings i.e. the default values internal to the Rendering engine. The settings will be saved.

Parameters

save
Pass true to save the settings, false otherwise.

void setCompressionLevel(float percentage) throws ServerError

Sets the current compression level for the service. (The default is 85%)

Parameters

percentage
A percentage compression level from 1.00 (100%) to 0.01 (1%).

Exceptions

ValidationException
if the percentage

float getCompressionLevel() throws ServerError

Returns the current compression level for the service.

bool isPixelsTypeSigned() throws ServerError

Returns true if the pixels type is signed, false otherwise.

double getPixelsTypeUpperBound(int w) throws ServerError

Returns the minimum value for that channels depending on the pixels type and the original range (globalmax, globalmin)

Parameters

w
The channel index.

double getPixelsTypeLowerBound(int w) throws ServerError

Returns the maximum value for that channels depending on the pixels type and the original range (globalmax, globalmin)

Parameters

w
The channel index.

IObjectList getCodomainMapContext(int w) throws ServerError

Returns the list of codomain contexts for the specified channel.

Parameters

w
The channel index.

Home Previous Up Next Index