#ifndef __DRCSURFCYL_H__ #define __DRCSURFCYL_H__ /*! \brief Representation of a cylinder surface */ class DrcSurfCyl : public DrcSurfAbs { private: //! First point of cylinder axis XYZPoint m_p1; //! Second point of cylinder axis XYZPoint m_p2; //! Radius of cylinder. double m_radius; private: /*! \brief Auxiliary function for assignment operator and copy constructor.. \param s The object to copy. */ void copy(const DrcSurfCyl& s); public: DrcSurfCyl(); //!< Empty constructor. /*! \brief Copy constructor. \param s Object to copy. */ DrcSurfCyl(const DrcSurfCyl& s); /*! \brief Assignment operator. \param s Object to assign. */ DrcSurfCyl& operator=(const DrcSurfCyl& s); /*! \brief Add a surface boundary point. \param r1 First point of cylinder axis. \param r2 Second point of cylinder axis. \param radius Radius of cylinder. */ void set(XYZPoint r1, XYZPoint r2, double radius); // implemetation of pure virtual functions. virtual DrcSurfCyl* clone() const; XYZVector normal(const XYZPoint& point) const; bool surfaceHit(DrcPhoton& ph, XYZPoint& pos_new, double& path_length) const; void print(fstream& stream) const; void addTransform(const Transform3D& trans); virtual bool isFlat(){return false;}; }; #endif