You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a fairly complex chart scheme that includes interactive mouse support. One feature is a mouse follower icon that follows XY series data as a separate XY series composed of a single data point. The pseudocode to update this single data point series is:
Being a single point, the update is, in principle, extremely lightweight. However, the entire chart is repainted which can be very significant work if a lot of data is displayed in the other series. This repaint time is very noticeable in something interactive like mouse feedback.
For comparison, this maintains good mouse interaction regardless of the background data size.
Is there a change in approach I can use to improve my performance with the existing XChart library? Is there some way to repaint specific series? I believe the answer is no, but I may be missing something.
If not, maybe we can enhance XCharts with some sort of layering system in its rendering logic. I’m essentially trying to update a layer that’s on top of a static backing image.
The text was updated successfully, but these errors were encountered:
I am far from a Swing expert but it's likely that using a JLayeredPane could accomplish independently rendered layers that visually combine for the completed chart.
I think JPanel's (maybe some sort of modified XChartPanel) could be stacked in the JLayeredPane with the non-base layers having there background opacity turn off (transparent).
Obviously, trying something like this would be a large and invasive undertaking.
I have a fairly complex chart scheme that includes interactive mouse support. One feature is a mouse follower icon that follows XY series data as a separate XY series composed of a single data point. The pseudocode to update this single data point series is:
Being a single point, the update is, in principle, extremely lightweight. However, the entire chart is repainted which can be very significant work if a lot of data is displayed in the other series. This repaint time is very noticeable in something interactive like mouse feedback.
For comparison, this maintains good mouse interaction regardless of the background data size.
Is there a change in approach I can use to improve my performance with the existing XChart library? Is there some way to repaint specific series? I believe the answer is no, but I may be missing something.
If not, maybe we can enhance XCharts with some sort of layering system in its rendering logic. I’m essentially trying to update a layer that’s on top of a static backing image.
The text was updated successfully, but these errors were encountered: