Hmm. This is interesting to me. I am able to replicate the clicks & pops when I test out on my setup. I’ve also got a powerful Windows 10 PC, and using 96K sample rate and ASIO that I always use.
For this test, I used OsciStudio 0.6.0.31, and Blender 2.83. I’m using the same oscistudio.py that @richddt mentioned.
A couple of things:
Once the animation is sent to OsciStudio (OS) from VAMP / Blender, Blender has no more role and can be disconnected from OS and closed. As you note, even a simple cube being animated in Blender (not using VAMP) will also cause the issue.
The problem here is clearly located in the way that OS interacts with the audio drivers.
It seems that the problem specifically occurs when OS switches between Blender animation frames. If you freeze the timeline animation in OsciStudio and just run an FX in OsciStudio (rotation, etc,) you will not hear the pops. Also, I did a test with no imported animation, nor VAMP. I just connected Blender to OsciStudio directly and manually rotated the simple cube in Blender. The pops and clicks occurred again.
To me, the sound reminds me of the pops you get if you play an audio sample that does not start/end at zero crossing. In those situations, there’s a sudden step from non-zero to zero, causing a click or pop.
Looking at the waveform from your sample, I do see discontinuities in the waveforms which I believe account for the noise. This is a close-up of your .wav sample, just one audio channel for clarity:
In the first section, the audio was nice and clean. The clicks started at the location I’ve marked, and you can see some zero crossing / discontinuities circled.
If OsciStudio doesn’t have any sort of audio transition between frames, I could see this being the case.
@kritzikratzi - does OsciStudio just jump cut immediately to the next frame when creating audio from imported Blender animations?
Would it be possible to have the audio fade between the previous and current animation frame, maybe over a couple of audio cycles?
Or alternately, when switching to a new animation frame, ramp the current audio down to zero, then ramp up the new sample from zero, again over a few samples in order to mitigate the pops?
@richddt - For your project, you could manually edit the .wav files for to make all of the frames into zero crossings, but that would be a major PITA given 1000 frames x however many animations you’re creating.
As an aside, in my recent projects I’ve been sending very complex (and thus noisy) images from Blender to Oscistudio, so I wouldn’t notice a couple of pops or clicks amid my noisy results.
One other thing I’ll mention is that I’ve been using OS for a couple of years, and I am pretty sure that when I first started using it, (with Blender 2.7x and Oscistudio 0.5x,) I did not have this problem.
I recall that when Blender came out with 2.8x, and @kritzikratzi was working on OS 0.6x, he did some refactoring of the interactions between Blender and OsciStudio, so I wonder if anything changed in the audio generation code at that time? I’ll try to re-run this test using old Blender and old OsciStudio and see if those clicks and pops are still there.