76 :
TEllipse(x1,y1,radin,radout,phimin,phimax,0)
128 if (r > r2)
return dist;
129 if (r < r1)
return dist;
132 if (y<0) phi = 360-phi;
135 if (phi1<0) phi1=phi1+360;
136 if (phi2<0) phi2=phi2+360;
138 if (phi < phi1 && phi > phi2)
return dist;
140 if (phi < phi1)
return dist;
141 if (phi > phi2)
return dist;
160 TCrown *newcrown =
new TCrown(x1, y1, radin, radout, phimin, phimax);
196 for (i=0;i<=np;i++) {
200 x[i] =
fX1 + dx*ct - dy*st;
201 y[i] =
fY1 + dx*st + dy*ct;
204 for (i=0;i<=np;i++) {
208 x[2*np-i+1] =
fX1 + dx*ct - dy*st;
209 y[2*np-i+1] =
fY1 + dx*st + dy*ct;
216 gPad->PaintFillArea(2*np+2,x,y);
220 gPad->PaintPolyLine(np+1,x,y);
221 gPad->PaintPolyLine(np+1,&x[np+1],&y[np+1]);
242 out<<
"crown = new TCrown("<<
fX1<<
","<<
fY1<<
","<<
fR1<<
","<<
fR2 248 if (
GetNoEdges()) out<<
" crown->SetNoEdges();"<<std::endl;
250 out<<
" crown->Draw();"<<std::endl;
virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py)
Execute action corresponding to one event.
double dist(Rotation3D const &r1, Rotation3D const &r2)
Double_t fX1
X coordinate of centre.
Double_t fY1
Y coordinate of centre.
virtual void Paint(Option_t *option="")
Paint this crown with its current attributes.
virtual void Modify()
Change current line attributes if necessary.
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
virtual Int_t DistancetoPrimitive(Int_t px, Int_t py)
Compute distance from point px,py to a crown.
if object in a list can be deleted
TCrown()
Crown default constructor.
virtual void AppendPad(Option_t *option="")
Append graphics object to current pad.
virtual Style_t GetLineStyle() const
Return the line style.
void Copy(TAttLine &attline) const
Copy this line attributes to a new TAttLine.
virtual void SaveLineAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1, Int_t widdef=1)
Save line attributes as C++ statement(s) on output stream out.
virtual void Modify()
Change current fill area attributes if necessary.
void Copy(TObject &crown) const
Copy this crown to crown.
virtual void DrawCrown(Double_t x1, Double_t y1, Double_t radin, Double_t radout, Double_t phimin=0, Double_t phimax=360, Option_t *option="")
Draw this crown with new coordinates.
Double_t fTheta
Rotation angle (degrees)
Double_t fPhimax
Maximum angle (degrees)
unsigned int r1[N_CITIES]
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save primitive as a C++ statement(s) on output stream out.
virtual void SaveFillAttributes(std::ostream &out, const char *name, Int_t coldef=1, Int_t stydef=1001)
Save fill attributes as C++ statement(s) on output stream out.
Double_t fR2
second radius
static const double x1[5]
virtual Color_t GetFillColor() const
Return the fill area color.
virtual ~TCrown()
Crown default destructor.
Mother of all ROOT objects.
void Copy(TObject &ellipse) const
Copy this ellipse to ellipse.
virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py)
Execute action corresponding to one event.
Bool_t GetNoEdges() const
Return kTRUE if kNoEdges bit is set, kFALSE otherwise.
virtual Style_t GetFillStyle() const
Return the fill area style.
Double_t Sqrt(Double_t x)
Double_t fPhimin
Minimum angle (degrees)
unsigned int r2[N_CITIES]
void Copy(TAttFill &attfill) const
Copy this fill attributes to a new TAttFill.