Package heronarts.lx.mixer
Class LXMixerEngine
java.lang.Object
heronarts.lx.LXComponent
heronarts.lx.mixer.LXMixerEngine
- All Implemented Interfaces:
LXPath,LXSerializable,LXOscComponent,LXParameterListener
Encapsulation of all the LX channel blending and mixer
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic interfacestatic classNested classes/interfaces inherited from class heronarts.lx.LXComponent
LXComponent.Description, LXComponent.Hidden, LXComponent.Name, LXComponent.Placeholder, LXComponent.PluginRequired, LXComponent.RenamableNested classes/interfaces inherited from interface heronarts.lx.LXSerializable
LXSerializable.Utils -
Field Summary
FieldsModifier and TypeFieldDescriptionfinal BooleanParameterfinal BooleanParameterfinal BooleanParameterfinal List<LXAbstractChannel> final CompoundParameterfinal ObjectParameter<LXBlend> final BooleanParameterfinal BooleanParameterfinal DiscreteParameterfinal DiscreteParameterfinal LXMasterBusstatic final Stringstatic final Stringstatic final Stringfinal BooleanParameterfinal BooleanParameterfinal BooleanParameterFields inherited from class heronarts.lx.LXComponent
childArrays, children, internalParameters, KEY_CHILDREN, KEY_CLASS, KEY_COMPONENT_ID, KEY_ID, KEY_INTERNAL, KEY_PARAMETER_PATH, KEY_PARAMETERS, KEY_PATH, KEY_RESET, label, legacyInternalParameters, legacyParameters, lx, modulationColor, modulationControlsExpanded, modulationsExpanded, parameters, presetFileFields inherited from interface heronarts.lx.LXPath
DEFAULT_SEPARATOR, ROOT, ROOT_PREFIX, ROOT_SLASH -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddChannel(int index) addChannel(int index, JsonObject channelObj) addChannel(int index, JsonObject channelObj, LXPattern[] patterns) addChannel(int index, LXPattern[] patterns) addChannel(JsonObject channelObj) addChannel(LXPattern[] patterns) addGroup()addGroup(int index) final LXMixerEngineaddListener(LXMixerEngine.Listener listener) voidclear()Removes all channels and clears the master busdeselectChannel(LXBus bus) voiddispose()Invoked when a component is being removed from the system and will no longer be used at all.enableChannelAux(LXAbstractChannel channel, boolean isExclusive) enableChannelCue(LXAbstractChannel channel, boolean isExclusive) getChannel(int channelIndex) getChannel(String label) booleanhandleOscMessage(OscMessage message, String[] parts, int index) Handles an OSC message sent to this component.LXBlend[]instantiateChannelBlends(LXComponent context) protected LXBlend[]protected LXBlend[]instantiateTransitionBlends(LXChannel channel) voidload(LX lx, JsonObject obj) Loads the LX component.voidloadChannel(JsonObject channelObj) voidloadChannel(JsonObject channelObj, int index) voidloop(LXEngine.Frame render, double deltaMs) voidmoveChannel(LXAbstractChannel channel, int delta) Move a channel by a relative increment.voidmoveChannel(LXAbstractChannel bus, int index, LXGroup group) Move a channel to a specified index, possibly adding or removing to a groupvoidSubclasses are free to override this if desired.voidremoveChannel(LXAbstractChannel channel) final LXMixerEngineremoveListener(LXMixerEngine.Listener listener) voidvoidsave(LX lx, JsonObject obj) Serializes the LX component.selectChannel(LXBus bus) selectChannel(LXBus bus, boolean multipleSelection) selectChannelRange(LXBus destination) setFocusedChannel(LXBus channel) setFocusedChannelAux(LXBus channel) Methods inherited from class heronarts.lx.LXComponent
addArray, addChild, addInternalParameter, addLegacyInternalParameter, addLegacyParameter, addParameter, addParameter, addParameters, assertDisposed, contains, copyParameters, getCategory, getChild, getComponentDescription, getComponentName, getComponentName, getComponentName, getDescription, getId, getLabel, getLX, getOscAddress, getOscLabel, getOscPath, getParameter, getParameters, getParent, getPath, hasParameter, isValidOscParameter, loadParameters, loadPreset, removeParameter, removeParameter, removeParameter, removeParameter, savePreset, setDescription, setParent, toOscQuery, toOscQuery, toOscQuery, toString, toStringMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface heronarts.lx.osc.LXOscComponent
getOscAddressMethods inherited from interface heronarts.lx.LXPath
getCanonicalLabel, getCanonicalLabel, getCanonicalLabel, getCanonicalLabel, getCanonicalLabel, getCanonicalPath, getCanonicalPath, isDescendant
-
Field Details
-
channels
-
masterBus
-
focusedChannel
-
focusedChannelAux
-
crossfader
-
crossfaderBlendMode
-
cueA
-
cueB
-
auxA
-
auxB
-
autoMuteDefault
-
viewCondensed
-
viewStacked
-
viewDeviceBin
-
PATH_CHANNEL
- See Also:
-
PATH_FOCUSED
- See Also:
-
PATH_MASTER
- See Also:
-
-
Constructor Details
-
LXMixerEngine
-
-
Method Details
-
addListener
-
removeListener
-
onParameterChanged
Description copied from class:LXComponentSubclasses are free to override this if desired. It will automatically fire for any listenable parameter that is registered with this component.- Specified by:
onParameterChangedin interfaceLXParameterListener- Overrides:
onParameterChangedin classLXComponent- Parameters:
p- Parameter that has a value change
-
handleOscMessage
Description copied from class:LXComponentHandles an OSC message sent to this component. By default this method handles registered components and parameters, but subclasses may override this method to handle different types of OSC messages.- Specified by:
handleOscMessagein interfaceLXOscComponent- Overrides:
handleOscMessagein classLXComponent- Parameters:
message- Full OSC message objectparts- The OSC address pattern, broken into an array of partsindex- Which index into the parts array corresponds to this component's children- Returns:
trueif the OSC message was handled and should be considered consumed,falseotherwise
-
instantiateChannelBlends
-
instantiateTransitionBlends
-
instantiateCrossfaderBlends
-
getChannels
-
getDefaultChannel
-
getLastChannel
-
getChannel
-
getChannel
-
getFocusedChannel
-
setFocusedChannel
-
getFocusedChannelAux
-
setFocusedChannelAux
-
deselectChannel
-
selectChannel
-
selectChannel
-
selectChannelRange
-
addChannel
-
addChannel
-
addChannel
-
addChannel
-
addChannel
-
addChannel
-
addChannel
-
group
-
ungroup
-
addGroupFromSelection
-
addGroup
-
addGroup
-
addGroup
-
getSelectedChannelsForGroup
-
removeSelectedChannels
public void removeSelectedChannels() -
removeChannel
-
moveChannel
Move a channel by a relative increment. Handles group overlap moves automatically.- Parameters:
channel- Channel to movedelta- Relative amount to move by
-
moveChannel
Move a channel to a specified index, possibly adding or removing to a group- Parameters:
bus- Channel to moveindex- Index position to move togroup- Group the channel should belong to, or null
-
enableChannelCue
-
enableChannelAux
-
loop
-
save
Description copied from class:LXComponentSerializes 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 callsuper.save(lx, obj)at the appropriate time.- Specified by:
savein interfaceLXSerializable- Overrides:
savein classLXComponent- Parameters:
lx- LX instanceobj- Object to serialize into
-
load
Description copied from class:LXComponentLoads 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:
loadin interfaceLXSerializable- Overrides:
loadin classLXComponent- Parameters:
lx- LX instanceobj- Object to deserialize
-
dispose
public void dispose()Description copied from class:LXComponentInvoked when a component is being removed from the system and will no longer be used at all. This unregisters the component and should free up any resources and parameter listeners. Ideally after this method is called the object should be eligible for garbage collection. Subclasses are generally expected to override this method to handle their particular cleanup work. They should also generally callsuper.dispose()at the appropriate time to perform the basic cleanup, which may need to happen either before or after cleaning up other objects.- Overrides:
disposein classLXComponent
-
clear
public void clear()Removes all channels and clears the master bus -
loadChannel
-
loadChannel
-