Forum Stats

  • 3,876,051 Users
  • 2,267,037 Discussions


Any way to pre-render charts with many datapoints?

3239506 Member Posts: 1
edited May 16, 2016 12:58PM in JavaFX 2.0 and Later

Most googling results in the "OffScreenOffThreadCharts" example, but I dont think this answers my question. That performs a specific function (i.e., taking snapshots and exporting them) offscreen, whereas I need to be able to render a graph off screen and then utilize it.

I'm looking to render a chart with around 10000+ points. I've done all the loading of the ObservableLists that the chart is based off and adding them to series on separate threads, but when the chart is actually being DRAWN TO THE SCREEN the entire application seems to freeze, no matter what level of multi-threading I do. I assume this is because it is having trouble drawing this many points to the screen.

It hangs for about 3 seconds. This hang would be acceptable, if all the UI elements on the screen did not also freeze, and the entire application to hang.

I see two possible routes forward:

1) Is there any way to render this chart "in the background", and then display it once it is complete?

2) If not, is there any way to have the various UI elements continue to function while the rendering is happening?

Thank you,

This discussion has been closed.