Class DebugTools

java.lang.Object
com.jme3.bullet.debug.DebugTools

public class DebugTools extends Object
Debugging aids.

This class is shared between JBullet and Native Bullet.

Author:
normenhansen
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    com.jme3.scene.debug.Arrow
    mesh for the blue arrow
    com.jme3.scene.Geometry
    geometry for the blue arrow
    com.jme3.scene.debug.Arrow
    mesh for the green arrow
    com.jme3.scene.Geometry
    geometry for the green arrow
    com.jme3.scene.debug.Arrow
    mesh for the magenta arrow
    com.jme3.scene.Geometry
    geometry for the magenta arrow
    com.jme3.scene.debug.Arrow
    mesh for the pink arrow
    com.jme3.scene.Geometry
    geometry for the pink arrow
    com.jme3.scene.debug.Arrow
    mesh for the red arrow
    com.jme3.scene.Geometry
    geometry for the red arrow
    com.jme3.scene.debug.Arrow
    mesh for the yellow arrow
    com.jme3.scene.Geometry
    geometry for the yellow arrow
    com.jme3.material.Material
    unshaded blue material
    com.jme3.material.Material
    unshaded green material
    com.jme3.material.Material
    unshaded magenta material
    com.jme3.material.Material
    unshaded pink material
    com.jme3.material.Material
    unshaded red material
    com.jme3.material.Material
    unshaded yellow material
    com.jme3.scene.Node
    node for attaching debug geometries
    protected final com.jme3.asset.AssetManager
     
    protected static final com.jme3.math.Vector3f
    local copy of Vector3f.UNIT_X
    protected static final com.jme3.math.Vector3f
    local copy of Vector3f.UNIT_XYZ
    protected static final com.jme3.math.Vector3f
    local copy of Vector3f.UNIT_Y
    protected static final com.jme3.math.Vector3f
    local copy of Vector3f.UNIT_Z
    protected static final com.jme3.math.Vector3f
    local copy of Vector3f.ZERO
  • Constructor Summary

    Constructors
    Constructor
    Description
    DebugTools(com.jme3.asset.AssetManager manager)
    Instantiate a set of debug tools.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    setBlueArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
    Alter the location and extent of the blue arrow.
    void
    setGreenArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
    Alter the location and extent of the green arrow.
    void
    setMagentaArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
    Alter the location and extent of the magenta arrow.
    void
    setPinkArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
    Alter the location and extent of the pink arrow.
    void
    setRedArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
    Alter the location and extent of the red arrow.
    protected void
    Attach all the debug geometries to the debug node.
    protected void
    Initialize all the DebugTools materials.
    void
    setYellowArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
    Alter the location and extent of the yellow arrow.
    void
    show(com.jme3.renderer.RenderManager rm, com.jme3.renderer.ViewPort vp)
    Render all the debug geometries to the specified view port.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • manager

      protected final com.jme3.asset.AssetManager manager
    • DEBUG_BLUE

      public com.jme3.material.Material DEBUG_BLUE
      unshaded blue material
    • DEBUG_RED

      public com.jme3.material.Material DEBUG_RED
      unshaded red material
    • DEBUG_GREEN

      public com.jme3.material.Material DEBUG_GREEN
      unshaded green material
    • DEBUG_YELLOW

      public com.jme3.material.Material DEBUG_YELLOW
      unshaded yellow material
    • DEBUG_MAGENTA

      public com.jme3.material.Material DEBUG_MAGENTA
      unshaded magenta material
    • DEBUG_PINK

      public com.jme3.material.Material DEBUG_PINK
      unshaded pink material
    • debugNode

      public com.jme3.scene.Node debugNode
      node for attaching debug geometries
    • arrowBlue

      public com.jme3.scene.debug.Arrow arrowBlue
      mesh for the blue arrow
    • arrowBlueGeom

      public com.jme3.scene.Geometry arrowBlueGeom
      geometry for the blue arrow
    • arrowGreen

      public com.jme3.scene.debug.Arrow arrowGreen
      mesh for the green arrow
    • arrowGreenGeom

      public com.jme3.scene.Geometry arrowGreenGeom
      geometry for the green arrow
    • arrowRed

      public com.jme3.scene.debug.Arrow arrowRed
      mesh for the red arrow
    • arrowRedGeom

      public com.jme3.scene.Geometry arrowRedGeom
      geometry for the red arrow
    • arrowMagenta

      public com.jme3.scene.debug.Arrow arrowMagenta
      mesh for the magenta arrow
    • arrowMagentaGeom

      public com.jme3.scene.Geometry arrowMagentaGeom
      geometry for the magenta arrow
    • arrowYellow

      public com.jme3.scene.debug.Arrow arrowYellow
      mesh for the yellow arrow
    • arrowYellowGeom

      public com.jme3.scene.Geometry arrowYellowGeom
      geometry for the yellow arrow
    • arrowPink

      public com.jme3.scene.debug.Arrow arrowPink
      mesh for the pink arrow
    • arrowPinkGeom

      public com.jme3.scene.Geometry arrowPinkGeom
      geometry for the pink arrow
    • UNIT_X_CHECK

      protected static final com.jme3.math.Vector3f UNIT_X_CHECK
      local copy of Vector3f.UNIT_X
    • UNIT_Y_CHECK

      protected static final com.jme3.math.Vector3f UNIT_Y_CHECK
      local copy of Vector3f.UNIT_Y
    • UNIT_Z_CHECK

      protected static final com.jme3.math.Vector3f UNIT_Z_CHECK
      local copy of Vector3f.UNIT_Z
    • UNIT_XYZ_CHECK

      protected static final com.jme3.math.Vector3f UNIT_XYZ_CHECK
      local copy of Vector3f.UNIT_XYZ
    • ZERO_CHECK

      protected static final com.jme3.math.Vector3f ZERO_CHECK
      local copy of Vector3f.ZERO
  • Constructor Details

    • DebugTools

      public DebugTools(com.jme3.asset.AssetManager manager)
      Instantiate a set of debug tools.
      Parameters:
      manager - for loading assets (not null, alias created)
  • Method Details

    • show

      public void show(com.jme3.renderer.RenderManager rm, com.jme3.renderer.ViewPort vp)
      Render all the debug geometries to the specified view port.
      Parameters:
      rm - the render manager (not null)
      vp - the view port (not null)
    • setBlueArrow

      public void setBlueArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
      Alter the location and extent of the blue arrow.
      Parameters:
      location - the coordinates of the tail (not null, unaffected)
      extent - the offset of the tip from the tail (not null, unaffected)
    • setGreenArrow

      public void setGreenArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
      Alter the location and extent of the green arrow.
      Parameters:
      location - the coordinates of the tail (not null, unaffected)
      extent - the offset of the tip from the tail (not null, unaffected)
    • setRedArrow

      public void setRedArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
      Alter the location and extent of the red arrow.
      Parameters:
      location - the coordinates of the tail (not null, unaffected)
      extent - the offset of the tip from the tail (not null, unaffected)
    • setMagentaArrow

      public void setMagentaArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
      Alter the location and extent of the magenta arrow.
      Parameters:
      location - the coordinates of the tail (not null, unaffected)
      extent - the offset of the tip from the tail (not null, unaffected)
    • setYellowArrow

      public void setYellowArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
      Alter the location and extent of the yellow arrow.
      Parameters:
      location - the coordinates of the tail (not null, unaffected)
      extent - the offset of the tip from the tail (not null, unaffected)
    • setPinkArrow

      public void setPinkArrow(com.jme3.math.Vector3f location, com.jme3.math.Vector3f extent)
      Alter the location and extent of the pink arrow.
      Parameters:
      location - the coordinates of the tail (not null, unaffected)
      extent - the offset of the tip from the tail (not null, unaffected)
    • setupDebugNode

      protected void setupDebugNode()
      Attach all the debug geometries to the debug node.
    • setupMaterials

      protected void setupMaterials()
      Initialize all the DebugTools materials.