public class SciViewSNT
extends java.lang.Object
SciView, allowing Trees to be rendered as Scenery objects| Constructor and Description |
|---|
SciViewSNT(org.scijava.Context context)
Instantiates a new SciViewSNT instance.
|
SciViewSNT(sc.iview.SciView sciView)
Instantiates SciViewSNT from an existing SciView instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addTree(Tree tree)
Adds a tree to the associated SciView instance.
|
sc.iview.SciView |
getSciView()
Gets the SciView instance currently in use.
|
graphics.scenery.Node |
getTreeAsSceneryNode(Tree tree)
Gets the specified Tree as a Scenery Node.
|
static void |
main(java.lang.String[] args) |
boolean |
removeTree(Tree tree)
Removes the specified Tree.
|
void |
setSciView(sc.iview.SciView sciView)
Sets the SciView to be used.
|
public SciViewSNT(org.scijava.Context context)
context - the SciJava application context providing the services
required by the classorg.scijava.NullContextException - If context is nullpublic SciViewSNT(sc.iview.SciView sciView)
sciView - the SciView instance to be associated with this SciViewSNT
instancejava.lang.NullPointerException - If sciView is nullpublic sc.iview.SciView getSciView()
public void setSciView(sc.iview.SciView sciView)
sciView - the SciView instance. Null allowed.public void addTree(Tree tree)
setSciView(SciView) has not been
called.tree - the Tree to be added. The Tree's label will be used as
identifier. It is expected to be unique when rendering multiple
Trees, if not (or no label exists) a unique label will be
generated.Tree.getLabel(),
Tree.setColor(ColorRGB)public graphics.scenery.Node getTreeAsSceneryNode(Tree tree)
tree - the tree previously added to SciView using addTree(Tree)public boolean removeTree(Tree tree)
tree - the tree previously added to SciView using addTree(Tree)addTree(Tree)public static void main(java.lang.String[] args)
throws java.lang.InterruptedException
java.lang.InterruptedException