Hi,
I have issue with export SciChart to Bitamp. I have to generate pdf report from data. Report contains two charts.
It is possible to render chart in memory and export to bitmap? I know it is possible in WPF but I couldn’t achive this in Android.
Now my solution is that I render this charts on fragments and wait 1s on each to render and then save chart. But this solution is not good. For slower devices chart is not exported correctly.
For example on one device have strange grid (only exported bitmap, fragment with this chart looks good):
- Marcin K asked 6 years ago
- You must login to post comments
Hi Marcin,
Yes, it’s possible to render chart in memory. We have an example in our demo application which we use internally for testing of chart export. You can use it as reference for implementing chart export in memory for your application:
public void exportChartInMemory() {
final SciChartSurface sciChartSurface = new SciChartSurface(getActivity());
setRenderSurface(sciChartSurface, renderSurface);
sciChartSurface.setTheme(themeId);
initSurface(sciChartSurface);
SciChartSurfaceExportUtil.prepareSurfaceForExport(sciChartSurface, 800, 600);
imageView.setImageBitmap(sciChartSurface.exportToBitmap());
}
Hope that this will help you!
Best regards,
Yura
- Yura Khariton answered 6 years ago
-
It’s works. Thank You
- You must login to post comments
Please login first to submit.