39 #if ( defined(G4GEOM_USE_USOLIDS) || defined(G4GEOM_USE_PARTIAL_USOLIDS) )
50 G4UTet::G4UTet(
const G4String& pName,
55 : G4USolid(pName, new UTet(pName,
56 UVector3(anchor.
x(),anchor.y(),anchor.
z()),
57 UVector3(p2.
x(), p2.y(), p2.
z()),
58 UVector3(p3.
x(), p3.y(), p3.
z()),
59 UVector3(p4.
x(), p4.y(), p4.
z()),
69 G4UTet::G4UTet( __void__&
a )
86 G4UTet::G4UTet(
const G4UTet& rhs)
96 G4UTet& G4UTet::operator = (
const G4UTet& rhs)
100 if (
this == &rhs) {
return *
this; }
104 G4USolid::operator=(rhs);
113 std::vector<G4ThreeVector> G4UTet::GetVertices()
const
115 std::vector<UVector3> vec = GetShape()->GetVertices();
116 std::vector<G4ThreeVector> vertices;
117 for (
unsigned int i=0; i<vec.size(); ++i)
120 vertices.push_back(v);
133 GetShape()->GetParametersList(index, array);
137 const G4int faces[4][4]={{1,3,2,0},{1,4,3,0},{1,2,4,0},{2,3,4,0}};
138 xyz[0][0]=array[0]; xyz[0][1]=array[1]; xyz[0][2]=array[2];
139 xyz[1][0]=array[3]; xyz[1][1]=array[4]; xyz[1][2]=array[5];
140 xyz[2][0]=array[6]; xyz[2][1]=array[7]; xyz[2][2]=array[8];
141 xyz[3][0]=array[9]; xyz[3][1]=array[10]; xyz[3][2]=array[11];
143 ph->createPolyhedron(4,4,xyz,faces);
148 #endif // G4GEOM_USE_USOLIDS
CLHEP::Hep3Vector G4ThreeVector
const G4double x[NPOINTSGL]