Class ConcaveComponent
java.lang.Object
org.jlab.geom.abs.AbstractComponent
org.jlab.geom.detector.alert.AHDC.ConcaveComponent
- All Implemented Interfaces:
- Component,- Transformable,- Showable
- Direct Known Subclasses:
- AlertDCWire
- Author:
- sergeyeva
- 
Constructor SummaryConstructorsModifierConstructorDescriptionprotectedConcaveComponent(int componentId, List<Point3D> firstFace, List<Point3D> secondFace) 
- 
Method SummaryModifier and TypeMethodDescriptionReturns a vector pointing from themidpointof this component towards the readout end of the component (e.g. towards the PMT of a scintillator).doubleReturns the length of this component.getLine()Returns a line running down the middle of the length of the component such that the two end points of the line segment are at the geometric centers of the two polygons defining this component's volume.booleangetVolumeIntersection(Line3D line, Point3D inIntersect, Point3D outIntersect) Returns true if the given line segment intersect the volume-shape twice (one incoming intersection and one out going) and stores the incoming and outgoing intersection points are stored in the first and second Point3D objects given as arguments respectively.protected voidonRotateX(double angle) Classes extending AbstractComponent should implement onRotateX so that any additional geometric data they contain is rotated appropriately when AbstractComponent's rotateX method is invoke.protected voidonRotateY(double angle) Classes extending AbstractComponent should implement onRotateY so that any additional geometric data they contain is rotated appropriately when AbstractComponent's rotateY method is invoke.protected voidonRotateZ(double angle) Classes extending AbstractComponent should implement onRotateZ so that any additional geometric data they contain is rotated appropriately when AbstractComponent's rotateZ method is invoke.protected voidonTranslateXYZ(double dx, double dy, double dz) Classes extending AbstractComponent should implement onTranslateXYZ so that any additional geometric data they contain is translated appropriately when AbstractComponent's translateXYZ method is invoked.Methods inherited from class org.jlab.geom.abs.AbstractComponentaddVolumeEdge, addVolumePoint, addVolumeTriangleFace, getComponentId, getMidpoint, getNumVolumeEdges, getNumVolumePoints, getVolumeCrossSection, getVolumeEdge, getVolumePoint, getVolumeShape, rotateX, rotateY, rotateZ, show, toString, translateXYZ
- 
Constructor Details- 
ConcaveComponent
 
- 
- 
Method Details- 
getDirectionReturns a vector pointing from themidpointof this component towards the readout end of the component (e.g. towards the PMT of a scintillator).- Returns:
- the direction of the readout end
 
- 
getLineReturns a line running down the middle of the length of the component such that the two end points of the line segment are at the geometric centers of the two polygons defining this component's volume. By convention, the origin point of the line lies at the geometric center of the first face and the end point of the line lies at the geometric center of the second face.Note that getLength()=getLine().length().- Returns:
- a line running down the middle of the length the component
- See Also:
 
- 
getLengthpublic double getLength()Description copied from interface:ComponentReturns the length of this component.- Returns:
- the length
 
- 
onTranslateXYZprotected void onTranslateXYZ(double dx, double dy, double dz) Description copied from class:AbstractComponentClasses extending AbstractComponent should implement onTranslateXYZ so that any additional geometric data they contain is translated appropriately when AbstractComponent's translateXYZ method is invoked. This method is called at the end of AbstractComponent's translateXYZ method.- Overrides:
- onTranslateXYZin class- AbstractComponent
- Parameters:
- dx- amount to translate along the x axis
- dy- amount to translate along the y axis
- dz- amount to translate along the z axis
- See Also:
 
- 
onRotateXprotected void onRotateX(double angle) Description copied from class:AbstractComponentClasses extending AbstractComponent should implement onRotateX so that any additional geometric data they contain is rotated appropriately when AbstractComponent's rotateX method is invoke. This method is called at the end of AbstractComponent's rotateX method.- Overrides:
- onRotateXin class- AbstractComponent
- Parameters:
- angle- rotation angle in radians
- See Also:
 
- 
onRotateYprotected void onRotateY(double angle) Description copied from class:AbstractComponentClasses extending AbstractComponent should implement onRotateY so that any additional geometric data they contain is rotated appropriately when AbstractComponent's rotateY method is invoke. This method is called at the end of AbstractComponent's rotateY method.- Overrides:
- onRotateYin class- AbstractComponent
- Parameters:
- angle- rotation angle in radians
- See Also:
 
- 
onRotateZprotected void onRotateZ(double angle) Description copied from class:AbstractComponentClasses extending AbstractComponent should implement onRotateZ so that any additional geometric data they contain is rotated appropriately when AbstractComponent's rotateZ method is invoke. This method is called at the end of AbstractComponent's rotateZ method.- Overrides:
- onRotateZin class- AbstractComponent
- Parameters:
- angle- rotation angle in radians
- See Also:
 
- 
getVolumeIntersectionReturns true if the given line segment intersect the volume-shape twice (one incoming intersection and one out going) and stores the incoming and outgoing intersection points are stored in the first and second Point3D objects given as arguments respectively.The incoming intersection is defined such that the incoming intersection point is closer to the origin of the line than the outgoing intersection point. Developer's Note: For optimization, this algorithm assumes that - the volume contains N*4-4 triangular faces
- the faces form a closed bounding volume
- neither end point of the line segment are inside the volume
- pairs of faces from index 0 through N*2-1 (i.e. 1 and 2, 2 and 3, 3 and 4, etc.) are coplanar (the side trapezoids)
- the faces from N*2 through N*3-3 are coplanar (the first base)
- the faces from N*3-3 through N*4-5 are coplanar (the second base)
 - Parameters:
- line- the line segment
- inIntersect- the incoming intersection
- outIntersect- the outgoing intersection
- Returns:
- true if two intersections are found
 
 
-