Re: Compare TGeoShape

From: Andrei Gheata <Andrei.Gheata_at_cern.ch>
Date: Thu, 15 Jul 2010 10:30:09 +0200


Hi Jason,

This comparison is not implemented and not in the plan. The reason is that there are ~20 different shapes and this makes the implementation effort too big and not scaling with the limited use cases. Besides, this cannot be implemented for Boolean composite shapes that can be of infinite variety.

Best,
Andrei

On 07/14/2010 11:03 PM, Jason Webb wrote:
> Hi ROOTers,
>
> Is there a simple way to compare two TGeoShapes to each other?
> Specifically I am interested in functionality like
>
> TGeoShape *shape1 = ...
> TGeoShape *shape2 = ...
>
> if ( shape1->IsEqualTo(shape2) )
> {
> std::cout << "same"<<std::endl;
> }
>
> where shape1 and shape2 are any of the TGeo shapes, and the 'IsEqualTo'
> function would return true if they are of the same class and have the
> same parameters.
>
> Thanks,
> Jason
>
Received on Thu Jul 15 2010 - 10:30:13 CEST

This archive was generated by hypermail 2.2.0 : Thu Jul 15 2010 - 17:50:01 CEST