98 if (phi1 > phi2 ) phi2 += 2*pi;
105 for (j = 0; j <
n; j++) {
106 ph = phi1 + j*angstep;
145 for (j = 0; j <
n; j++) {
154 for (j = 0; j <
n; j++) {
198 Int_t nbSegs = 2*nbPnts;
199 Int_t nbPols = nbPnts-2;
201 if (buffer.
SetRawSizes(nbPnts, 3*nbPnts, nbSegs, 3*nbSegs, nbPols, 6*nbPols)) {
218 for (i = 0; i < 4; i++) {
219 for (j = 1; j <
n; j++) {
220 buffer.
fSegs[(i*
n+j-1)*3 ] =
c;
221 buffer.
fSegs[(i*
n+j-1)*3+1] = i*
n+j-1;
222 buffer.
fSegs[(i*
n+j-1)*3+2] = i*
n+j;
225 for (i = 4; i < 6; i++) {
226 for (j = 0; j <
n; j++) {
227 buffer.
fSegs[(i*
n+j)*3 ] =
c+1;
228 buffer.
fSegs[(i*
n+j)*3+1] = (i-4)*
n+j;
229 buffer.
fSegs[(i*
n+j)*3+2] = (i-2)*
n+j;
232 for (i = 6; i < 8; i++) {
233 for (j = 0; j <
n; j++) {
235 buffer.
fSegs[(i*
n+j)*3+1] = 2*(i-6)*
n+j;
236 buffer.
fSegs[(i*
n+j)*3+2] = (2*(i-6)+1)*
n+j;
244 for (j = 0; j <
n-1; j++) {
246 buffer.
fPols[indx++] = 4;
247 buffer.
fPols[indx++] = (4+i)*
n+j+1;
248 buffer.
fPols[indx++] = (2+i)*
n+j;
249 buffer.
fPols[indx++] = (4+i)*
n+j;
250 buffer.
fPols[indx++] = i*
n+j;
253 for (j = 0; j <
n-1; j++) {
255 buffer.
fPols[indx++] = 4;
256 buffer.
fPols[indx++] = i*
n+j;
257 buffer.
fPols[indx++] = (4+i)*
n+j;
258 buffer.
fPols[indx++] = (2+i)*
n+j;
259 buffer.
fPols[indx++] = (4+i)*
n+j+1;
262 for (j = 0; j <
n-1; j++) {
263 buffer.
fPols[indx++] =
c+i;
264 buffer.
fPols[indx++] = 4;
265 buffer.
fPols[indx++] = (i-2)*2*
n+j;
266 buffer.
fPols[indx++] = (4+i)*
n+j;
267 buffer.
fPols[indx++] = ((i-2)*2+1)*
n+j;
268 buffer.
fPols[indx++] = (4+i)*
n+j+1;
271 for (j = 0; j <
n-1; j++) {
272 buffer.
fPols[indx++] =
c+i;
273 buffer.
fPols[indx++] = 4;
274 buffer.
fPols[indx++] = (4+i)*
n+j+1;
275 buffer.
fPols[indx++] = ((i-2)*2+1)*
n+j;
276 buffer.
fPols[indx++] = (4+i)*
n+j;
277 buffer.
fPols[indx++] = (i-2)*2*
n+j;
279 buffer.
fPols[indx++] =
c+2;
280 buffer.
fPols[indx++] = 4;
281 buffer.
fPols[indx++] = 6*
n;
282 buffer.
fPols[indx++] = 4*
n;
283 buffer.
fPols[indx++] = 7*
n;
284 buffer.
fPols[indx++] = 5*
n;
285 buffer.
fPols[indx++] =
c+2;
286 buffer.
fPols[indx++] = 4;
287 buffer.
fPols[indx++] = 6*
n-1;
288 buffer.
fPols[indx++] = 8*
n-1;
289 buffer.
fPols[indx++] = 5*
n-1;
290 buffer.
fPols[indx++] = 7*
n-1;
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t points
Generic 3D primitive description class.
void SetSectionsValid(UInt_t mask)
Bool_t SetRawSizes(UInt_t reqPnts, UInt_t reqPntsCapacity, UInt_t reqSegs, UInt_t reqSegsCapacity, UInt_t reqPols, UInt_t reqPolsCapacity)
Set kRaw tessellation section of buffer with supplied sizes.
Int_t GetBasicColor() const
Get basic color.
Int_t ShapeDistancetoPrimitive(Int_t numPoints, Int_t px, Int_t py)
Distance to primitive.
virtual void FillBuffer3D(TBuffer3D &buffer, Int_t reqSections) const
We have to set kRawSize (unless already done) to allocate buffer space before kRaw can be filled.
void TransformPoints(Double_t *points, UInt_t NbPnts) const
Transform points (LocalToMaster)
Double_t * fCoTab
Table of sin(fPhi1) .... sin(fPhil+fDphi1)
virtual Int_t GetNumberOfDivisions() const
~TTUBS() override
TUBS shape default destructor.
void SetPoints(Double_t *points) const override
Create TUBS points.
void Sizeof3D() const override
Return total X3D needed by TNode::ls (when called with option "x")
Int_t DistancetoPrimitive(Int_t px, Int_t py) override
Compute distance from point px,py to a TUBE.
void MakeTableOfCoSin() const override
Make table of sine and cosine.
const TBuffer3D & GetBuffer3D(Int_t reqSections) const override
Get buffer 3d.
TTUBS()
TUBS shape default constructor.
Double_t ATan(Double_t)
Returns the principal value of the arc tangent of x, expressed in radians.
Double_t Cos(Double_t)
Returns the cosine of an angle of x radians.
Double_t Sin(Double_t)
Returns the sine of an angle of x radians.