Page 1 of 1

Direct2D Canvas crash:

Posted: Wed Jan 11, 2012 1:43 pm
by 16061207
Problem Statement :
Tee Chart crashes “if we move the ColorLine or DrawLine tool added to the tChart”

Environment :

We are using Windows 7 machine with SlimDx installed and TeeChart version 4.1.2011.10193.

We are using TeeChart.Direct2D.dll .

Details:
We are using Direct2D Canvas (Graphics3DDirect2D D2D) for fastline series plotting. As soon as Colorline and Drawline tool is added / moved to the tChart. Tchart crashes.

Following is the exception details:

Exception:- D2DERR_WRONG_STATE: The object was not in the correct state to process the method. (-2003238911)

Stack Trace:

at SlimDX.Result.Throw[T](Object dataKey, Object dataValue)

at SlimDX.Result.Record[T](Int32 hr, Boolean failed, Object dataKey, Object dataValue)

at SlimDX.Direct2D.RenderTarget.EndDraw()

at Steema.TeeChart.Drawing.Direct2D.Graphics3DDirect2D.ShowImage(Graphics g)

at Steema.TeeChart.TChart.Draw(Graphics g)

at Steema.TeeChart.TChart.OnPaint(PaintEventArgs pe)

at System.Windows.Forms.Control.PaintWithErrorHandling(PaintEventArgs e, Int16 layer)

at System.Windows.Forms.Control.WmPaint(Message& m)

at System.Windows.Forms.Control.WndProc(Message& m)

at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)

at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)

at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)

We are using Direct2D demo application and we just added a drawline tool to the tchart. As soon as we are trying to drag the drawline tchart crashes with above exception.

Please let us know whether it’s a known bug or not ??? And what is the solution to fix this bug.

Re: Direct2D Canvas crash:

Posted: Thu Jan 12, 2012 3:09 pm
by 10050769
Hello crb,

I can reproduce your problem and I have added your request in bug list report with number[TF02016003]. We will try to fix it for next maintenance releases of TeeChart.Net.

Thanks,

Re: Direct2D Canvas crash:

Posted: Mon Feb 13, 2012 11:47 am
by 10050769
Hello crb,

I inform you that the bug of number [TF02016003] will not be resolved, because this issue is a problem in Direct2D. To avoid the problem I recommend use colorline drag, please set DragRepaint to true as do in next lines of code:

Code: Select all

ColorLine tool = new ColorLine(tChart1.Chart);
tool.Axis = tChart1.Axes.Bottom;
tool.AllowDrag = true;
tool.Value = 3;
tool.DragRepaint = true; 
Thanks,