Git Product home page Git Product logo

Comments (2)

hmoffatt avatar hmoffatt commented on July 18, 2024 1

The sound fonts don't have any information about attack / steady / decay, if you had that information you could certainly use it and get both infinite sustain AND smaller sound fonts, which would be great.

sf2 sound font has the attack / steady / decay information, but the sound font builder script included with MIDI.js doesn't actually understand sf2 files. It just renders an sf2 sound font to the js format by using the Fluidsynth synthesiser to play each note for 3 seconds.

from midi.js.

congfeng22 avatar congfeng22 commented on July 18, 2024

If a midi note shall last longer than the duration of the soundfont sample the sound will stop when the end of the sample is reached.
Adding "source.loop=true;" after the audio buffer has been created in "player.js" is a cheap work around.

Alas, if the sample contains an attack, the loop restart will be noticeable.

Is there a way to split buffers generally into attack / steady sound / decay ?

Hi, could you elaborate on where to insert source.loop=true; in player.js? I'm having the same problem and need a quick fix. Thanks!

from midi.js.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.