Page 1 of 1

Fill series from unsafe memory buffers

Posted: Tue Mar 06, 2018 6:48 am
by tmp
Hi.

I have a setup where I get live data at >200kHz sampling rate with multiple channels. This data is processed (e.g. FFT) and then fed into LC. Since all calculations are done with the help of external libraries (e.g. Intel IPP), the data resides in unmanaged buffers. To get the data into a series object, I have to marshal the unmanaged memory to double[] and then create a PointLineSeries (or similar) per FFT spectrum. I guess, you turn that managed double[] back into unmanaged DirectX magic. My question is now if there is a way to fill a series directly from a vector in unmanaged memory (e.g. I give you a pointer and a length). This would really speed thing up and prohibit the excessive creation/destruction cycle of intermediate double[].

Regards, tmp

Re: Fill series from unsafe memory buffers

Posted: Tue Mar 06, 2018 3:14 pm
by ArctionKestutis
Hi,

No, there is no way to avoid intermediate conversion to type supported by corresponding Series field (Points or Data).
Probably you could acquire 'source' license of LightningChart and do such project specific optimization.

All the best.