DrawToBitmap Issue in latest service release

TeeChart for Microsoft Visual Studio .NET, Xamarin Studio (Android, iOS & Forms) & Monodevelop.
Post Reply
Aaron Peronto
Newbie
Newbie
Posts: 38
Joined: Thu Feb 01, 2007 12:00 am

DrawToBitmap Issue in latest service release

Post by Aaron Peronto » Mon Dec 03, 2007 5:59 pm

Have there been any problems reported with the DrawToBitmap method in the latest (8 Nov 2007) service release for v3 in Visual Studio 2005?

Here is what I am seeing.

We had been running using v2 still and now have a release version of our app out and want to work on upgrading to v3 now that have time to test such a major change for us. We implemented our own double-buffering of sorts in our app so that we use DrawToBitmap to render the chart and then place the resulting image into a PictureBox control on our form. The TeeChart control remains hidden the entire time.

When I un-installed v2 and installed the Nov 8 release of v3, our images drawn using DrawToBitmap now display nothing at all. I wrote a small test app that I can upload for you that will show you what I am doing.

I uninstalled the latest v3 release and installed the v3 from July 27 (version 3.2.2763.26082 is what is shows for the number installed now) and the problem goes away. The bitmap that results from my DrawToBitmap call shows the graph exactly as I expected it to (and exactly how it used to show using v2).

Please let me know if this is a known issue or if you need me to upload my test application.

Thanks.
Aaron

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

Post by Narcís » Tue Dec 04, 2007 2:06 pm

Hi Aaron,

Yes, there's a known issue when exporting TeeChart into an image in the latest maintenance release. This has been fixed and we expect to deliver a new maintenance release before the end of this week.

If you want us to test your example application with our current sources we will be glad to do so.
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

Aaron Peronto
Newbie
Newbie
Posts: 38
Joined: Thu Feb 01, 2007 12:00 am

Post by Aaron Peronto » Tue Dec 04, 2007 2:20 pm

No need to test with my simple little test app.
It is good enough to know that you guys are aware of the issue and plan to have it fixed in the near future.

Thanks, as always, for the quick response.

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

Post by Narcís » Tue Dec 04, 2007 2:29 pm

Hi Aaron,

You're very welcome!

Then you may be interested in being aware at this forum or subscribe to our RSS feed for the next release announcement.
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

Aaron Peronto
Newbie
Newbie
Posts: 38
Joined: Thu Feb 01, 2007 12:00 am

Post by Aaron Peronto » Wed Dec 05, 2007 6:14 pm

Narcis,
I have some questions and concerns about some performance changes I have seen from .NET v2 to three different v3.2 versions (July, November and now the new Decemeber release).

Is there an email address/Private Message address that I can use to communicate some things I have seen related to performance?
I noticed that PMs have been disabled on these boards or I would have sent this info and the questions to you through a PM.

Thanks.
Aaron

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

Post by Narcís » Fri Dec 07, 2007 8:33 am

Hi Aaron,

As far as I can see you are a Pro-Support subscriber. You can use the Pro-Support e-mail address or send your inquires to info at steema dot com.

Thanks in advance.
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

Aaron Peronto
Newbie
Newbie
Posts: 38
Joined: Thu Feb 01, 2007 12:00 am

Post by Aaron Peronto » Thu Dec 13, 2007 6:42 pm

Using the new (December 5th Service Release) version of TeeChart .NET v3.2 I still am unable to get the DrawToBitmap method to work as it used to work.
Was that DrawToBitmap fix supposed to be in this service or release or will it appear in an upcoming fix set?

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

Post by Narcís » Fri Dec 14, 2007 12:40 pm

Hi Aaron,

It is related to the manual double-buffering, that's why setting UseBuffer to false works ok, for example:

Code: Select all

			tChart1.Graphics3D.UseBuffer = false;
			tChart1.Invalidate();
			Rectangle rect = new Rectangle(0, 0, tChart1.Width, tChart1.Height);
			Bitmap bmp = new Bitmap(rect.Width, rect.Height);

			tChart1.DrawToBitmap(bmp, rect);
			//bmp.Save(@"C:\temp\chart.bmp");
			pictureBox1.Image = bmp;
Other options:

Code: Select all

			Rectangle rect = new Rectangle(0, 0, tChart1.Width, tChart1.Height);
			Bitmap bmp = new Bitmap(rect.Width, rect.Height);
			Graphics g = Graphics.FromImage(bmp);
			tChart1.Graphics3D.BackBuffer.Render(g);
			//bmp.Save(@"C:\temp\chart1.bmp");
			pictureBox1.Image = bmp;
or:

Code: Select all

			Bitmap bmp = tChart1.Bitmap;
			pictureBox1.Image = bmp;
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