change to Linux
This commit is contained in:
parent
06b92fd866
commit
5d6f2765e3
424
.clang-format
424
.clang-format
|
@ -1,212 +1,212 @@
|
||||||
---
|
---
|
||||||
Language: Cpp
|
Language: Cpp
|
||||||
# BasedOnStyle: Google
|
# BasedOnStyle: Google
|
||||||
AccessModifierOffset: -4
|
AccessModifierOffset: -4
|
||||||
AlignAfterOpenBracket: Align
|
AlignAfterOpenBracket: Align
|
||||||
AlignArrayOfStructures: None
|
AlignArrayOfStructures: None
|
||||||
AlignConsecutiveMacros: None
|
AlignConsecutiveMacros: None
|
||||||
AlignConsecutiveAssignments: None
|
AlignConsecutiveAssignments: None
|
||||||
AlignConsecutiveBitFields: None
|
AlignConsecutiveBitFields: None
|
||||||
AlignConsecutiveDeclarations: None
|
AlignConsecutiveDeclarations: None
|
||||||
AlignEscapedNewlines: Left
|
AlignEscapedNewlines: Left
|
||||||
AlignOperands: Align
|
AlignOperands: Align
|
||||||
AlignTrailingComments: true
|
AlignTrailingComments: true
|
||||||
AllowAllArgumentsOnNextLine: true
|
AllowAllArgumentsOnNextLine: true
|
||||||
AllowAllConstructorInitializersOnNextLine: true
|
AllowAllConstructorInitializersOnNextLine: true
|
||||||
AllowAllParametersOfDeclarationOnNextLine: true
|
AllowAllParametersOfDeclarationOnNextLine: true
|
||||||
AllowShortEnumsOnASingleLine: true
|
AllowShortEnumsOnASingleLine: true
|
||||||
AllowShortBlocksOnASingleLine: Never
|
AllowShortBlocksOnASingleLine: Never
|
||||||
AllowShortCaseLabelsOnASingleLine: false
|
AllowShortCaseLabelsOnASingleLine: false
|
||||||
AllowShortFunctionsOnASingleLine: All
|
AllowShortFunctionsOnASingleLine: All
|
||||||
AllowShortLambdasOnASingleLine: All
|
AllowShortLambdasOnASingleLine: All
|
||||||
AllowShortIfStatementsOnASingleLine: WithoutElse
|
AllowShortIfStatementsOnASingleLine: WithoutElse
|
||||||
AllowShortLoopsOnASingleLine: true
|
AllowShortLoopsOnASingleLine: true
|
||||||
AlwaysBreakAfterDefinitionReturnType: None
|
AlwaysBreakAfterDefinitionReturnType: None
|
||||||
AlwaysBreakAfterReturnType: None
|
AlwaysBreakAfterReturnType: None
|
||||||
AlwaysBreakBeforeMultilineStrings: true
|
AlwaysBreakBeforeMultilineStrings: true
|
||||||
AlwaysBreakTemplateDeclarations: Yes
|
AlwaysBreakTemplateDeclarations: Yes
|
||||||
AttributeMacros:
|
AttributeMacros:
|
||||||
- __capability
|
- __capability
|
||||||
BinPackArguments: true
|
BinPackArguments: true
|
||||||
BinPackParameters: true
|
BinPackParameters: true
|
||||||
BraceWrapping:
|
BraceWrapping:
|
||||||
AfterCaseLabel: false
|
AfterCaseLabel: false
|
||||||
AfterClass: false
|
AfterClass: false
|
||||||
AfterControlStatement: Never
|
AfterControlStatement: Never
|
||||||
AfterEnum: false
|
AfterEnum: false
|
||||||
AfterFunction: false
|
AfterFunction: false
|
||||||
AfterNamespace: false
|
AfterNamespace: false
|
||||||
AfterObjCDeclaration: false
|
AfterObjCDeclaration: false
|
||||||
AfterStruct: false
|
AfterStruct: false
|
||||||
AfterUnion: false
|
AfterUnion: false
|
||||||
AfterExternBlock: false
|
AfterExternBlock: false
|
||||||
BeforeCatch: false
|
BeforeCatch: false
|
||||||
BeforeElse: false
|
BeforeElse: false
|
||||||
BeforeLambdaBody: false
|
BeforeLambdaBody: false
|
||||||
BeforeWhile: false
|
BeforeWhile: false
|
||||||
IndentBraces: false
|
IndentBraces: false
|
||||||
SplitEmptyFunction: true
|
SplitEmptyFunction: true
|
||||||
SplitEmptyRecord: true
|
SplitEmptyRecord: true
|
||||||
SplitEmptyNamespace: true
|
SplitEmptyNamespace: true
|
||||||
BreakBeforeBinaryOperators: None
|
BreakBeforeBinaryOperators: None
|
||||||
BreakBeforeConceptDeclarations: true
|
BreakBeforeConceptDeclarations: true
|
||||||
BreakBeforeBraces: Attach
|
BreakBeforeBraces: Attach
|
||||||
BreakBeforeInheritanceComma: false
|
BreakBeforeInheritanceComma: false
|
||||||
BreakInheritanceList: BeforeColon
|
BreakInheritanceList: BeforeColon
|
||||||
BreakBeforeTernaryOperators: true
|
BreakBeforeTernaryOperators: true
|
||||||
BreakConstructorInitializersBeforeComma: false
|
BreakConstructorInitializersBeforeComma: false
|
||||||
BreakConstructorInitializers: BeforeColon
|
BreakConstructorInitializers: BeforeColon
|
||||||
BreakAfterJavaFieldAnnotations: false
|
BreakAfterJavaFieldAnnotations: false
|
||||||
BreakStringLiterals: true
|
BreakStringLiterals: true
|
||||||
ColumnLimit: 120
|
ColumnLimit: 120
|
||||||
CommentPragmas: '^ IWYU pragma:'
|
CommentPragmas: '^ IWYU pragma:'
|
||||||
CompactNamespaces: false
|
CompactNamespaces: false
|
||||||
ConstructorInitializerAllOnOneLineOrOnePerLine: true
|
ConstructorInitializerAllOnOneLineOrOnePerLine: true
|
||||||
ConstructorInitializerIndentWidth: 4
|
ConstructorInitializerIndentWidth: 4
|
||||||
ContinuationIndentWidth: 4
|
ContinuationIndentWidth: 4
|
||||||
Cpp11BracedListStyle: true
|
Cpp11BracedListStyle: true
|
||||||
DeriveLineEnding: true
|
DeriveLineEnding: true
|
||||||
DerivePointerAlignment: true
|
DerivePointerAlignment: true
|
||||||
DisableFormat: false
|
DisableFormat: false
|
||||||
EmptyLineAfterAccessModifier: Never
|
EmptyLineAfterAccessModifier: Never
|
||||||
EmptyLineBeforeAccessModifier: LogicalBlock
|
EmptyLineBeforeAccessModifier: LogicalBlock
|
||||||
ExperimentalAutoDetectBinPacking: false
|
ExperimentalAutoDetectBinPacking: false
|
||||||
FixNamespaceComments: true
|
FixNamespaceComments: true
|
||||||
ForEachMacros:
|
ForEachMacros:
|
||||||
- foreach
|
- foreach
|
||||||
- Q_FOREACH
|
- Q_FOREACH
|
||||||
- BOOST_FOREACH
|
- BOOST_FOREACH
|
||||||
IfMacros:
|
IfMacros:
|
||||||
- KJ_IF_MAYBE
|
- KJ_IF_MAYBE
|
||||||
IncludeBlocks: Regroup
|
IncludeBlocks: Regroup
|
||||||
IncludeCategories:
|
IncludeCategories:
|
||||||
- Regex: '^<ext/.*\.h>'
|
- Regex: '^<ext/.*\.h>'
|
||||||
Priority: 2
|
Priority: 2
|
||||||
SortPriority: 0
|
SortPriority: 0
|
||||||
CaseSensitive: false
|
CaseSensitive: false
|
||||||
- Regex: '^<.*\.h>'
|
- Regex: '^<.*\.h>'
|
||||||
Priority: 1
|
Priority: 1
|
||||||
SortPriority: 0
|
SortPriority: 0
|
||||||
CaseSensitive: false
|
CaseSensitive: false
|
||||||
- Regex: '^<.*'
|
- Regex: '^<.*'
|
||||||
Priority: 2
|
Priority: 2
|
||||||
SortPriority: 0
|
SortPriority: 0
|
||||||
CaseSensitive: false
|
CaseSensitive: false
|
||||||
- Regex: '.*'
|
- Regex: '.*'
|
||||||
Priority: 3
|
Priority: 3
|
||||||
SortPriority: 0
|
SortPriority: 0
|
||||||
CaseSensitive: false
|
CaseSensitive: false
|
||||||
IncludeIsMainRegex: '([-_](test|unittest))?$'
|
IncludeIsMainRegex: '([-_](test|unittest))?$'
|
||||||
IncludeIsMainSourceRegex: ''
|
IncludeIsMainSourceRegex: ''
|
||||||
IndentAccessModifiers: false
|
IndentAccessModifiers: false
|
||||||
IndentCaseLabels: true
|
IndentCaseLabels: true
|
||||||
IndentCaseBlocks: false
|
IndentCaseBlocks: false
|
||||||
IndentGotoLabels: true
|
IndentGotoLabels: true
|
||||||
IndentPPDirectives: None
|
IndentPPDirectives: None
|
||||||
IndentExternBlock: AfterExternBlock
|
IndentExternBlock: AfterExternBlock
|
||||||
IndentRequires: false
|
IndentRequires: false
|
||||||
IndentWidth: 4
|
IndentWidth: 4
|
||||||
IndentWrappedFunctionNames: false
|
IndentWrappedFunctionNames: false
|
||||||
InsertTrailingCommas: None
|
InsertTrailingCommas: None
|
||||||
JavaScriptQuotes: Leave
|
JavaScriptQuotes: Leave
|
||||||
JavaScriptWrapImports: true
|
JavaScriptWrapImports: true
|
||||||
KeepEmptyLinesAtTheStartOfBlocks: false
|
KeepEmptyLinesAtTheStartOfBlocks: false
|
||||||
LambdaBodyIndentation: Signature
|
LambdaBodyIndentation: Signature
|
||||||
MacroBlockBegin: ''
|
MacroBlockBegin: ''
|
||||||
MacroBlockEnd: ''
|
MacroBlockEnd: ''
|
||||||
MaxEmptyLinesToKeep: 1
|
MaxEmptyLinesToKeep: 1
|
||||||
NamespaceIndentation: None
|
NamespaceIndentation: None
|
||||||
ObjCBinPackProtocolList: Never
|
ObjCBinPackProtocolList: Never
|
||||||
ObjCBlockIndentWidth: 2
|
ObjCBlockIndentWidth: 2
|
||||||
ObjCBreakBeforeNestedBlockParam: true
|
ObjCBreakBeforeNestedBlockParam: true
|
||||||
ObjCSpaceAfterProperty: false
|
ObjCSpaceAfterProperty: false
|
||||||
ObjCSpaceBeforeProtocolList: true
|
ObjCSpaceBeforeProtocolList: true
|
||||||
PenaltyBreakAssignment: 2
|
PenaltyBreakAssignment: 2
|
||||||
PenaltyBreakBeforeFirstCallParameter: 1
|
PenaltyBreakBeforeFirstCallParameter: 1
|
||||||
PenaltyBreakComment: 300
|
PenaltyBreakComment: 300
|
||||||
PenaltyBreakFirstLessLess: 120
|
PenaltyBreakFirstLessLess: 120
|
||||||
PenaltyBreakString: 1000
|
PenaltyBreakString: 1000
|
||||||
PenaltyBreakTemplateDeclaration: 10
|
PenaltyBreakTemplateDeclaration: 10
|
||||||
PenaltyExcessCharacter: 1000000
|
PenaltyExcessCharacter: 1000000
|
||||||
PenaltyReturnTypeOnItsOwnLine: 200
|
PenaltyReturnTypeOnItsOwnLine: 200
|
||||||
PenaltyIndentedWhitespace: 0
|
PenaltyIndentedWhitespace: 0
|
||||||
PointerAlignment: Left
|
PointerAlignment: Left
|
||||||
PPIndentWidth: -1
|
PPIndentWidth: -1
|
||||||
RawStringFormats:
|
RawStringFormats:
|
||||||
- Language: Cpp
|
- Language: Cpp
|
||||||
Delimiters:
|
Delimiters:
|
||||||
- cc
|
- cc
|
||||||
- CC
|
- CC
|
||||||
- cpp
|
- cpp
|
||||||
- Cpp
|
- Cpp
|
||||||
- CPP
|
- CPP
|
||||||
- 'c++'
|
- 'c++'
|
||||||
- 'C++'
|
- 'C++'
|
||||||
CanonicalDelimiter: ''
|
CanonicalDelimiter: ''
|
||||||
BasedOnStyle: google
|
BasedOnStyle: google
|
||||||
- Language: TextProto
|
- Language: TextProto
|
||||||
Delimiters:
|
Delimiters:
|
||||||
- pb
|
- pb
|
||||||
- PB
|
- PB
|
||||||
- proto
|
- proto
|
||||||
- PROTO
|
- PROTO
|
||||||
EnclosingFunctions:
|
EnclosingFunctions:
|
||||||
- EqualsProto
|
- EqualsProto
|
||||||
- EquivToProto
|
- EquivToProto
|
||||||
- PARSE_PARTIAL_TEXT_PROTO
|
- PARSE_PARTIAL_TEXT_PROTO
|
||||||
- PARSE_TEST_PROTO
|
- PARSE_TEST_PROTO
|
||||||
- PARSE_TEXT_PROTO
|
- PARSE_TEXT_PROTO
|
||||||
- ParseTextOrDie
|
- ParseTextOrDie
|
||||||
- ParseTextProtoOrDie
|
- ParseTextProtoOrDie
|
||||||
- ParseTestProto
|
- ParseTestProto
|
||||||
- ParsePartialTestProto
|
- ParsePartialTestProto
|
||||||
CanonicalDelimiter: pb
|
CanonicalDelimiter: pb
|
||||||
BasedOnStyle: google
|
BasedOnStyle: google
|
||||||
ReferenceAlignment: Pointer
|
ReferenceAlignment: Pointer
|
||||||
ReflowComments: true
|
ReflowComments: true
|
||||||
ShortNamespaceLines: 1
|
ShortNamespaceLines: 1
|
||||||
SortIncludes: CaseSensitive
|
SortIncludes: CaseSensitive
|
||||||
SortJavaStaticImport: Before
|
SortJavaStaticImport: Before
|
||||||
SortUsingDeclarations: true
|
SortUsingDeclarations: true
|
||||||
SpaceAfterCStyleCast: false
|
SpaceAfterCStyleCast: false
|
||||||
SpaceAfterLogicalNot: false
|
SpaceAfterLogicalNot: false
|
||||||
SpaceAfterTemplateKeyword: true
|
SpaceAfterTemplateKeyword: true
|
||||||
SpaceBeforeAssignmentOperators: true
|
SpaceBeforeAssignmentOperators: true
|
||||||
SpaceBeforeCaseColon: false
|
SpaceBeforeCaseColon: false
|
||||||
SpaceBeforeCpp11BracedList: false
|
SpaceBeforeCpp11BracedList: false
|
||||||
SpaceBeforeCtorInitializerColon: true
|
SpaceBeforeCtorInitializerColon: true
|
||||||
SpaceBeforeInheritanceColon: true
|
SpaceBeforeInheritanceColon: true
|
||||||
SpaceBeforeParens: ControlStatements
|
SpaceBeforeParens: ControlStatements
|
||||||
SpaceAroundPointerQualifiers: Default
|
SpaceAroundPointerQualifiers: Default
|
||||||
SpaceBeforeRangeBasedForLoopColon: true
|
SpaceBeforeRangeBasedForLoopColon: true
|
||||||
SpaceInEmptyBlock: false
|
SpaceInEmptyBlock: false
|
||||||
SpaceInEmptyParentheses: false
|
SpaceInEmptyParentheses: false
|
||||||
SpacesBeforeTrailingComments: 2
|
SpacesBeforeTrailingComments: 2
|
||||||
SpacesInAngles: Never
|
SpacesInAngles: Never
|
||||||
SpacesInConditionalStatement: false
|
SpacesInConditionalStatement: false
|
||||||
SpacesInContainerLiterals: true
|
SpacesInContainerLiterals: true
|
||||||
SpacesInCStyleCastParentheses: false
|
SpacesInCStyleCastParentheses: false
|
||||||
SpacesInLineCommentPrefix:
|
SpacesInLineCommentPrefix:
|
||||||
Minimum: 1
|
Minimum: 1
|
||||||
Maximum: -1
|
Maximum: -1
|
||||||
SpacesInParentheses: false
|
SpacesInParentheses: false
|
||||||
SpacesInSquareBrackets: false
|
SpacesInSquareBrackets: false
|
||||||
SpaceBeforeSquareBrackets: false
|
SpaceBeforeSquareBrackets: false
|
||||||
BitFieldColonSpacing: Both
|
BitFieldColonSpacing: Both
|
||||||
Standard: Auto
|
Standard: Auto
|
||||||
StatementAttributeLikeMacros:
|
StatementAttributeLikeMacros:
|
||||||
- Q_EMIT
|
- Q_EMIT
|
||||||
StatementMacros:
|
StatementMacros:
|
||||||
- Q_UNUSED
|
- Q_UNUSED
|
||||||
- QT_REQUIRE_VERSION
|
- QT_REQUIRE_VERSION
|
||||||
TabWidth: 8
|
TabWidth: 8
|
||||||
UseCRLF: false
|
UseCRLF: false
|
||||||
UseTab: Never
|
UseTab: Never
|
||||||
WhitespaceSensitiveMacros:
|
WhitespaceSensitiveMacros:
|
||||||
- STRINGIZE
|
- STRINGIZE
|
||||||
- PP_STRINGIZE
|
- PP_STRINGIZE
|
||||||
- BOOST_PP_STRINGIZE
|
- BOOST_PP_STRINGIZE
|
||||||
- NS_SWIFT_NAME
|
- NS_SWIFT_NAME
|
||||||
- CF_SWIFT_NAME
|
- CF_SWIFT_NAME
|
||||||
...
|
...
|
||||||
|
|
||||||
|
|
|
@ -1,23 +1,22 @@
|
||||||
{
|
{
|
||||||
"configurations": [
|
"configurations": [
|
||||||
{
|
{
|
||||||
"name": "Win32",
|
"name": "Linux",
|
||||||
"includePath": [
|
"includePath": [
|
||||||
"${default}",
|
"${default}",
|
||||||
"${workspaceFolder}/include",
|
"${workspaceFolder}/include",
|
||||||
"D:/Geant4/dist/include/Geant4",
|
"/home/fox/G4Kit/Geant4/include",
|
||||||
"D:/ROOT/include"
|
"/home/fox/G4Kit/ROOT/include"
|
||||||
],
|
],
|
||||||
"defines": [
|
"defines": [
|
||||||
"_DEBUG",
|
"_DEBUG",
|
||||||
"UNICODE",
|
"UNICODE",
|
||||||
"_UNICODE"
|
"_UNICODE"
|
||||||
],
|
],
|
||||||
"windowsSdkVersion": "10.0.19041.0",
|
"compilerPath": "/usr/bin/gcc",
|
||||||
"compilerPath": "D:/Microsoft/VisualStudio/2022/Community/VC/Tools/MSVC/14.31.31103/bin/Hostx64/x64/cl.exe",
|
|
||||||
"cStandard": "c17",
|
"cStandard": "c17",
|
||||||
"cppStandard": "c++17",
|
"cppStandard": "c++17",
|
||||||
"intelliSenseMode": "windows-msvc-x64",
|
"intelliSenseMode": "linux-gcc-x64",
|
||||||
"configurationProvider": "ms-vscode.cmake-tools"
|
"configurationProvider": "ms-vscode.cmake-tools"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
{
|
|
||||||
"cmake.configureSettings": {
|
|
||||||
"CMAKE_TOOLCHAIN_FILE": "D:/Microsoft/vcpkg/scripts/buildsystems/vcpkg.cmake"
|
|
||||||
}
|
|
||||||
}
|
|
|
@ -1,33 +1,36 @@
|
||||||
cmake_minimum_required(VERSION 3.16)
|
cmake_minimum_required(VERSION 3.16)
|
||||||
set(Geant4_DIR D:/Geant4/dist/lib/Geant4-11.0.1)
|
set(Geant4_DIR D:/Geant4/dist/lib/Geant4-11.0.1)
|
||||||
|
|
||||||
project(exampleB0)
|
project(exampleB0)
|
||||||
|
|
||||||
option(WITH_GEANT4_UIVIS "Build example with Geant4 UI and Vis drivers" ON)
|
set(Geant4_DIR ${Geant4_DIR})
|
||||||
if(WITH_GEANT4_UIVIS)
|
option(WITH_GEANT4_UIVIS "Build example with Geant4 UI and Vis drivers" ON)
|
||||||
find_package(Geant4 REQUIRED ui_all vis_all)
|
if(WITH_GEANT4_UIVIS)
|
||||||
else()
|
find_package(Geant4 REQUIRED ui_all vis_all)
|
||||||
find_package(Geant4 REQUIRED)
|
else()
|
||||||
endif()
|
find_package(Geant4 REQUIRED)
|
||||||
|
endif()
|
||||||
include(${Geant4_USE_FILE})
|
|
||||||
include_directories(${PROJECT_SOURCE_DIR}/include)
|
include(${Geant4_USE_FILE})
|
||||||
|
include_directories(${PROJECT_SOURCE_DIR}/include)
|
||||||
file(GLOB sources ${PROJECT_SOURCE_DIR}/src/*.cpp)
|
|
||||||
file(GLOB headers ${PROJECT_SOURCE_DIR}/include/*.h)
|
file(GLOB sources ${PROJECT_SOURCE_DIR}/src/*.cpp)
|
||||||
|
file(GLOB headers ${PROJECT_SOURCE_DIR}/include/*.h)
|
||||||
add_executable(exampleB0 main.cpp ${sources} ${headers})
|
|
||||||
target_link_libraries(exampleB0 ${Geant4_LIBRARIES})
|
add_executable(exampleB0 main.cpp ${sources} ${headers})
|
||||||
|
target_link_libraries(exampleB0 ${Geant4_LIBRARIES})
|
||||||
set(exampleB0_SCRIPTS
|
|
||||||
auto.mac
|
set(exampleB0_SCRIPTS
|
||||||
vis.mac
|
auto.mac
|
||||||
)
|
vis.mac
|
||||||
|
)
|
||||||
foreach(_script ${exampleB0_SCRIPTS})
|
|
||||||
configure_file(
|
foreach(_script ${exampleB0_SCRIPTS})
|
||||||
${PROJECT_SOURCE_DIR}/${_script}
|
configure_file(
|
||||||
${PROJECT_BINARY_DIR}/Release/${_script}
|
${PROJECT_SOURCE_DIR}/${_script}
|
||||||
COPYONLY
|
${PROJECT_BINARY_DIR}/${_script}
|
||||||
)
|
COPYONLY
|
||||||
endforeach()
|
)
|
||||||
|
endforeach()
|
||||||
|
|
||||||
|
install(TARGETS exampleB0 DESTINATION bin)
|
||||||
|
|
10
README.md
10
README.md
|
@ -1,5 +1,5 @@
|
||||||
# G4 example B0
|
# G4 example B0
|
||||||
|
|
||||||
放疗水箱常用于放疗装置的剂量校准,其尺寸为(x=638mm,y=630mm,z=555mm)。现假设一笔形束从x-y平面中心处,自水箱外向下射入放疗水箱。
|
放疗水箱常用于放疗装置的剂量校准,其尺寸为(x=638mm,y=630mm,z=555mm)。现假设一笔形束从x-y平面中心处,自水箱外向下射入放疗水箱。
|
||||||
|
|
||||||
请用`Geant4`模拟计算不同能量的光子(1MeV、5MeV、10MeV)入射后在放疗水箱的z方向上的吸收剂量变化曲线。
|
请用`Geant4`模拟计算不同能量的光子(1MeV、5MeV、10MeV)入射后在放疗水箱的z方向上的吸收剂量变化曲线。
|
||||||
|
|
100
auto.mac
100
auto.mac
|
@ -1,50 +1,50 @@
|
||||||
# 多线程设置
|
# 多线程设置
|
||||||
/run/numberOfThreads 12
|
/run/numberOfThreads 12
|
||||||
|
|
||||||
# verbose
|
# verbose
|
||||||
/control/verbose 1
|
/control/verbose 1
|
||||||
/run/verbose 1
|
/run/verbose 1
|
||||||
/event/verbose 0
|
/event/verbose 0
|
||||||
/tracking/verbose 0
|
/tracking/verbose 0
|
||||||
|
|
||||||
# 初始化
|
# 初始化
|
||||||
/run/initialize
|
/run/initialize
|
||||||
|
|
||||||
# 定义 scoring 网格
|
# 定义 scoring 网格
|
||||||
/score/create/boxMesh water_box
|
/score/create/boxMesh water_box
|
||||||
/score/mesh/boxSize 319. 315. 277.5 mm
|
/score/mesh/boxSize 319. 315. 277.5 mm
|
||||||
/score/mesh/nBin 1 1 555
|
/score/mesh/nBin 1 1 555
|
||||||
|
|
||||||
# 定义需要获取的物理量与过滤器
|
# 定义需要获取的物理量与过滤器
|
||||||
# 过滤器,本例需要考虑次级粒子
|
# 过滤器,本例需要考虑次级粒子
|
||||||
/score/quantity/energyDeposit eDep
|
/score/quantity/energyDeposit eDep
|
||||||
/score/quantity/doseDeposit Dose
|
/score/quantity/doseDeposit Dose
|
||||||
# /score/filter/particle gammaFilter gamma
|
# /score/filter/particle gammaFilter gamma
|
||||||
/score/close
|
/score/close
|
||||||
|
|
||||||
# 发射粒子
|
# 发射粒子
|
||||||
/gun/particle gamma
|
/gun/particle gamma
|
||||||
/gun/energy 1 MeV
|
/gun/energy 1 MeV
|
||||||
/run/beamOn 100000
|
/run/beamOn 100000
|
||||||
|
|
||||||
# 保存数据
|
# 保存数据
|
||||||
/score/dumpQuantityToFile water_box eDep eDep_1.txt
|
/score/dumpQuantityToFile water_box eDep eDep_1.txt
|
||||||
/score/dumpQuantityToFile water_box Dose Dose_1.txt
|
/score/dumpQuantityToFile water_box Dose Dose_1.txt
|
||||||
|
|
||||||
# 发射粒子
|
# 发射粒子
|
||||||
/gun/particle gamma
|
/gun/particle gamma
|
||||||
/gun/energy 5 MeV
|
/gun/energy 5 MeV
|
||||||
/run/beamOn 100000
|
/run/beamOn 100000
|
||||||
|
|
||||||
# 保存数据
|
# 保存数据
|
||||||
/score/dumpQuantityToFile water_box eDep eDep_5.txt
|
/score/dumpQuantityToFile water_box eDep eDep_5.txt
|
||||||
/score/dumpQuantityToFile water_box Dose Dose_5.txt
|
/score/dumpQuantityToFile water_box Dose Dose_5.txt
|
||||||
|
|
||||||
# 发射粒子
|
# 发射粒子
|
||||||
/gun/particle gamma
|
/gun/particle gamma
|
||||||
/gun/energy 10 MeV
|
/gun/energy 10 MeV
|
||||||
/run/beamOn 100000
|
/run/beamOn 100000
|
||||||
|
|
||||||
# 保存数据
|
# 保存数据
|
||||||
/score/dumpQuantityToFile water_box eDep eDep_10.txt
|
/score/dumpQuantityToFile water_box eDep eDep_10.txt
|
||||||
/score/dumpQuantityToFile water_box Dose Dose_10.txt
|
/score/dumpQuantityToFile water_box Dose Dose_10.txt
|
||||||
|
|
|
@ -1,15 +1,15 @@
|
||||||
#ifndef B0ActionInitialization_h
|
#ifndef B0ActionInitialization_h
|
||||||
#define B0ActionInitialization_h
|
#define B0ActionInitialization_h
|
||||||
|
|
||||||
#include "G4VUserActionInitialization.hh"
|
#include "G4VUserActionInitialization.hh"
|
||||||
|
|
||||||
class ActionInitialization : public G4VUserActionInitialization {
|
class ActionInitialization : public G4VUserActionInitialization {
|
||||||
public:
|
public:
|
||||||
ActionInitialization();
|
ActionInitialization();
|
||||||
~ActionInitialization() override;
|
~ActionInitialization() override;
|
||||||
|
|
||||||
void BuildForMaster() const override;
|
void BuildForMaster() const override;
|
||||||
void Build() const override;
|
void Build() const override;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
|
@ -1,18 +1,18 @@
|
||||||
#ifndef B0DetectorConstruction_h
|
#ifndef B0DetectorConstruction_h
|
||||||
#define B0DetectorConstruction_h
|
#define B0DetectorConstruction_h
|
||||||
|
|
||||||
#include "G4VUserDetectorConstruction.hh"
|
#include "G4VUserDetectorConstruction.hh"
|
||||||
#include "globals.hh"
|
#include "globals.hh"
|
||||||
|
|
||||||
class G4VPhysicalVolume;
|
class G4VPhysicalVolume;
|
||||||
class G4LogicalVolume;
|
class G4LogicalVolume;
|
||||||
|
|
||||||
class DetectorConstruction : public G4VUserDetectorConstruction {
|
class DetectorConstruction : public G4VUserDetectorConstruction {
|
||||||
public:
|
public:
|
||||||
DetectorConstruction();
|
DetectorConstruction();
|
||||||
~DetectorConstruction() override;
|
~DetectorConstruction() override;
|
||||||
|
|
||||||
G4VPhysicalVolume* Construct() override;
|
G4VPhysicalVolume* Construct() override;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,21 +1,21 @@
|
||||||
#ifndef B0EventAction_h
|
#ifndef B0EventAction_h
|
||||||
#define B0EventAction_h
|
#define B0EventAction_h
|
||||||
|
|
||||||
#include "G4UserEventAction.hh"
|
#include "G4UserEventAction.hh"
|
||||||
#include "globals.hh"
|
#include "globals.hh"
|
||||||
|
|
||||||
class RunAction;
|
class RunAction;
|
||||||
|
|
||||||
class EventAction : public G4UserEventAction {
|
class EventAction : public G4UserEventAction {
|
||||||
public:
|
public:
|
||||||
EventAction(RunAction* r);
|
EventAction(RunAction* r);
|
||||||
~EventAction() override;
|
~EventAction() override;
|
||||||
|
|
||||||
void BeginOfEventAction(const G4Event*) override;
|
void BeginOfEventAction(const G4Event*) override;
|
||||||
void EndOfEventAction(const G4Event*) override;
|
void EndOfEventAction(const G4Event*) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
RunAction* fRunAction = nullptr;
|
RunAction* fRunAction = nullptr;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,23 +1,23 @@
|
||||||
#ifndef B0PrimaryGeneratorAction_h
|
#ifndef B0PrimaryGeneratorAction_h
|
||||||
#define B0PrimaryGeneratorAction_h
|
#define B0PrimaryGeneratorAction_h
|
||||||
|
|
||||||
#include "G4ParticleGun.hh"
|
#include "G4ParticleGun.hh"
|
||||||
#include "G4VUserPrimaryGeneratorAction.hh"
|
#include "G4VUserPrimaryGeneratorAction.hh"
|
||||||
#include "globals.hh"
|
#include "globals.hh"
|
||||||
|
|
||||||
class G4ParticleGun;
|
class G4ParticleGun;
|
||||||
class G4Event;
|
class G4Event;
|
||||||
class G4Box;
|
class G4Box;
|
||||||
|
|
||||||
class PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction {
|
class PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction {
|
||||||
public:
|
public:
|
||||||
PrimaryGeneratorAction();
|
PrimaryGeneratorAction();
|
||||||
~PrimaryGeneratorAction();
|
~PrimaryGeneratorAction();
|
||||||
virtual void GeneratePrimaries(G4Event*);
|
virtual void GeneratePrimaries(G4Event*);
|
||||||
const G4ParticleGun* GetParticleGun() const { return fParticleGun; }
|
const G4ParticleGun* GetParticleGun() const { return fParticleGun; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
G4ParticleGun* fParticleGun;
|
G4ParticleGun* fParticleGun;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,19 +1,19 @@
|
||||||
#ifndef B0RunAction_h
|
#ifndef B0RunAction_h
|
||||||
#define B0RunAction_h
|
#define B0RunAction_h
|
||||||
|
|
||||||
#include "G4Accumulable.hh"
|
#include "G4Accumulable.hh"
|
||||||
#include "G4UserRunAction.hh"
|
#include "G4UserRunAction.hh"
|
||||||
#include "globals.hh"
|
#include "globals.hh"
|
||||||
|
|
||||||
class G4Run;
|
class G4Run;
|
||||||
|
|
||||||
class RunAction : public G4UserRunAction {
|
class RunAction : public G4UserRunAction {
|
||||||
public:
|
public:
|
||||||
RunAction();
|
RunAction();
|
||||||
~RunAction() override;
|
~RunAction() override;
|
||||||
|
|
||||||
void BeginOfRunAction(const G4Run*) override;
|
void BeginOfRunAction(const G4Run*) override;
|
||||||
void EndOfRunAction(const G4Run*) override;
|
void EndOfRunAction(const G4Run*) override;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,21 +1,21 @@
|
||||||
#ifndef B0SteppingAction_h
|
#ifndef B0SteppingAction_h
|
||||||
#define B0SteppingAction_h
|
#define B0SteppingAction_h
|
||||||
|
|
||||||
#include "G4UserSteppingAction.hh"
|
#include "G4UserSteppingAction.hh"
|
||||||
#include "globals.hh"
|
#include "globals.hh"
|
||||||
|
|
||||||
class G4LogicalVolume;
|
class G4LogicalVolume;
|
||||||
class EventAction;
|
class EventAction;
|
||||||
|
|
||||||
class SteppingAction : public G4UserSteppingAction {
|
class SteppingAction : public G4UserSteppingAction {
|
||||||
public:
|
public:
|
||||||
SteppingAction(EventAction* e);
|
SteppingAction(EventAction* e);
|
||||||
~SteppingAction() override;
|
~SteppingAction() override;
|
||||||
|
|
||||||
void UserSteppingAction(const G4Step*) override;
|
void UserSteppingAction(const G4Step*) override;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
EventAction* fEventAction = nullptr;
|
EventAction* fEventAction = nullptr;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
74
main.cpp
74
main.cpp
|
@ -1,38 +1,38 @@
|
||||||
#include "ActionInitialization.h"
|
#include "ActionInitialization.h"
|
||||||
#include "DetectorConstruction.h"
|
#include "DetectorConstruction.h"
|
||||||
#include "G4MTRunManager.hh"
|
#include "G4MTRunManager.hh"
|
||||||
#include "G4ScoringManager.hh"
|
#include "G4ScoringManager.hh"
|
||||||
#include "G4UIExecutive.hh"
|
#include "G4UIExecutive.hh"
|
||||||
#include "G4UImanager.hh"
|
#include "G4UImanager.hh"
|
||||||
#include "G4VisExecutive.hh"
|
#include "G4VisExecutive.hh"
|
||||||
#include "PrimaryGeneratorAction.h"
|
#include "PrimaryGeneratorAction.h"
|
||||||
#include "QBBC.hh"
|
#include "QBBC.hh"
|
||||||
|
|
||||||
int main(int argc, char** argv) {
|
int main(int argc, char** argv) {
|
||||||
G4UIExecutive* ui = nullptr;
|
G4UIExecutive* ui = nullptr;
|
||||||
if (argc == 1) ui = new G4UIExecutive(argc, argv);
|
if (argc == 1) ui = new G4UIExecutive(argc, argv);
|
||||||
|
|
||||||
G4MTRunManager* runManager = new G4MTRunManager;
|
G4MTRunManager* runManager = new G4MTRunManager;
|
||||||
G4VisExecutive* visManager = new G4VisExecutive;
|
G4VisExecutive* visManager = new G4VisExecutive;
|
||||||
G4UImanager* UIManager = G4UImanager::GetUIpointer();
|
G4UImanager* UIManager = G4UImanager::GetUIpointer();
|
||||||
G4ScoringManager::GetScoringManager();
|
G4ScoringManager::GetScoringManager();
|
||||||
|
|
||||||
runManager->SetUserInitialization(new DetectorConstruction());
|
runManager->SetUserInitialization(new DetectorConstruction());
|
||||||
runManager->SetUserInitialization(new QBBC);
|
runManager->SetUserInitialization(new QBBC);
|
||||||
runManager->SetUserInitialization(new ActionInitialization());
|
runManager->SetUserInitialization(new ActionInitialization());
|
||||||
|
|
||||||
visManager->Initialize();
|
visManager->Initialize();
|
||||||
if (!ui) {
|
if (!ui) {
|
||||||
G4String command = "/control/execute ";
|
G4String command = "/control/execute ";
|
||||||
G4String fileName = argv[1];
|
G4String fileName = argv[1];
|
||||||
UIManager->ApplyCommand(command + fileName);
|
UIManager->ApplyCommand(command + fileName);
|
||||||
} else {
|
} else {
|
||||||
UIManager->ApplyCommand("/control/execute vis.mac");
|
UIManager->ApplyCommand("/control/execute vis.mac");
|
||||||
ui->SessionStart();
|
ui->SessionStart();
|
||||||
delete ui;
|
delete ui;
|
||||||
}
|
}
|
||||||
|
|
||||||
delete runManager;
|
delete runManager;
|
||||||
delete visManager;
|
delete visManager;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
|
@ -1,27 +1,27 @@
|
||||||
#include "ActionInitialization.h"
|
#include "ActionInitialization.h"
|
||||||
|
|
||||||
#include "EventAction.h"
|
#include "EventAction.h"
|
||||||
#include "PrimaryGeneratorAction.h"
|
#include "PrimaryGeneratorAction.h"
|
||||||
#include "RunAction.h"
|
#include "RunAction.h"
|
||||||
#include "SteppingAction.h"
|
#include "SteppingAction.h"
|
||||||
|
|
||||||
ActionInitialization::ActionInitialization() {}
|
ActionInitialization::ActionInitialization() {}
|
||||||
|
|
||||||
ActionInitialization::~ActionInitialization() {}
|
ActionInitialization::~ActionInitialization() {}
|
||||||
|
|
||||||
void ActionInitialization::BuildForMaster() const {
|
void ActionInitialization::BuildForMaster() const {
|
||||||
RunAction* runAction = new RunAction;
|
RunAction* runAction = new RunAction;
|
||||||
SetUserAction(runAction);
|
SetUserAction(runAction);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ActionInitialization::Build() const {
|
void ActionInitialization::Build() const {
|
||||||
SetUserAction(new PrimaryGeneratorAction);
|
SetUserAction(new PrimaryGeneratorAction);
|
||||||
|
|
||||||
RunAction* runAction = new RunAction;
|
RunAction* runAction = new RunAction;
|
||||||
SetUserAction(runAction);
|
SetUserAction(runAction);
|
||||||
|
|
||||||
EventAction* eventAction = new EventAction(runAction);
|
EventAction* eventAction = new EventAction(runAction);
|
||||||
SetUserAction(eventAction);
|
SetUserAction(eventAction);
|
||||||
|
|
||||||
SetUserAction(new SteppingAction(eventAction));
|
SetUserAction(new SteppingAction(eventAction));
|
||||||
}
|
}
|
|
@ -1,22 +1,22 @@
|
||||||
#include "DetectorConstruction.h"
|
#include "DetectorConstruction.h"
|
||||||
|
|
||||||
#include "G4Box.hh"
|
#include "G4Box.hh"
|
||||||
#include "G4LogicalVolume.hh"
|
#include "G4LogicalVolume.hh"
|
||||||
#include "G4NistManager.hh"
|
#include "G4NistManager.hh"
|
||||||
#include "G4PVPlacement.hh"
|
#include "G4PVPlacement.hh"
|
||||||
#include "G4SystemOfUnits.hh"
|
#include "G4SystemOfUnits.hh"
|
||||||
|
|
||||||
DetectorConstruction::DetectorConstruction() {}
|
DetectorConstruction::DetectorConstruction() {}
|
||||||
|
|
||||||
DetectorConstruction::~DetectorConstruction() {}
|
DetectorConstruction::~DetectorConstruction() {}
|
||||||
|
|
||||||
G4VPhysicalVolume* DetectorConstruction::Construct() {
|
G4VPhysicalVolume* DetectorConstruction::Construct() {
|
||||||
G4NistManager* nist = G4NistManager::Instance();
|
G4NistManager* nist = G4NistManager::Instance();
|
||||||
|
|
||||||
G4Box* solid_world = new G4Box("world", 638 / 2 * mm, 630 / 2 * mm, 555. / 2 * mm);
|
G4Box* solid_world = new G4Box("world", 638 / 2 * mm, 630 / 2 * mm, 555. / 2 * mm);
|
||||||
G4LogicalVolume* logic_world = new G4LogicalVolume(solid_world, nist->FindOrBuildMaterial("G4_WATER"), "world");
|
G4LogicalVolume* logic_world = new G4LogicalVolume(solid_world, nist->FindOrBuildMaterial("G4_WATER"), "world");
|
||||||
G4VPhysicalVolume* physics_world =
|
G4VPhysicalVolume* physics_world =
|
||||||
new G4PVPlacement(0, G4ThreeVector(0, 0, 0), logic_world, "world", 0, false, 0, true);
|
new G4PVPlacement(0, G4ThreeVector(0, 0, 0), logic_world, "world", 0, false, 0, true);
|
||||||
|
|
||||||
return physics_world;
|
return physics_world;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,13 +1,13 @@
|
||||||
#include "EventAction.h"
|
#include "EventAction.h"
|
||||||
|
|
||||||
#include "G4Event.hh"
|
#include "G4Event.hh"
|
||||||
#include "G4RunManager.hh"
|
#include "G4RunManager.hh"
|
||||||
#include "RunAction.h"
|
#include "RunAction.h"
|
||||||
|
|
||||||
EventAction::EventAction(RunAction* r) : fRunAction(r) {}
|
EventAction::EventAction(RunAction* r) : fRunAction(r) {}
|
||||||
|
|
||||||
EventAction::~EventAction() {}
|
EventAction::~EventAction() {}
|
||||||
|
|
||||||
void EventAction::BeginOfEventAction(const G4Event* event) { }
|
void EventAction::BeginOfEventAction(const G4Event* event) { }
|
||||||
|
|
||||||
void EventAction::EndOfEventAction(const G4Event* event) { }
|
void EventAction::EndOfEventAction(const G4Event* event) { }
|
||||||
|
|
|
@ -1,18 +1,18 @@
|
||||||
#include "PrimaryGeneratorAction.h"
|
#include "PrimaryGeneratorAction.h"
|
||||||
|
|
||||||
#include "G4ParticleTable.hh"
|
#include "G4ParticleTable.hh"
|
||||||
#include "G4SystemOfUnits.hh"
|
#include "G4SystemOfUnits.hh"
|
||||||
|
|
||||||
PrimaryGeneratorAction::PrimaryGeneratorAction() {
|
PrimaryGeneratorAction::PrimaryGeneratorAction() {
|
||||||
auto table = G4ParticleTable::GetParticleTable();
|
auto table = G4ParticleTable::GetParticleTable();
|
||||||
|
|
||||||
fParticleGun = new G4ParticleGun(1);
|
fParticleGun = new G4ParticleGun(1);
|
||||||
fParticleGun->SetParticleDefinition(table->FindParticle("gamma"));
|
fParticleGun->SetParticleDefinition(table->FindParticle("gamma"));
|
||||||
fParticleGun->SetParticlePosition(G4ThreeVector(0, 0, 555. / 2 * mm));
|
fParticleGun->SetParticlePosition(G4ThreeVector(0, 0, 555. / 2 * mm));
|
||||||
fParticleGun->SetParticleMomentumDirection(G4ThreeVector(0, 0, -1));
|
fParticleGun->SetParticleMomentumDirection(G4ThreeVector(0, 0, -1));
|
||||||
fParticleGun->SetParticleEnergy(1 * MeV);
|
fParticleGun->SetParticleEnergy(1 * MeV);
|
||||||
}
|
}
|
||||||
|
|
||||||
PrimaryGeneratorAction::~PrimaryGeneratorAction() { delete fParticleGun; }
|
PrimaryGeneratorAction::~PrimaryGeneratorAction() { delete fParticleGun; }
|
||||||
|
|
||||||
void PrimaryGeneratorAction::GeneratePrimaries(G4Event* e) { fParticleGun->GeneratePrimaryVertex(e); }
|
void PrimaryGeneratorAction::GeneratePrimaries(G4Event* e) { fParticleGun->GeneratePrimaryVertex(e); }
|
||||||
|
|
|
@ -1,22 +1,22 @@
|
||||||
#include "RunAction.h"
|
#include "RunAction.h"
|
||||||
|
|
||||||
#include "DetectorConstruction.h"
|
#include "DetectorConstruction.h"
|
||||||
#include "G4AccumulableManager.hh"
|
#include "G4AccumulableManager.hh"
|
||||||
#include "G4LogicalVolume.hh"
|
#include "G4LogicalVolume.hh"
|
||||||
#include "G4LogicalVolumeStore.hh"
|
#include "G4LogicalVolumeStore.hh"
|
||||||
#include "G4Run.hh"
|
#include "G4Run.hh"
|
||||||
#include "G4RunManager.hh"
|
#include "G4RunManager.hh"
|
||||||
#include "G4SystemOfUnits.hh"
|
#include "G4SystemOfUnits.hh"
|
||||||
#include "G4UnitsTable.hh"
|
#include "G4UnitsTable.hh"
|
||||||
#include "PrimaryGeneratorAction.h"
|
#include "PrimaryGeneratorAction.h"
|
||||||
|
|
||||||
RunAction::RunAction() {
|
RunAction::RunAction() {
|
||||||
}
|
}
|
||||||
|
|
||||||
RunAction::~RunAction() {}
|
RunAction::~RunAction() {}
|
||||||
|
|
||||||
void RunAction::BeginOfRunAction(const G4Run*) {
|
void RunAction::BeginOfRunAction(const G4Run*) {
|
||||||
}
|
}
|
||||||
|
|
||||||
void RunAction::EndOfRunAction(const G4Run* run) {
|
void RunAction::EndOfRunAction(const G4Run* run) {
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,15 +1,15 @@
|
||||||
#include "SteppingAction.h"
|
#include "SteppingAction.h"
|
||||||
#include "DetectorConstruction.h"
|
#include "DetectorConstruction.h"
|
||||||
#include "EventAction.h"
|
#include "EventAction.h"
|
||||||
|
|
||||||
#include "G4Event.hh"
|
#include "G4Event.hh"
|
||||||
#include "G4LogicalVolume.hh"
|
#include "G4LogicalVolume.hh"
|
||||||
#include "G4RunManager.hh"
|
#include "G4RunManager.hh"
|
||||||
#include "G4Step.hh"
|
#include "G4Step.hh"
|
||||||
|
|
||||||
SteppingAction::SteppingAction(EventAction* e) : fEventAction(e) {}
|
SteppingAction::SteppingAction(EventAction* e) : fEventAction(e) {}
|
||||||
|
|
||||||
SteppingAction::~SteppingAction() {}
|
SteppingAction::~SteppingAction() {}
|
||||||
|
|
||||||
void SteppingAction::UserSteppingAction(const G4Step* step) {
|
void SteppingAction::UserSteppingAction(const G4Step* step) {
|
||||||
}
|
}
|
||||||
|
|
78
vis.mac
78
vis.mac
|
@ -1,40 +1,40 @@
|
||||||
# 多线程设置
|
# 多线程设置
|
||||||
/run/numberOfThreads 4
|
/run/numberOfThreads 4
|
||||||
|
|
||||||
# verbose
|
# verbose
|
||||||
/control/saveHistory
|
/control/saveHistory
|
||||||
/control/verbose 2
|
/control/verbose 2
|
||||||
/run/verbose 1
|
/run/verbose 1
|
||||||
/event/verbose 0
|
/event/verbose 0
|
||||||
/tracking/verbose 0
|
/tracking/verbose 0
|
||||||
|
|
||||||
# 初始化
|
# 初始化
|
||||||
/run/initialize
|
/run/initialize
|
||||||
|
|
||||||
# 设置视图,使用OpenGL
|
# 设置视图,使用OpenGL
|
||||||
/vis/open OGL 800x800-0+0
|
/vis/open OGL 800x800-0+0
|
||||||
|
|
||||||
# 禁止自动刷新,消息静音(除错误外)
|
# 禁止自动刷新,消息静音(除错误外)
|
||||||
/vis/viewer/set/autoRefresh false
|
/vis/viewer/set/autoRefresh false
|
||||||
/vis/verbose errors
|
/vis/verbose errors
|
||||||
|
|
||||||
# 绘制几何体
|
# 绘制几何体
|
||||||
/vis/drawVolume
|
/vis/drawVolume
|
||||||
|
|
||||||
# 绘制轨迹 类型为平滑
|
# 绘制轨迹 类型为平滑
|
||||||
/vis/scene/add/trajectories smooth
|
/vis/scene/add/trajectories smooth
|
||||||
# 根据粒子ID进行绘制
|
# 根据粒子ID进行绘制
|
||||||
/vis/modeling/trajectories/create/drawByParticleID
|
/vis/modeling/trajectories/create/drawByParticleID
|
||||||
# 以2px的宽度绘制节点
|
# 以2px的宽度绘制节点
|
||||||
/vis/modeling/trajectories/drawByParticleID-0/default/setDrawStepPts true
|
/vis/modeling/trajectories/drawByParticleID-0/default/setDrawStepPts true
|
||||||
/vis/modeling/trajectories/drawByParticleID-0/default/setStepPtsSize 2
|
/vis/modeling/trajectories/drawByParticleID-0/default/setStepPtsSize 2
|
||||||
# 保留、叠加所有事例
|
# 保留、叠加所有事例
|
||||||
/vis/scene/endOfEventAction accumulate
|
/vis/scene/endOfEventAction accumulate
|
||||||
|
|
||||||
# 设置颜色
|
# 设置颜色
|
||||||
/vis/geometry/set/colour world 0 0 0 1 .3
|
/vis/geometry/set/colour world 0 0 0 1 .3
|
||||||
/vis/viewer/set/style surface
|
/vis/viewer/set/style surface
|
||||||
|
|
||||||
# 坐标轴
|
# 坐标轴
|
||||||
/vis/scene/add/scale # Simple scale line
|
/vis/scene/add/scale # Simple scale line
|
||||||
/vis/scene/add/axes # Simple axes: x=red, y=green, z=blue.
|
/vis/scene/add/axes # Simple axes: x=red, y=green, z=blue.
|
Loading…
Reference in New Issue