blackhornet's Recent Forum Activity

  • Figured it out. You apply a Gain effect with a gain of zero, so there is no immediate effect, and then call Set effect parameter when you want to fade, set to Filter/delay/gain gain with your final dB (negative to fade down), and the time period to fade over.

    Sample here: GainTester.CAPX

  • I just posted a ForEach example on another thread. Should be sufficient for this thread too.

    FunctionForEach.capx

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • You should post the CAPX, so people can see what is going on, and this is in the wrong forum. Should move to -> How do I...?

  • We'd need to see more of the code. Here's a sample of running various combinations of functions and ForEach. All work as expected.

    FunctionForEach.capx

    Perhaps post the CAPX, or issolate the issue in a smaller example.

  • Ashley, you are probably the only one who can answer this. Thanks.

  • That's old school. WebAudio can do this itself.

  • I know the new WebAudio support is capable of this, but I can't seem to figure out how to implement it. I want to be able to specify a ramp-down on the gain over a period of time. I actually have the low level calls, from the MIDI.js code, but I can't figure out how to get the C2 implementation to do the same thing.

    From MIDI.js

        source.gain.linearRampToValueAtTime(1, delay);

        source.gain.linearRampToValueAtTime(0, delay + 0.2);

  • When I tried the MIDI.js samples, there was only one that wouldn't crash on my iPod Touch. I immediately thought of how Ashley had already dealt with the issue of supporting sound across all platforms. For that reason, I decided to hook the backend of the MIDI.js implementation to the C2 Audio plugin. So, the sounds are standard C2 sounds, played via the MIDI player engine - one for each note. This is going to be the challenge of supporting MIDI. Unless I'm mistaken, there will be no guaranteed General MIDI sounds available across all platforms, so you are going to have to provide your own 'soundfonts'.

    I had seen the synthesizer post. I'll keep it in mind but there's plenty for me still to do on this plugin.

  • Update 2014-09-26:

    Plugin updated to 1.1 - looping was throwing an exception, and "Stop" didn't!

    Update 2014-05-16:

    Piano Sample r168 (no ChromeConsole plugin needed)

    Update 2013-05-21:

    I'm releasing the MIDI plugin. There's still lots to do & cleanup, but here's the first version.

    BHT_MIDI - 1.1

    Piano Sample

    Manual

    I'd like this to be more complete, but it's just dragging out. I will be filling in the manual throughout the week, and there may need to be a tutorial as well.

    Original post:

    I've got a long way to go, but I've started on a MIDI plugin.

    MIDI Sampler

    This is a whole lot of hack-work. This thread caught my eye: Web Audio API and MIDI, so it's based on this.

    So far, this is a hack of the MIDI.js code, the C2 Audio plugin, and Pode's DragnDropZone plugin.

    You need to press the Preload button first to get the sounds local to your computer, but from there you can try the three sample songs, press the piano keys, or drag a .MID file onto the gray drag-n-drop zone.

    There's some handy test files here: use the download link

    (Hmm, link works in IE but not Chrome: http://www.personalcopy.com/midi.htm)

  • Text commands are in the manual here:

    Manual

  • If you could isolate the bad behaviour into a separate CAPX, then anyone could investigate the base issue.

  • If you go to the Manual page, at the top are four tabs. The second one is SDK.

    Broken links can be reported on the Website issues forum.

    There's a Plugins forum with dozens of third-party plugins you can download, and look at their code.

blackhornet's avatar

blackhornet

Early Adopter

Member since 28 May, 2012

Twitter
blackhornet has 26 followers

Connect with blackhornet