907 {
908 os << "View parameters and options:";
909
910 os << "\n Drawing style: " << v.fDrawingStyle;
911
912 os << "\n Number of cloud points: " << v.fNumberOfCloudPoints;
913
914 os << "\n Auxiliary edges: ";
915 if (!v.fAuxEdgeVisible) os << "in";
916 os << "visible";
917
918 os << "\n Culling: ";
919 if (v.fCulling) os << "on";
920 else os << "off";
921
922 os << "\n Culling invisible objects: ";
923 if (v.fCullInvisible) os << "on";
924 else os << "off";
925
926 os << "\n Density culling: ";
927 if (v.fDensityCulling) {
928 os << "on - invisible if density less than "
929 << v.fVisibleDensity / (1. * g / cm3) << " g cm^-3";
930 }
931 else os << "off";
932
933 os << "\n Culling daughters covered by opaque mothers: ";
934 if (v.fCullCovered) os << "on";
935 else os << "off";
936
937 os << "\n Colour by density: ";
938 if (v.fCBDAlgorithmNumber <= 0) {
939 os << "inactive";
940 } else {
941 os << "Algorithm " << v.fCBDAlgorithmNumber << ", Parameters:";
942 for (auto p: v.fCBDParameters) {
944 }
945 }
946
947 os << "\n Section flag: ";
948 if (v.fSection) os << "true, section/cut plane: " << v.fSectionPlane;
949 else os << "false";
950
952 os << "\n Cutaway planes: ";
953 for (size_t i = 0; i < v.fCutawayPlanes.size (); i++) {
954 os << ' ' << v.fCutawayPlanes[i];
955 }
956 }
957 else {
958 os << "\n No cutaway planes";
959 }
960
961 os << "\n Explode factor: " << v.fExplodeFactor
962 << " about centre: " << v.fExplodeCentre;
963
964 os << "\n No. of sides used in circle polygon approximation: "
965 << v.fNoOfSides;
966
967 os << "\n Viewpoint direction: " << v.fViewpointDirection;
968
969 os << "\n Up vector: " << v.fUpVector;
970
971 os << "\n Field half angle: " << v.fFieldHalfAngle;
972
973 os << "\n Zoom factor: " << v.fZoomFactor;
974
975 os << "\n Scale factor: " << v.fScaleFactor;
976
977 os << "\n Current target point: " << v.fCurrentTargetPoint;
978
979 os << "\n Dolly distance: " << v.fDolly;
980
981 os << "\n Light ";
982 if (v.fLightsMoveWithCamera) os << "moves";
983 else os << "does not move";
984 os << " with camera";
985
986 os << "\n Relative lightpoint direction: "
987 << v.fRelativeLightpointDirection;
988
989 os << "\n Actual lightpoint direction: "
990 << v.fActualLightpointDirection;
991
992 os << "\n Derived parameters for standard view of object of unit radius:";
994 tempVP.fDolly = 0.;
995 tempVP.fZoomFactor = 1.;
1003 os << "\n Camera distance: " << cameraDistance;
1004 os << "\n Near distance: " << nearDistance;
1005 os << "\n Far distance: " << farDistance;
1006 os << "\n Front half height: " << right;
1007
1008 os << "\n Default VisAttributes:\n " << v.fDefaultVisAttributes;
1009
1010 os << "\n Default TextVisAttributes:\n " << v.fDefaultTextVisAttributes;
1011
1012 os << "\n Default marker: " << v.fDefaultMarker;
1013
1014 os << "\n Global marker scale: " << v.fGlobalMarkerScale;
1015
1016 os << "\n Global lineWidth scale: " << v.fGlobalLineWidthScale;
1017
1018 os << "\n Marker ";
1019 if (v.fMarkerNotHidden) os << "not ";
1020 os << "hidden by surfaces.";
1021
1022 os << "\n Window size hint: "
1023 << v.fWindowSizeHintX << 'x'<< v.fWindowSizeHintX;
1024
1025 os << "\n X geometry string: " << v.fXGeometryString;
1026 os << "\n X geometry mask: "
1027 << std::showbase << std::hex << v.fGeometryMask
1028 << std::noshowbase << std::dec;
1029
1030 os << "\n Auto refresh: ";
1031 if (v.fAutoRefresh) os << "true";
1032 else os << "false";
1033
1034 os << "\n Background colour: " << v.fBackgroundColour;
1035
1036 os << "\n Picking requested: ";
1037 if (v.fPicking) os << "true";
1038 else os << "false";
1039
1040 os << "\n Rotation style: ";
1041 switch (v.fRotationStyle) {
1043 os << "constrainUpDirection (conventional HEP view)"; break;
1045 os << "freeRotation (Google-like rotation, using mouse-grab)"; break;
1046 default: os << "unrecognised"; break;
1047 }
1048
1049 os << "\n Vis attributes modifiers: ";
1050 const std::vector<G4ModelingParameters::VisAttributesModifier>& vams =
1051 v.fVisAttributesModifiers;
1052 if (vams.empty()) {
1053 os << "None";
1054 } else {
1055 os << vams;
1056 }
1057
1058 os << "\n Time window parameters:"
1059 <<
"\n Start time: " << v.fStartTime/
ns <<
" ns"
1060 <<
"\n End time: " << v.fEndTime/
ns <<
" ns"
1061 << "\n Fade factor: " << v.fFadeFactor;
1062 if (!v.fDisplayHeadTime) {
1063 os << "\n Head time display not requested.";
1064 } else {
1065 os
1066 << "\n Head time position: "
1067 << v.fDisplayHeadTimeX << ' ' << v.fDisplayHeadTimeY
1068 << "\n Head time size: " << v.fDisplayHeadTimeSize
1069 << "\n Head time colour: " << v.fDisplayHeadTimeRed
1070 << ' ' << v.fDisplayHeadTimeGreen << ' ' << v.fDisplayHeadTimeBlue;
1071 }
1072 if (!v.fDisplayLightFront) {
1073 os << "\n Light front display not requested.";
1074 } else {
1075 os
1076 << "\n Light front position: "
1077 << v.fDisplayLightFrontX/mm << ' ' << v.fDisplayLightFrontY/mm
1078 << ' ' << v.fDisplayLightFrontZ/mm << " mm"
1079 <<
"\n Light front time: " << v.fDisplayLightFrontT/
ns <<
" ns"
1080 << "\n Light front colour: " << v.fDisplayLightFrontRed
1081 << ' ' << v.fDisplayLightFrontGreen << ' ' << v.fDisplayLightFrontBlue;
1082 }
1083
1084 os << "\n Special Mesh Rendering";
1085 if (v.fSpecialMeshRendering) {
1086 os << " requested with option \"" << v.fSpecialMeshRenderingOption;
1087 os << "\" for ";
1088 if (v.fSpecialMeshVolumes.empty()) {
1089 os << "any mesh";
1090 } else {
1091 os << "selected meshes";
1092 for (const auto& vol: v.fSpecialMeshVolumes) {
1093 os << "\n " << vol.GetName() << ':' << vol.GetCopyNo();
1094 }
1095 }
1096 } else os << ": off";
1097 return os;
1098}
G4double GetCameraDistance(G4double radius) const
G4double GetFarDistance(G4double cameraDistance, G4double nearDistance, G4double radius) const
G4double GetFrontHalfHeight(G4double nearDistance, G4double radius) const
G4double GetNearDistance(G4double cameraDistance, G4double radius) const