//*CMZ : 1.00/06 17/04/99 07.50.09 by Rene Brun //*-- Author : Nenad Buncic 17/09/95 //*KEEP,CopyRight,T=C. /************************************************************************* * Copyright(c) 1995-1999, The ROOT System, All rights reserved. * * Authors: Rene Brun and Fons Rademakers. * * * * For the licensing terms see $ROOTSYS/AA_LICENSE. * * For the list of contributors see $ROOTSYS/AA_CREDITS. * *************************************************************************/ //*KEND. //*KEEP,TTRD1. #include "TTRD1.h" //*KEEP,TNode. #include "TNode.h" //*KEND. ClassImp(TTRD1) //______________________________________________________________________________ //// TRD1 is a trapezoid with the x dimension varying along z. // It has 7 parameters: // // - name name of the shape // - title shape's title // - material (see TMaterial) // - dx1 half-length along x at the z surface positioned at -DZ // - dx2 half-length along x at the z surface positioned at +DZ // - dy half-length along the y-axis // - dz half-length along the z-axis //______________________________________________________________________________ TTRD1::TTRD1() { //*-*-*-*-*-*-*-*-*-*-*-*TRD1 shape default constructor*-*-*-*-*-*-*-*-*-*-*-*-* //*-* ============================== } //______________________________________________________________________________ TTRD1::TTRD1(Text_t *name, Text_t *title, Text_t *material, Float_t dx1, Float_t dx2, Float_t dy, Float_t dz) : TBRIK(name, title,material,dx1,dy,dz) { //*-*-*-*-*-*-*-*-*-*-*-*-*TRD1 shape normal constructor*-*-*-*-*-*-*-*-*-*-*-*-* //*-* ============================= fDx2 = dx2; } //______________________________________________________________________________ TTRD1::~TTRD1() { //*-*-*-*-*-*-*-*-*-*-*-*-*TRD1 shape default destructor*-*-*-*-*-*-*-*-*-*-*-*-* //*-* ============================= } //______________________________________________________________________________ void TTRD1::SetPoints(Float_t *buff) { //*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*Create TRD1 points*-*-*-*-*-*-*-*-*-*-*-*-*-*-* //*-* ================== Float_t dx1, dx2, dy, dz; dx1 = TBRIK::fDx; dx2 = fDx2; dy = TBRIK::fDy; dz = TBRIK::fDz; if (buff) { buff[ 0] = -dx1; buff[ 1] = -dy; buff[ 2] = -dz; buff[ 3] = dx1; buff[ 4] = -dy; buff[ 5] = -dz; buff[ 6] = dx1; buff[ 7] = dy; buff[ 8] = -dz; buff[ 9] = -dx1; buff[10] = dy; buff[11] = -dz; buff[12] = -dx2; buff[13] = -dy; buff[14] = dz; buff[15] = dx2; buff[16] = -dy; buff[17] = dz; buff[18] = dx2; buff[19] = dy; buff[20] = dz; buff[21] = -dx2; buff[22] = dy; buff[23] = dz; } }