Comments (8)
Could you try with f473539? I did indeed introduce a wrong behavior in this commit...
from sfizz.
Yes this fixed the issue.
from sfizz.
What is the motivation here? The sample-rate is passed to the plugin when the plugin is instantiated and must not change. So you can pick it up directly from instantiate (...)
The parameter-option is only for the benefit of GUIs (and it is passed as atom_Float). Support for this was only added recently. Ardour 5.x did no support this option.
from sfizz.
I seem to recall that e.g. VST can change sample rates on the fly. At least such an option existed in Juce. I assumed this option was there to handle this possibility.
from sfizz.
Yes, VST has that option (but almost no VSTs implement this properly. Check e.g. frequency grid-lines in VSTs EQs when changing the rate).
It is also super rare that anyone would change rate of a project while running. That's not click-free, nor realtime-safe, and one cannot do this live anyway. Also many plugins allocate buffers depending on sample-rate, so LV2 opted to just take down and re-instantiate the plugin.
I'm not aware of any LV2 host that allows changing the sample-rate while running. jalv, Ardour, Qtractor don't (maybe Carla does?).
from sfizz.
I agree it seems overly optimistic to change the sample rate live, but as far as I could see there is really nothing preventing it in the way the "Options" extension is set. The API documentation mentions that the methods are in the "instantiation" threading class but that the options are there to enable changing some parameters of the plugin at runtime.
I don't remember exactly but the reason why I put this code path to change the sample rate was probably because I had an unmap
around that told me that the host sent a sample rate option, and figured I probably should handle it somehow :) If I can disregard it it's fine as I already initialize the default sample rate to the parameter passed to the instantiate(...)
function. Is it the same for the block size or can this actually change at runtime?
from sfizz.
The API documentation mentions that the methods are in the "instantiation" threading class but that the options are there to enable changing some parameters of the plugin at runtime.
Indeed. it's theoretically possible possible that way.
Is it the same for the block size or can this actually change at runtime?
Yes, it can change at runtime. A plugin must also support run(..,n_samples) for any non-negative number of n_samples. The block-size is only an upper bound.
e.g. Ardour splits the cycle when looping or when there's port-automation. So in a single process cycle of 1024 samples, the plugin may be called with run(567); /* parameter or position changes*/ run (457);
from sfizz.
Ahhh I see that's how this is implemented. It seemed weird to have only a single parameter value per block with automation curves. Thanks :D I aimed at doing it this way though so hopefully I succeeded...
My question however was more related to whether the max sample rate may change by calling set_options(...)
after instantiation?
from sfizz.
Related Issues (20)
- Reloading the SFZ file stops all audio HOT 1
- Tuning root key is ignored.
- The wrong number of frames is returned by the st_audiofile function
- Crash if a midi note is recieved while the SFZ file is reloaded HOT 19
- ⚠️ Feature requests | non-bug issues in Discussions ⚠️
- bug when off_by is involved and the two midi notes are played exactly at the same time HOT 4
- Transpose vs tune HOT 4
- RAM usage : Samples are continuously loaded in RAM while playing HOT 2
- Error building Arch AUR makepkg HOT 3
- Note-On performance issue
- Support `lotimer` / `hitimer` HOT 4
- Tests fails with the latest Abseil HOT 7
- Invalid output when the number of output is above 1 and using effects
- Compatibility with catch2 >= 3
- Issues when Note on/off at the maximum delay HOT 2
- Ardour freezes for a long time after stopping playback
- All voices are always active after sustain is released HOT 2
- overriding default_path for each sfz mapping HOT 2
- Segfault during use of `sfizz_render` HOT 2
- ampeg_delay make the note play indefinitely HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sfizz.