Class VFBUtils

java.lang.Object
sc.fiji.snt.annotation.VFBUtils

public class VFBUtils extends Object
Utility methods for accessing/handling Virtual Fly Brain (VFB) annotations
Author:
Tiago Ferreira
  • Method Details

    • isDatabaseAvailable

      public static boolean isDatabaseAvailable()
      Checks whether a connection to the Virtual Fly Brain database can be established.
      Returns:
      true, if an HHTP connection could be established
    • brainBarycentre

      public static SNTPoint brainBarycentre(String templateBrain)
      Returns the spatial centroid of an adult Drosophila template brain.
      Parameters:
      templateBrain - the template brain to be loaded (case-insensitive). Either "JFRC2" (AKA JFRC2010, VFB), "JFRC3" (AKA JFRC2013), "JFRC2018" or "FCWB" (FlyCircuit Whole Brain Template)
      Returns:
      the SNT point defining the (X,Y,Z) center of brain mesh.
    • getRefBrain

      public static OBJMesh getRefBrain(String templateBrain) throws IllegalArgumentException
      Retrieves the surface mesh of an adult Drosophila template brain. No Internet connection is required, as these meshes (detailed on the nat.flybrains documentation) are bundled with SNT.
      Parameters:
      templateBrain - the template brain to be loaded (case-insensitive). Either "JFRC2" (AKA JFRC2010, VFB), "JFRC3" (AKA JFRC2013), "JFRC2018", or "FCWB" (FlyCircuit Whole Brain Template)
      Returns:
      the template mesh.
      Throws:
      IllegalArgumentException - if templateBrain is not recognized
    • getMesh

      public static OBJMesh getMesh(String vfbId)
      Retrieves the mesh associated with the specified VFB id.
      Parameters:
      vfbId - the VFB id, e.g., VFB_00017894, 00017894
      Returns:
      a reference to the retrieved mesh
    • getMesh

      public static OBJMesh getMesh(String vfbId, org.scijava.util.ColorRGB color)
      Retrieves the mesh associated with the specified VFB id.
      Parameters:
      vfbId - the VFB id, e.g., VFB_00017894, 00017894
      color - the color to be assigned to the mesh
      Returns:
      a reference to the retrieved mesh
    • getXYZLabels

      public static String[] getXYZLabels()
      Returns:
      the anatomical descriptions associated with the Cartesian X,Y,Z axes
    • main

      public static void main(String[] args)