Class LXStructure

java.lang.Object
heronarts.lx.LXComponent
heronarts.lx.structure.LXStructure
All Implemented Interfaces:
LXPath, LXSerializable, LXParameterListener, LXFixtureContainer

public class LXStructure extends LXComponent implements LXFixtureContainer
  • Field Details

  • Constructor Details

  • Method Details

    • getPath

      public String getPath()
      Description copied from class: LXComponent
      Accessor for the path of this object. Returns the path this component was registered with. Some subclasses may override this if path structure is dynamic.
      Specified by:
      getPath in interface LXPath
      Overrides:
      getPath in class LXComponent
      Returns:
      path of this component relative to its parent
    • getModelFile

      public File getModelFile()
    • getModel

      public LXModel getModel()
    • addListener

      public LXStructure addListener(LXStructure.Listener listener)
    • removeListener

      public LXStructure removeListener(LXStructure.Listener listener)
    • addFixture

      public LXStructure addFixture(LXFixture fixture)
    • addFixture

      public LXStructure addFixture(LXFixture fixture, int index)
    • moveFixture

      public LXStructure moveFixture(LXFixture fixture, int index)
    • selectFixtureRange

      public LXStructure selectFixtureRange(LXFixture fixture)
    • selectAllFixtures

      public LXStructure selectAllFixtures()
    • selectFixture

      public LXStructure selectFixture(LXFixture fixture)
    • selectFixture

      public LXStructure selectFixture(LXFixture fixture, boolean isMultipleSelection)
    • soloFixture

      public LXStructure soloFixture(LXFixture fixture)
    • getSelectedFixtures

      public List<LXFixture> getSelectedFixtures()
    • removeFixtures

      public LXStructure removeFixtures(List<LXFixture> fixtures)
    • removeSelectedFixtures

      public LXStructure removeSelectedFixtures()
    • removeFixture

      public LXStructure removeFixture(LXFixture fixture)
    • translateSelectedFixtures

      public LXStructure translateSelectedFixtures(float tx, float ty, float tz)
    • translateSelectedFixtures

      public LXStructure translateSelectedFixtures(float tx, float ty, float tz, LXCommand.Structure.ModifyFixturePositions action)
    • rotateSelectedFixtures

      public LXStructure rotateSelectedFixtures(float theta, float phi)
    • rotateSelectedFixtures

      public LXStructure rotateSelectedFixtures(float theta, float phi, LXCommand.Structure.ModifyFixturePositions action)
    • adjustSelectedFixtureBrightness

      public LXStructure adjustSelectedFixtureBrightness(float delta)
    • enableSelectedFixtures

      public LXStructure enableSelectedFixtures(boolean enabled)
    • identifySelectedFixtures

      public LXStructure identifySelectedFixtures(boolean identify)
    • newDynamicModel

      public LXStructure newDynamicModel()
    • setStaticModel

      public LXStructure setStaticModel(LXModel model)
    • fixtureGenerationChanged

      public void fixtureGenerationChanged(LXFixture fixture)
      Description copied from interface: LXFixtureContainer
      The generation of this fixture has changed, its metrics or hierarchy are now different. The container will need to take this into account.
      Specified by:
      fixtureGenerationChanged in interface LXFixtureContainer
      Parameters:
      fixture - Fixture that has changed
    • fixtureGeometryChanged

      public void fixtureGeometryChanged(LXFixture fixture)
      Description copied from interface: LXFixtureContainer
      The geometry of this fixture has changed, its metrics and hierarchy are consistent but the point locations may have changed.
      Specified by:
      fixtureGeometryChanged in interface LXFixtureContainer
      Parameters:
      fixture - Fixture that has changed
    • fixtureOutputChanged

      public void fixtureOutputChanged(LXFixture fixture)
      Description copied from interface: LXFixtureContainer
      The output settings of this fixture has changed, the top level structure should re-consolidate all the outputs.
      Specified by:
      fixtureOutputChanged in interface LXFixtureContainer
      Parameters:
      fixture - Fixture that has changed
    • fixtureTagsChanged

      public void fixtureTagsChanged(LXFixture fixture)
      Description copied from interface: LXFixtureContainer
      The tags of this fixture has changed, the container will need to take this into account.
      Specified by:
      fixtureTagsChanged in interface LXFixtureContainer
      Parameters:
      fixture - Fixture that has changed
    • isExternalModel

      public boolean isExternalModel()
    • isDirty

      public boolean isDirty()
    • reload

      public void reload()
    • load

      public void load(LX lx, JsonObject obj)
      Description copied from class: LXComponent
      Loads the LX component. Restores the ID of the component, as well as its internal and user-facing parameters. Any explicitly registered children will be automatically loaded, so long as they are direct descendants. Dynamic arrays will not be automatically loaded, this is left to subclasses to implement.
      Specified by:
      load in interface LXSerializable
      Overrides:
      load in class LXComponent
      Parameters:
      lx - LX instance
      obj - Object to deserialize
    • save

      public void save(LX lx, JsonObject obj)
      Description copied from class: LXComponent
      Serializes the LX component. By default, all internal and user-facing parameters are serialized, as well as any explicitly registered child components. Note that child arrays are not serialized, or any other dynamic components. Subclasses may override to perform more saving, and are expected to call super.save(lx, obj) at the appropriate time.
      Specified by:
      save in interface LXSerializable
      Overrides:
      save in class LXComponent
      Parameters:
      lx - LX instance
      obj - Object to serialize into
    • importModel

      public LXStructure importModel(File file)
    • exportModel

      public LXStructure exportModel(File file)
    • exportViews

      public void exportViews(File file)
    • importViews

      public List<LXViewDefinition> importViews(File file)