Blank Charts - Handling

A forum dedicated to WPF version of LightningChart Ultimate.

Moderator: Queue Moderators

Post Reply
User avatar
blakeadkins
Posts: 44
Joined: Tue Feb 25, 2014 7:49 pm

Blank Charts - Handling

Post by blakeadkins » Mon Aug 31, 2015 4:14 pm

Is there a way to determine if a chart is blank and not rendering (error from chart, property on LightningChart object, etc)?

We've had some customers that have released versions where the charts show up blank. We've fixed the issues by upgrading drivers or disabling certain drivers, but I'm wondering if there's a way programatically or event driven to prompt user to check those things without having the charts show up blank and receiving a support request from a customer.

Thanks!

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: Blank Charts - Handling

Post by ArctionPasi » Mon Aug 31, 2015 7:54 pm

From the chart itself... not.


But there's a way to detect if graphics hardware is available in WPF:

Code: Select all

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Media;

namespace ClassLibrary1
{
    public class Class1
    {

        public static bool IsHardwareAvailable()
        {
            int iTier = RenderCapability.Tier >> 16;
            if (iTier < 2)
                return false;
            return true; 
        }
    }
}
Usage:

Code: Select all

private void Button_Click(object sender, RoutedEventArgs e)
        {
            if (ClassLibrary1.Class1.IsHardwareAvailable())
                MessageBox.Show("HW available"); 
            else
                MessageBox.Show("HW not available"); 
        }
Please let us know how it works for you, so we could possibly include that as public static method of LightningChartUltimate class.
LightningChart Support Team, PT

User avatar
blakeadkins
Posts: 44
Joined: Tue Feb 25, 2014 7:49 pm

Re: Blank Charts - Handling

Post by blakeadkins » Mon Aug 31, 2015 8:07 pm

I'll give that a try.

We also had a system where we had charts show up blank and then we installed your Demo program and all of the charts in that program showed up blank. And in the Demo Application, the Active GPU was showing up blank for all charts as well. Doesn't the 'auto' switch to software rendering if HW rendering isn't possible?

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: Blank Charts - Handling

Post by ArctionPasi » Tue Sep 01, 2015 4:50 am

It should go to software rendering mode, true.

The hardware rendering may have been prevented in the system level, see this: http://www.arction.com/forum/viewtopic. ... =222&p=786

Or LanDesk mirror driver has been installed: http://www.arction.com/forum/viewtopic.php?f=16&t=533
LightningChart Support Team, PT

User avatar
blakeadkins
Posts: 44
Joined: Tue Feb 25, 2014 7:49 pm

Re: Blank Charts - Handling

Post by blakeadkins » Tue Sep 01, 2015 12:27 pm

I checked the registry and didn't find either of those registry tags in there. Are there any other places they might be?

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: Blank Charts - Handling

Post by ArctionPasi » Mon Sep 07, 2015 12:53 pm

Can you please check that you have delivered Arction.DirectXFiles.dll with your application? If the system is not up to date, it will extract correct DirectX native dlls into Windows temp folder and use them from there.
LightningChart Support Team, PT

User avatar
blakeadkins
Posts: 44
Joined: Tue Feb 25, 2014 7:49 pm

Re: Blank Charts - Handling

Post by blakeadkins » Tue Sep 08, 2015 1:21 pm

We checked our files and also made sure AntiVirus wasn't removing anything. But even after we installed Lightning Chart demo program, the demo program wasn't showing charts either.

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: Blank Charts - Handling

Post by ArctionPasi » Tue Sep 08, 2015 1:41 pm

According to our archives, one reason for the chart being blank is that there's currupted native DirectX dlls in the system. Chart finds them and uses them, instead of good dlls inside Arction.DirectXFiles.dll.

Please check c:\Windows\System32\d3dx9_43.dll date. What is it? Correct date is May 2010.

Rename that files as d3dx9_43.bak. Run LC application. The chart should then use d3dx9_43.dll from Arction.DirectXFiles.dll.

Does chart.ChartError event handler report any problem, by the way?
LightningChart Support Team, PT

User avatar
blakeadkins
Posts: 44
Joined: Tue Feb 25, 2014 7:49 pm

Re: Blank Charts - Handling

Post by blakeadkins » Tue Sep 08, 2015 3:58 pm

I'll have my guy check the dll date; but when running the Demo program, no matter what "chart" we clicked on it always showed up blank and the Active GPU was blank. We weren't getting any errors.

User avatar
blakeadkins
Posts: 44
Joined: Tue Feb 25, 2014 7:49 pm

Re: Blank Charts - Handling

Post by blakeadkins » Tue Sep 08, 2015 7:33 pm

I also setup a Windows 7 virtual Machine without a hardware driver. When I run the WPF Demo program, the charts do show up blank. There is no hardware device, but I thought it would fall back to software rendering. I also took a screenshot of the GPU info. I'm going to try adding a hardware device to the VM and see if anything changes.
Attachments
blankGpuInfo.PNG
blankGpuInfo.PNG (9.04 KiB) Viewed 30903 times
demoProgramBlank.PNG
demoProgramBlank.PNG (39.59 KiB) Viewed 30903 times

User avatar
blakeadkins
Posts: 44
Joined: Tue Feb 25, 2014 7:49 pm

Re: Blank Charts - Handling

Post by blakeadkins » Wed Sep 09, 2015 6:44 pm

More information...

I ran the WPF Demo App again today on my Virtual Machine and I used Snoop (https://snoopwpf.codeplex.com/) to dive into the LightningChartProperties. The ChartRenderOptions.DeviceType was set for Auto. In snoop, I changed the property to 'Software Only' and then the chart rendered fine.

Did some logic change in the 'Auto' setting? I thought by default it would try hardware rendering and then if that didn't work it would switch to Software.
Attachments
screenshotwithSnoopSmaller.png
screenshotwithSnoopSmaller.png (127.13 KiB) Viewed 30887 times

User avatar
ArctionPasi
Posts: 1367
Joined: Tue Mar 26, 2013 10:57 pm
Location: Finland
Contact:

Re: Blank Charts - Handling

Post by ArctionPasi » Thu Sep 10, 2015 7:02 am

Hi,

I sent you a test app by e-mail yesterday, using 6.5.3 assemblies. Autodetect works fine according to our tests in oracle VirtualBox VMs and laptop without GPU drivers installed. It goes internally to reference rasterizer state and renders (slowly as expected).

6.4 version had a problem in autodetect. It was fixed in versions 6.4.4 onwards. The snoop pic shows you are using 6.4 version.

Please update your app and demo app to use 6.5.3 assemblies and let us know if the problem still persists.
LightningChart Support Team, PT

Post Reply