Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
GeoModel
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
GeoModelDev
GeoModel
Commits
df227995
Commit
df227995
authored
3 years ago
by
Riccardo Maria Bianchi
Browse files
Options
Downloads
Patches
Plain Diff
Update I/O exmaple
parent
6914ca1d
Branches
Branches containing commit
Tags
Tags containing commit
1 merge request
!131
Fix duplicate volumes when reading a .db back in
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
GeoModelExamples/HelloGeoWriteReadWrite/main.cpp
+6
-4
6 additions, 4 deletions
GeoModelExamples/HelloGeoWriteReadWrite/main.cpp
with
6 additions
and
4 deletions
GeoModelExamples/HelloGeoWriteReadWrite/main.cpp
+
6
−
4
View file @
df227995
// Copyright (C) 2002-202
0
CERN for the benefit of the ATLAS collaboration
// Copyright (C) 2002-202
2
CERN for the benefit of the ATLAS collaboration
/*
* HelloGeo.cpp
* This example writes a sample geometry, reads it back in, then writes it again.
* It is meant to test the GeoModel I/O packages and methods.
*
* Author: Riccardo Maria BIANCHI @ CERN
* Created on:
Apr
, 20
19
* Created on:
May
, 20
22
*
*/
...
...
@@ -222,7 +223,8 @@ int main(int argc, char *argv[])
// Dump the tree volumes to a local file
std
::
cout
<<
"Dumping the GeoModel geometry to the DB file..."
<<
std
::
endl
;
GeoModelIO
::
WriteGeoModel
dumpGeoModelGraph3
(
db3
);
// init the GeoModel node action
world
->
exec
(
&
dumpGeoModelGraph3
);
// visit all GeoModel nodes
//world->exec(&dumpGeoModelGraph3); // visit all GeoModel nodes
dbPhys
->
exec
(
&
dumpGeoModelGraph3
);
// visit all GeoModel nodes
dumpGeoModelGraph3
.
saveToDB
();
// save to the SQlite DB file
std
::
cout
<<
"DONE. Geometry saved."
<<
std
::
endl
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment