filling TBranch

From: Stanislav Terechtchenko (Stanislav.Terechtchenko@cern.ch)
Date: Mon Jul 27 1998 - 15:39:54 MEST


	Dear Rooters.
 Simple question. I have a global data buffer which is filled by some
external function. How can I fill the TBranch with this data. I don't
like to create local copy  of this data wrapped by some class to avoid
copy overhead.

Something like this:

Int_t data[100];
TFile *f = new TFile("f.root","RECREATE");
TTree *tr = new TTree("tr","Tree");
tr->Branch("data",data,"some leaf list - i dont know the form",1024);

//loop
 fillDataArray(data);
 tr->Fill();
//end loop

	Thanks.
		Stas.



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:34:35 MET