strange inputs** modifications in standalone
So my plugin records incoming audio into its buffers. It has a "refill" button on the GUI that does exactly that.
When any plugin wrapper is used, everything works fine.
But in windows standalone I've noticed some interesting things. All GUI control clicks are processed on the last sample of a frame. I click "refill", buffer refilling is called. To record only relevant samples I keep track for the event offset. So in this frame I can record only one last sample.
The buffer also keeps a copy of ins** (due to some intrinsic routing, but in standalone version it is equal to the original ins**).
It appears that in the last sample of a frame ins[0] and ins[1] contain wrong addresses instead of the ones they had during the whole frame. I read from the wrong address and the plugin crashes.
If I however copy original input poiners per channel to double* ins[2], i.e. direct pointers to the L and R sample arrays, everything works fine.
From looking at RtAudio source code I can't tell right away if it is a problem there or on my side. Had anyone had such problems?
Last edited by 1eqinfinity; 12-22-2017 at 12:04 PM.
|