How to draw lines on 3D walls?

TeeChart VCL for Borland/CodeGear/Embarcadero RAD Studio, Delphi and C++ Builder.
Post Reply
Wiebe
Newbie
Newbie
Posts: 21
Joined: Wed May 11, 2005 4:00 am
Location: Middelburg
Contact:

How to draw lines on 3D walls?

Post by Wiebe » Thu Mar 30, 2006 8:01 pm

BCB6 and TeeChart Pro v7.05

How to draw e.g. a horizontal line on the bottom wall, at a position matching a certain zValue?

Thanks in advance,

Wiebe

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 Mar 31, 2006 8:36 am

Hi Wiebe,

You can custom draw on TChart's canvas using its OnAfterDraw event and do something like the following code:

Code: Select all

void __fastcall TForm1::Chart1AfterDraw(TObject *Sender)
{
	int index=Series1->ZValues->Locate(15);

	Chart1->Canvas->MoveTo3D(Chart1->Axes->Bottom->IStartPos, Chart1->Axes->Bottom->PosAxis, Series1->CalcZPos(index));
	Chart1->Canvas->LineTo3D(Chart1->Axes->Bottom->IEndPos, Chart1->Axes->Bottom->PosAxis, Series1->CalcZPos(index));
}
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

Wiebe
Newbie
Newbie
Posts: 21
Joined: Wed May 11, 2005 4:00 am
Location: Middelburg
Contact:

Post by Wiebe » Fri Mar 31, 2006 2:50 pm

Thanks Narcís,

Excellent.
However, "walldrawing" requires some imagination since properies like IEndPos and IStartPos are nowhere available nor explained in Help.
Or am I missing something?

Wiebe

Pep
Site Admin
Site Admin
Posts: 3303
Joined: Fri Nov 14, 2003 5:00 am
Contact:

Post by Pep » Mon Apr 03, 2006 11:21 am

Hi Wiebe,

yes, these properties has not been explained in the TeeChart Help files. We'll add them for the next releases.

In case you still having problems painting on the Chart please do not hesitate to let us know and we'll try to help you..

Post Reply