Assignmetn operator '=' of TH2Poly

Hi,
I am trying to create a TH2Poly inherited class TCamera, that represents a Camera which has either square or hexagonal pixels. This class will be used as Histogram representing Camera (Thus requiring all the Fill() and etc functions) ,many other calculations related to it, and also for graphical representations. For this purpose I require assignment operator ‘=’ of TH2Poly, to create assignment operator ‘=’ for TCamera class. Present version of TH2Poly ‘=’ doesn’t seem to be working. Is there some other way ??

[quote=“Chinmay”]Hi,
I am trying to create a TH2Poly inherited class TCamera, that represents a Camera which has either square or hexagonal pixels. This class will be used as Histogram representing Camera (Thus requiring all the Fill() and etc functions) ,many other calculations related to it, and also for graphical representations. For this purpose I require assignment operator ‘=’ of TH2Poly, to create assignment operator ‘=’ for TCamera class. Present version of TH2Poly ‘=’ doesn’t seem to be working. Is there some other way ??[/quote]

TH2 (the base class for TH2Poly) has a private operator =, TH2Poly does not have explicitly defined operator =, thus assignment of TH2Polys is suppressed/prohibited. So if you want to have TCamera::operator =, you have to do all the work yourself, if it’s possible at all.