mixxxdj / mixxx

Mixxx is Free DJ software that gives you everything you need to perform live mixes.
http://mixxx.org
Other
4.51k stars 1.28k forks source link

[EffectX] audibly enabled only every 2nd time toggled ON when "mix"=0 #8702

Closed mixxxbot closed 2 years ago

mixxxbot commented 2 years ago

Reported by: ronso0 Date: 2016-11-29T05:19:23Z Status: Fix Released Importance: Undecided Launchpad Issue: lp1645565 Tags: effects, script


Apparently effect is enabled audibly(!) only every SECOND time GUI and MIDI say it's ON if Wet/Dry is set to 0 when toggling that effect ON. This happens for Effect1-3, no matter if 1,2 or all 3 are enabled at the same time. Just toggle them all while Wet/Dry is 0.

1) assign [EffectRack1_EffecetUnit1] to [Channel1], enable it 2) load an effect to [EffectRak1_EffecetUnit1_Effect1], choose one that is easily audible like BitCrusher and leave it OFF 3) turn "Wet/Dry" of [EffectRack1_EffecetUnit1] to 0 4) load a track to [Channel1], play it 5) enable [Effect1] 6) increase Wet/Dry so you would normally hear the BitCrusher   > Do you? I don't. 7) set Wet/Dry back to 0 8) disable [Effect1] 9) enable [Effect1] 10) increase Wet/Dry   > do you hear [Effect1]? Now I do 3-6) I can't hear it 7-10) I CAN hear it ...and so on

2.1.0-alpha-pre (build master r5996) (will try current master as soon as it has a rev.number) 2.0.0.1 (build 1.12 r5769)

Linux 3.14.23-rt20 #⁠1 SMP PREEMPT RT x86_64 GNU/Linux

skin: Deere and FlatNite http://www.mixxx.org/forums/viewtopic.php?f=8&t=8578

mixxxbot commented 2 years ago

Commented by: daschuer Date: 2016-11-29T09:46:30Z


When "mix" is 0 when enabling the effect you should not hear the effect at all. Because it is fully dry = bypassed. If this is not the case this sounds like an engine bug.

You could verify the current values of the controls by starting Mixxx using: mixxx --developer

Now the tooltips are displaying the current value. And you are able to whatch all Control objects in the developer menu.

You may also run your script and save all COs in a CVS file before and after.

Is it possible to reproduce the faulty behavior using the developers menu only?

Does it happen in latest master build? Maybe https://bugs.launchpad.net/mixxx/+bug/1609270 is related.

mixxxbot commented 2 years ago

Commented by: ronso0 Date: 2016-12-01T13:00:39Z


Yeah, of course I don't hear the effect when "mix" is 0.
"0" is just the position when toggling the effect, after that I increase "mix".
My initial description might be to complex.
Procedure is like this:
1. mix = 0, effect_enabled = 0 
2. switch effect with "fxSlot1_enabled != fxSlot1_enabled"
> status is updated in GUI
3. 0 < "mix" < 1
> effect is NOT audible
4. set "mix" to 0 again
5. switch effect off with script
repeat 1, 2, 3...
> effect is audible
repeat 1, 2, 3...
> effect is NOT audible
repeat 1, 2, 3...
> effect is audible

As mentioned above: toggling the effect like this works everytime
  if (fxSlot1_enabled == false) {
    fxSlot1_enableds = 1;}
  else {
    fxSlot1_enabled = 0;}
So I suppose it has to do with binary/boolean.
Also it works when mapping "mix" knob to 0,001-1 instead of 0-1.
mixxxbot commented 2 years ago

Commented by: Be-ing Date: 2016-12-01T20:30:01Z


I'm confused why you're manipulating both the effect enabled switch and the mix knob. If you want to toggle the effect, just use the enabled switch.

Also, this code looks strange:
engine.setValue("[EffectRack1_EffectUnit1_Effect1]","enabled",+fxSlot1_enabled+);

I'm not sure what's going on with those +'s around fxslot1_enabled, but they're probably doing some implicit type conversion that isn't quite what you think it is. JavaScript's type conversions can be really weird and unintuitive, especially with the + operator. Generally, you shouldn't rely on implict type conversions in JavaScript. For some humorously absurd examples, see https://www.destroyallsoftware.com/talks/wat

mixxxbot commented 2 years ago

Commented by: ronso0 Date: 2016-12-03T14:17:12Z


I'm sorry for the confusion about the script part, forget that: I can reproduce it with GUI, without any controller/script involved. r5996 I'll updat the dsecription accordingly, please give it a try.

@Be You're right about enclosing the var like +var+ but it doesn't make a different. And mapping "mix" like I mentioned was a workaround I came across by chance. It still applies when reproducing this bug when you use it instead of the GUI knob.

mixxxbot commented 2 years ago

Commented by: sblaisot Date: 2016-12-03T15:31:01Z


Ronny,

Which OS an which skin do you use ?

Are you able to reproduce it using Mixxx 2.0.0 (last stable release) ?

mixxxbot commented 2 years ago

Commented by: sblaisot Date: 2016-12-03T15:33:35Z


also, are you able to reproduce the bug if you disable your controller in the settings (uncheck the "enabled" checkbox on the controller page) ?

mixxxbot commented 2 years ago

Commented by: ronso0 Date: 2016-12-03T18:19:02Z


2.1.0-alpha-pre (build master r5996) 2.0.0.1 (build 1.12 r5769)

Linux 3.14.23-rt20 #⁠1 SMP PREEMPT RT x86_64 GNU/Linux

skin: Deere and FlatNite http://www.mixxx.org/forums/viewtopic.php?f=8&t=8578

yes, controller is disabled.

mixxxbot commented 2 years ago

Commented by: ronso0 Date: 2017-02-18T16:55:26Z


Bug still present in build master r6201. Tested with clean profile and mouse-only.

mixxxbot commented 2 years ago

Commented by: Be-ing Date: 2017-04-10T19:59:02Z


Another way of explaining the bug: if an effect is enabled when the "mix" (dry/wet) ControlPotmeter > 0, then mix is set to 0, then the effect is disabled while mix is still 0, enabling the effect while mix is still 0 does not work. This is a bug in the effect chain optimization code.

mixxxbot commented 2 years ago

Commented by: Be-ing Date: 2017-04-10T20:08:27Z


https://github.com/mixxxdj/mixxx/pull/1234

mixxxbot commented 2 years ago

Issue closed with status Fix Released.