Using ReferenceCanvas

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
Phil
Newbie
Newbie
Posts: 1
Joined: Fri Mar 12, 2004 5:00 am
Location: France

Using ReferenceCanvas

Post by Phil » Sat Apr 30, 2011 9:41 am

Hi,

I have been using TChart for years and have develloped a full GIS program that uses TChart as the basic drawing environment but the actual GIS data is contained in a huge database which uses the Axis and Canvas of a TChart to determine the drawing limits.

The entire mechanism is encapsulated in a TDrawingSeries which is descended from TSeries. Effectively, it is a GIS CAD program contained in a TSeries but still alows me to use other Tchart series on the same Chart.

Everything works fine but as the database increases in size, the drawing time increases proportionately and to make it worse, I have now have introduced dynamic objects which are tracked in real time. It is getting to be quite slow (although I can still drag a vector shoreline of the world containing millions of polylines around the screen in real time).

What I am experimenting with is using a background thread for my part of the drawing process which is interuptable, drawn in stages and rendered on demand or completion (if that makes any sense)

Essentially, What I want to do is

Grab The TChart Reference canvas (includes the axes et al)
Overlay my transparent bitmap containg the GIS CAD data (Exactly the same dimensions as the TChart)
Put it back on the Chart ... Without generating any redraw, i.e. Just Get, Ammend and Put.

I use Delphi2007, TChart7.12

not interested in .Net .... at All

Thanks

Narcís
Site Admin
Site Admin
Posts: 14730
Joined: Mon Jun 09, 2003 4:00 am
Location: Banyoles, Catalonia
Contact:

Re: Using ReferenceCanvas

Post by Narcís » Mon May 02, 2011 7:50 am

Hi Phil,

You could try using asynchronous rendering as explained in the Real-time Charting article at http://www.teechart.net/reference/articles/index.php. It basically consists on setting AutoRepaint property to false and enable it when you want the chart to be refreshed.
Best Regards,
Narcís Calvet / Development & Support
Steema Software
Avinguda Montilivi 33, 17003 Girona, Catalonia
Tel: 34 972 218 797
http://www.steema.com
Image Image Image Image Image Image
Instructions - How to post in this forum

Post Reply