Re: TPolyLine3D

Michael Katz-Hyman (michaelk@jlab.org)
Fri, 23 Jul 1999 11:00:07 -0400 (EDT)


Thanks alot, now I see...

Mike

On Fri, 23 Jul 1999, Mathieu de Naurois wrote:

> Michael Katz-Hyman wrote:
> >
> > Yes but TPolyLine3d isn't a TShape so you can't add it to a TNode, right
> > or wrong?
> >
> > I have also tried to execute the snippit of code inside of a event display
> > where the geometry is defined. This also was unsuccessful.
> >
> > Mike
>
> You're right. Just try something like this:
> (I create a dummy TBRICK to set up the range)
>
>
> new TCanvas("c");
> TGeometry *g=new TGeometry("GeoDet","Detecteur");
> TBRIK *Brick=new TBRIK("Brik","","",10,10,10);
> TNode * Node =new TNode("Node","",Brick,0,0,0);
>
> g->Draw();
>
> float x[3]={1,6,2};
> float y[3]={4,6,7};
> float z[3]={9,7,4};
>
> TPolyLine3D *p=new TPolyLine3D(3,x,y,z);
> p->Draw("SAME");
>
> I works...
>
> Mathieu
>