Pre loader

New user, slow load

Welcome to the SciChart Forums!

  • Please read our Question Asking Guidelines for how to format a good question
  • Some reputation is required to post answers. Get up-voted to avoid the spam filter!
  • We welcome community answers and upvotes. Every Q&A improves SciChart for everyone

WPF Forums | JavaScript Forums | Android Forums | iOS Forums

Answered
1
0

Hello,

I’m evaluating SciChart v6.1 for a WPF realtime charting application.
So far everything has worked well, except some issues with very slow loading.
On my machine, any app referencing SciChart takes around 5-6 seconds to initialize before the app can continue loading.

Some debugging with dotTrace shows most of the time is spent in the constructor of SciChartSurface calling the Charting2DNativeDllsLoader constructor.

dev machine is Windows 10 Pro x64, core i7, 32GB ram
Visual Studio 2019 Pro
To duplicate create new WPF application, .NET Framework v4.8
In MainWindow constructor add two lines:

SciChartSurface.SetRuntimeLicenseKey("[TRIAL KEY]");
var tmp = new SciChartSurface();

Executing the second line takes around 5-6 seconds.
I have uploaded a sample project that duplicates this issue and dotTrace result.
Let me know if I can provide any other info.

Version
6.1
Images
  • You must to post comments
Best Answer
0
0

Update: Please see this video below showing vastly improved startup times

SciChart WPF v6.2 will be up to 28x faster or 0.15 seconds to initialize the first chart on our test machines. See the video below.

This will be released shortly, or you can get it now from our nightly build feed.



Best regards,
Andrew

  • You must to post comments
0
0

Thanks for the quick reply Andrew. That function does the trick.

  • You must to post comments
0
0

Hi Steven

Thank you for your question, it’s great that you’ve asked it as people who search for this same problem will find the solution, so thanks!

We’ve literally just released an update in SciChart WPF v6.1 which addresses the slow initial one-time loading of SciChartSurface. This can be found here:

SciChart WPF v6.1.0.13075 Released! Preloading SciChart native
libraries and async load licensing before a SciChartSurface is shown

Some customers have reported slow initial startup time with SciChart
and asked for a way to do this initialization earlier in the
application, e.g. when a splash-screen is shown.

We’ve published a sample on Github showing how to do async library
loading with SciChart WPF v6.1 using two two static methods.

  • SciChart2DInitializer.LoadLibrariesAndLicenseAsync
  • SciChart2D3DInitializer.LoadLibrariesAndLicenseAsync

If you download the sample on our Github repository you can check out how to asynchronously load the licensing & native libraries in SciChart. We suggest doing this once in a splash screen or during initial startup of your application.

Let me know if this helps. Initial load time should reduce significantly with this method. There will still be a one-time hit as XAML/BAML is loaded but for subsequent charts, the startup time should be instant.

Best regards,
Andrew

  • Martin Mohr
    Hi Andrew, transfering the very long load time to the start of the application is a nice workaround. But will the load times be reduced to a much lower time in future releases? V5 was much faster! Regards Martin
  • Andrew Burnett-Thompson
    Hi Martin! Yes, version 6.2 (which is in QA testing before release now) has an improvement to startup time making it **28 times faster to load the first chart**. In addition with async loading this should make scichart app startup times imperceptible. We aim to release it this week.
  • You must to post comments
Showing 3 results
Your Answer

Please first to submit.

Try SciChart Today

Start a trial and discover why we are the choice
of demanding developers worldwide

Start TrialCase Studies