Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Certain Mallets produce only noise #7573

Open
1 task done
zzzhang12 opened this issue Nov 5, 2024 · 9 comments
Open
1 task done

Certain Mallets produce only noise #7573

zzzhang12 opened this issue Nov 5, 2024 · 9 comments

Comments

@zzzhang12
Copy link

zzzhang12 commented Nov 5, 2024

System Information

MacOS 14.5, MacBook Air (chip: Apple M3)

LMMS Version(s)

1.2.2 (OS_X/x86_64,Qt 5.15.0, GCC 4.2.1 Compatible Apple LLVM 11.0.0 (clang-1100.0.33.17)

Bug Summary

The uniform bar, tuned bar, glass, and Tibetan bowl produces only noise instead of the actual sound of the instruments.

Expected Behaviour

Switching to either one of these instruments should create the respective sound.

Steps To Reproduce

No specific steps or settings required.
I only started a new project, added a Mallets instrument, switched to the specific instrument I mentioned, clicked on (holder) the piano keyboard.

Please search the issue tracker for existing bug reports before submitting your own.

  • I have searched all existing issues and confirmed that this is not a duplicate.
@zzzhang12 zzzhang12 added the bug label Nov 5, 2024
@zonkmachine
Copy link
Member

Test adding an envelope (second instrument tab).
This plugin has updates in the latest development versions. Download the 1.3 development release (Nightly) if you want to test it.

@musikBear

This comment has been minimized.

@zonkmachine

This comment has been minimized.

@Rossmaxx Rossmaxx added the stable branch This issue applies to the latest stable label Nov 30, 2024
@Rossmaxx
Copy link
Contributor

@zzzhang12 can you confirm if this is still a thing in master? If not, you can close this.

@Monospace-V
Copy link
Contributor

2024-12-21.23-27-52.mp4

is OP referring to how the notes don't sound like different notes but just like different frequencies? @zzzhang12 , can you clarify?

I have reason to believe that this behaviour is what OP is referring to, since I initially was confused by it also, simply didn't question it then.

@zonkmachine
Copy link
Member

I have reason to believe that this behaviour is what OP is referring to, since I initially was confused by it also, simply didn't question it then.

It sounds like something ring modulated which is commonly used in percussion sound synthesis. Try a volume envelope on it. To me it sounds like it's intended to.

@zonkmachine
Copy link
Member

zonkmachine commented Dec 23, 2024

The instruments in Mallets are summoned from three different instruments in the stk library that are quite different from each other. The last four Mallet instruments come from stk's BandedWG.
https://github.com/thestk/stk/blob/master/src%2FBandedWG.cpp

They are actually not completely implemented and in an earlier PR I simply removed some knobs that hadn't been implemented. It's a compromise. My suggestion at that time was to actually remove those four instruments completely as they were more or less broken. It's quite a complex module and actually not currently a simulation of something being stricken, as the other instruments are, but by something 'bowed'. I think the original coder of Mallets may simply have misunderstood it's use but I also think it should be able to use the module in a 'stricken' mode but I haven't been able to implement this. If someone wants to dig deeper into this, I would recommend trying to poke the BandedWG module directly via the terminal or via csound to see what capabilities it has that we've missed.

I think this is not really a bug but a feature request and a lack of documentation.

@zonkmachine zonkmachine added enhancement and removed bug stable branch This issue applies to the latest stable labels Dec 23, 2024
@michaelgregorius
Copy link
Contributor

Judging by the linked documentation is seems that the banded waveguide needs some more expressive input capabilities to not sound as monotonous as it currently does:

    Control Change Numbers: 
       - Bow Pressure = 2
       - Bow Motion = 4
       - Strike Position = 8 (not implemented)
       - Vibrato Frequency = 11
       - Gain = 1
       - Bow Velocity = 128
       - Set Striking = 64

@zonkmachine
Copy link
Member

Found an example for BandedWG under Chuck that could give a hint on how to use it. The example uses Strike Position which is not implemented according to the stk documentation so that may not work,... or the stk documentation is wrong.
https://chuck.cs.princeton.edu/doc/examples/stk/bandedwg.ck

Here's an online Chuck server with the example loaded:
Press: Start WebChucK (orange button) and then Run (Green button)

// STK BandedWG

// patch
BandedWG bwg => dac;

// scale
[0, 2, 4, 7, 8, 11] @=> int scale[];

// infinite time loop
while( true )
{
    // ding!
    Math.random2f( 0, 1 ) => bwg.bowRate;
    Math.random2f( 0, 1 ) => bwg.bowPressure;
    Math.random2f( 0, 1 ) => bwg.strikePosition;
    Math.random2( 0, 3 ) => bwg.preset;

    // set freq
    scale[Math.random2(0,scale.size()-1)] => int winner;
    57 + Math.random2(0,2)*12 + winner => Std.mtof => bwg.freq;

    // print some parameters
    <<< "---", "" >>>;
    <<< "preset:", bwg.preset() >>>;    
    <<< "bow rate:", bwg.bowRate() >>>;
    <<< "bow Pressure:", bwg.bowPressure() >>>;
    <<< "strike position:", bwg.strikePosition() >>>;
    <<< "frequency:", bwg.freq() >>>;
    <<< "---", "" >>>;

    <<< "bow -> pluck", "" >>>;
    Math.random2f( .5, 1 ) => bwg.pluck;
    // advance time
    2::second => now;

    <<< "pluck -> bow", "" >>>;
    .8 => bwg.startBowing;
    Math.random2f(2,4)::second => now;
    1.0 => bwg.stopBowing;
    1::second => now;
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants