Let me coment on the track IDs since I implemented the track id as an int cast to the memory location of the track (ie the pointer). I was working on that in the development stage and in the beginning the ids were serial numbers that started with 1, 2, 3, ... Unfortunately, that was done at the time both in the DC and in the TPC, so I sometimes had different tracks with identical id's. I therefore had the idea at the time that they could not both be in the same memory location (not taking into account if a TPC track was deleted and another DC track created at the memory location), so I could guarantee that the IDs generated using the memory location cast to an int would be unique. I have lost track of how it is done in the TPCs these days, but if I was to do it over again, I would use the new root facility (I forget what it is called for the moment) which gives you a number which is guaranteed to be unique to generate the track ids. It is somehow based on the number of nanoseconds since the epoch and I guess the idea is that you cant ask for a number within a nano second to get the same one. I looked through the code and it is not obvious how it works, but they say it does. Anyway, a short history of track ids for your cultural enrichment. Kris Djamel Ouerdane wrote: > Hi Flemming et al, > > After having read your message, I realized that I misunderstood the way > the track IDs were set. I would have expected that they are set like for > the TPC tracks. Casting the pointer to an integer gives a relatively big > number that at first glance looks like an uninitialized variable. Sorry > for the confusion. I'm gonna correct it. > > Djam > > -- > Djamel Ouerdane ------------------------------------------o > | Niels Bohr Institute | Home: | > | Blegdamsvej 17, DK-2100 Ø | Jagtvej 141 2D, | > | Fax: +45 35 32 50 16 | DK-2200 Copenhagen N | > | Tel: +45 35 32 52 69 | +45 35 86 19 74 | > | http://www.nbi.dk/~ouerdane | > | ouerdane@nbi.dk | > o---------------------------------------------------------o
This archive was generated by hypermail 2b30 : Wed Apr 03 2002 - 09:58:43 EST