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
ae4944be
Commit
ae4944be
authored
2 months ago
by
Johannes Junggeburth
Browse files
Options
Downloads
Patches
Plain Diff
Add volumeId to the GeoChildNodeWithTrf
parent
930ed375
No related branches found
No related tags found
1 merge request
!412
Query is nothing else than a std::optional but just came earlier
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
GeoModelCore/GeoModelHelpers/GeoModelHelpers/getChildNodesWithTrf.h
+4
-2
4 additions, 2 deletions
...re/GeoModelHelpers/GeoModelHelpers/getChildNodesWithTrf.h
GeoModelCore/GeoModelHelpers/src/getChildNodesWithTrf.cxx
+4
-3
4 additions, 3 deletions
GeoModelCore/GeoModelHelpers/src/getChildNodesWithTrf.cxx
with
8 additions
and
5 deletions
GeoModelCore/GeoModelHelpers/GeoModelHelpers/getChildNodesWithTrf.h
+
4
−
2
View file @
ae4944be
...
...
@@ -7,6 +7,7 @@
#include
"GeoModelKernel/GeoVPhysVol.h"
#include
"GeoModelKernel/GeoDefinitions.h"
#include
<optional>
class
GeoVolumeCursor
;
...
...
@@ -27,9 +28,10 @@ struct GeoChildNodeWithTrf {
bool
isAlignable
{
false
};
/// @brief tag whether the physical volume is a full physVol
bool
isSensitive
{
false
};
/// @brief Identifier of the volume. If there's any and no copies are active
std
::
optional
<
int
>
volumeId
{
std
::
nullopt
};
GeoChildNodeWithTrf
()
=
default
;
GeoChildNodeWithTrf
(
GeoVolumeCursor
&
curs
);
GeoChildNodeWithTrf
(
GeoVolumeCursor
&
curs
);
};
/*** @brief Returns all direct children of a volume with their transform. Equicalent volumes can be summarized.
...
...
This diff is collapsed.
Click to expand it.
GeoModelCore/GeoModelHelpers/src/getChildNodesWithTrf.cxx
+
4
−
3
View file @
ae4944be
/*
Copyright (C) 2002-202
4
CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-202
5
CERN for the benefit of the ATLAS collaboration
*/
#include
<utility>
...
...
@@ -20,11 +20,11 @@ namespace {
volume
{
curs
.
getVolume
()},
nodeName
{
curs
.
getName
()},
isAlignable
{
curs
.
hasAlignableTransform
()},
isSensitive
{
typeid
(
*
volume
)
==
typeid
(
GeoFullPhysVol
)}
{
isSensitive
{
typeid
(
*
volume
)
==
typeid
(
GeoFullPhysVol
)},
volumeId
{
static_cast
<
const
std
::
optional
<
int
>&>
(
curs
.
getId
())}
{
//// Do not specify a node name if it's a dummy one
if
(
nodeName
==
dummyNodeName
)
{
nodeName
=
volume
->
getLogVol
()
->
getName
();
}
}
...
...
@@ -53,6 +53,7 @@ std::vector <GeoChildNodeWithTrf> getChildrenWithRef(PVConstLink physVol,
children
.
emplace_back
(
std
::
move
(
currentChild
));
}
else
if
(
prevChild
.
nCopies
==
1
)
{
++
prevChild
.
nCopies
;
prevChild
.
volumeId
=
std
::
nullopt
;
prevChild
.
inductionRule
=
prevChild
.
transform
.
inverse
()
*
currentChild
.
transform
;
}
else
if
(
!
transSort
.
compare
(
prevChild
.
inductionRule
,
...
...
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