Pre loader

NullReferenceException when using Direct3D

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

0
0

We are getting a NullReferenceException at OnRenderSurfaceBaseLoaded(Object sender, RoutedEventArgs e) in Direct3D10RenderSurface.

On calling:

if (Direct3D10CompatibilityHelper.SupportsDirectX10)
        {
            // quickest one and optically on par with high quality or xaml rendering
            return new Direct3D10RenderSurface();
        }

System:
Windows 8: Version 6.2.9200.0
CLR version: 4.0.30319.42000

see Stacktrace:


Stack trace

System.NullReferenceException: Object reference not set to an instance of an object.
----------------------------------------------------------------------
at SciChart.Drawing.DirectX.Context.D3D10.Direct3D10RenderSurface.OnRenderSurfaceBaseLoaded(Object sender, RoutedEventArgs e): 
----------------------------------------------------------------------
at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised): 
----------------------------------------------------------------------
at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args): 
----------------------------------------------------------------------
at System.Windows.BroadcastEventHelper.BroadcastEvent(DependencyObject root, RoutedEvent routedEvent): 
----------------------------------------------------------------------
at System.Windows.BroadcastEventHelper.BroadcastLoadedEvent(Object root): 
----------------------------------------------------------------------
at MS.Internal.LoadedOrUnloadedOperation.DoWork(): 
----------------------------------------------------------------------
at System.Windows.Media.MediaContext.FireLoadedPendingCallbacks(): 
----------------------------------------------------------------------
at System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks(): 
----------------------------------------------------------------------
at System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget): 
----------------------------------------------------------------------
at System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget): 
----------------------------------------------------------------------
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs): 
----------------------------------------------------------------------
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler): 

Any help?

Version
SciChart 4.2.5.10565, SharpDX 2.6.3
  • Noah Son
    Joerg, I am seeing the same exception and charts stops updating. It occurs whenever connecting to windows remote desktop. This happens also on SciChart v5.1.0.11299. Were you able to get around this issue? I posted my question on stackoverflow. https://stackoverflow.com/questions/50336826/onrendersurfacebaseloaded-null-exception-when-connecting-using-windows-remote-de
  • Joerg Hoehn
    No, we stopped using the DirectX10 support for that part of code.
  • Andrew Burnett-Thompson
    If either of you guys send us code to reproduce, we will look into it! Problem is people report bugs, don’t provide steps to repro, and they get lost in the sea of support requests we get. @Noah under normal circumstances you should not need to dispose the SciChartsurface. I’ve commented to that effect on your SO post. @Joerg under normal circumstances you should not need to check for DirectX compatibility, the DirectXHelper.TryApplyDirectXRenderer=True attached property does it for you.
  • You must to post comments
0
0

Hi Joerg,

We had an issue like this reported recently, and it seems to be resolved in v5.0.0 and up. Can you try it?

Best regards,
Andrew

  • You must to post comments
0
0

Hi Andrew,

We cannot try version 5.0.0 Our license expired in October this year, because the software went into maintenance phase. We had a scichart license since 2012 and updated to latest possible version 4.5.2.10565. But we had the source code license, so we would be able to fix the problem in source code if possible.

Is it possible that we fix that in our source code? Can you give me some info about the needed source changes or better a git patch ??

Thanks,
Joerg

  • You must to post comments
Showing 2 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