use of ini.trakem2.utils.Filter in project TrakEM2 by trakem2.
the class RegularizedAffineLayerAlignment method exec.
/**
* Stateful. Changing the parameters of this instance. Do not use in parallel.
*
* @param layerSet
* @param firstIn
* @param lastIn
* @param ref
* @param propagateTransformBefore
* @param propagateTransformAfter
* @param fov
* @param filter
*/
public final void exec(final LayerSet layerSet, final int firstIn, final int lastIn, final int ref, final boolean propagateTransformBefore, final boolean propagateTransformAfter, final Rectangle fov, final Filter<Patch> filter) throws Exception {
final int first = Math.min(firstIn, lastIn);
final int last = Math.max(firstIn, lastIn);
/* always first index first despite the method would return inverse order if last > first */
final List<Layer> layerRange = layerSet.getLayers(first, last);
final HashSet<Layer> fixedLayers = new HashSet<Layer>();
if (ref - first >= 0)
fixedLayers.add(layerRange.get(ref - first));
Utils.log(layerRange.size() + "");
exec(layerRange, fixedLayers, propagateTransformBefore, propagateTransformAfter, fov, filter);
}
Aggregations