Package sc.fiji.snt

Class MultiPathTracerCanvas

All Implemented Interfaces:
MouseListener, MouseMotionListener, ImageObserver, MenuContainer, Serializable, Cloneable, EventListener, Accessible

public class MultiPathTracerCanvas extends TracerCanvas
TracerCanvas variant that renders a caller-supplied collection of Paths: each in its own color, with one entry optionally "highlighted".

Intended for read-only wizard windows (e.g. the cost-function wizard). Supplied paths should already have their canvasOffset configured if the canvas image is a cropped sub-volume of the source (so node coordinates line up with the displayed cropped image).

Author:
Tiago Ferreira
See Also:
  • Constructor Details

    • MultiPathTracerCanvas

      public MultiPathTracerCanvas(ij.ImagePlus imp, SNT snt, PathAndFillManager pafm)
      Builds the canvas. The pafm argument is required by the TracerCanvas contract but is never iterated by this subclass — pass the SNT instance's PathAndFillManager.
  • Method Details

    • setEntries

      public void setEntries(List<MultiPathTracerCanvas.Entry> list)
      Replaces the current set of painted entries with the supplied list.
    • clearEntries

      public void clearEntries()
      Clears all entries
    • addEntry

      public void addEntry(Path path, Color color, boolean highlighted)
      Appends a single entry without repainting
    • setEitherSide

      public void setEitherSide(int either_side)
      Sets the z-slice band (either side of the current slice) over which paths still render (with reduced alpha). Pass 0 for strict per-slice rendering.
    • setHighlightedAlpha

      public void setHighlightedAlpha(int inBand, int outOfBand)
      Sets the in-band / out-of-band transparency for highlighted entries (percent).
    • setDimmedAlpha

      public void setDimmedAlpha(int inBand, int outOfBand)
      Sets the in-band / out-of-band transparency for non-highlighted entries (percent).
    • drawOverlay

      protected void drawOverlay(Graphics2D g)
      Replaces the parent's PAFM-iterating draw loop with our entry list. SeedOverlay, SearchArtist, and crosshairs are intentionally skipped — this canvas is a passive preview, not an interactive tracing surface.
      Overrides:
      drawOverlay in class TracerCanvas