A
- pixel type of the source RandomAccessible
.B
- pixel type of the target RandomAccessibleInterval
.public class SimpleVolatileProjector<A,B> extends Object implements VolatileProjector
VolatileProjector
, that renders a target 2D
RandomAccessibleInterval
by copying values from a source
RandomAccessible
. The source can have more dimensions than the
target. Target coordinate (x,y) is copied from source coordinate
(x,y,0,...,0).
A specified number of threads is used for rendering.
Constructor and Description |
---|
SimpleVolatileProjector(RandomAccessible<A> source,
Converter<? super A,B> converter,
RandomAccessibleInterval<B> target,
int numThreads,
ExecutorService executorService)
Create new projector with the given source and a converter from source to
target pixel type.
|
Modifier and Type | Method and Description |
---|---|
void |
cancel()
Abort
VolatileProjector.map() if it is currently running. |
long |
getLastFrameRenderNanoTime()
How many nano-seconds did the last
VolatileProjector.map() take. |
boolean |
isValid() |
boolean |
map(boolean clearUntouchedTargetPixels)
Render the 2D target image by copying values from the source.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
map
public SimpleVolatileProjector(RandomAccessible<A> source, Converter<? super A,B> converter, RandomAccessibleInterval<B> target, int numThreads, ExecutorService executorService)
source
- source pixels.converter
- converts from the source pixel type to the target pixel type.target
- the target interval that this projector maps tonumThreads
- how many threads to use for rendering.executorService
- public void cancel()
VolatileProjector
VolatileProjector.map()
if it is currently running.cancel
in interface VolatileProjector
public long getLastFrameRenderNanoTime()
VolatileProjector
VolatileProjector.map()
take.getLastFrameRenderNanoTime
in interface VolatileProjector
public boolean isValid()
isValid
in interface VolatileProjector
public boolean map(boolean clearUntouchedTargetPixels)
map
in interface VolatileProjector
Copyright © 2015–2021 Fiji. All rights reserved.