PerstentSeriesRenderingIntensityLayer ZoomToFit

A forum dedicated to WPF version of LightningChart Ultimate.

Moderator: Arction_LasseP

Posts: 1
Joined: Tue Mar 20, 2018 4:53 pm

PerstentSeriesRenderingIntensityLayer ZoomToFit

Post by jhughes » Tue Mar 20, 2018 5:10 pm

I am working with the WPF examples and struggling to utilize ZoomToFit functionality for the charts with persistent data rendering layers.

I have experimented with adding the most recently rendered data to _chart.ViewXY.SampleDataSeries[0].SamplesDouble and then calling _chart.ViewXY.ZoomToFit().

In this scenario, the chart does zoom to make all data in the SampleDataSereies viewable.

However, I would like to ZoomToFit to the persistent data layer without any SampleDataSeries.

Any suggestions?

Posts: 383
Joined: Mon Mar 14, 2016 9:22 am

Re: PerstentSeriesRenderingIntensityLayer ZoomToFit

Post by ArctionKestutis » Wed Mar 21, 2018 9:16 am


It would be overstretch of scenario PersistentSeriesRenderLayer was design for. PersistentSeriesRenderLayer is kind of a bitmap, that allows adding rendering data incrementally in it. CPU load or memory footprint doesn’t rise, but you could not have zoom/pan interactivity as with normal Series. This is basically trade-off between those requirements. If you change the range and location of Axes you need to re-render Persistent Layer completely (or from point your trace still should be visible).
If you need zoom functionality, when you should add all your series to the SampleDataSeries' list. As with normal List, you could remove item(s) from there then is not needed.

All the best.