Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
BornAgain
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mlz
BornAgain
Commits
6247a642
Commit
6247a642
authored
3 years ago
by
Matthias Puchner
Browse files
Options
Downloads
Patches
Plain Diff
make private where possible
parent
f11d8338
No related branches found
No related tags found
1 merge request
!570
remove SessionModel/Item from SampleModel and all related items
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
GUI/View/Realspace/RealSpaceBuilder.h
+5
-3
5 additions, 3 deletions
GUI/View/Realspace/RealSpaceBuilder.h
GUI/View/Realspace/TransformTo3D.cpp
+1
-20
1 addition, 20 deletions
GUI/View/Realspace/TransformTo3D.cpp
with
6 additions
and
23 deletions
GUI/View/Realspace/RealSpaceBuilder.h
+
5
−
3
View file @
6247a642
...
...
@@ -51,6 +51,11 @@ public:
RealSpace
::
Vector3D
::
_z
))
// up
const
;
void
populateParticleFromParticle3DContainer
(
RealSpace
::
Model
*
model
,
const
Particle3DContainer
&
particle3DContainer
,
const
QVector3D
&
lattice_position
=
{})
const
;
private
:
void
populateMultiLayer
(
RealSpace
::
Model
*
model
,
const
MultiLayerItem
&
mlayerItem
,
const
SceneGeometry
&
sceneGeometry
,
const
QVector3D
&
origin
=
{})
const
;
...
...
@@ -64,9 +69,6 @@ public:
void
populateParticleFromParticleItem
(
RealSpace
::
Model
*
model
,
const
ItemWithParticles
&
particleItem
)
const
;
void
populateParticleFromParticle3DContainer
(
RealSpace
::
Model
*
model
,
const
Particle3DContainer
&
particle3DContainer
,
const
QVector3D
&
lattice_position
=
{})
const
;
private
:
std
::
unique_ptr
<
RealSpace
::
BuilderUtils
>
m_builderUtils
;
...
...
This diff is collapsed.
Click to expand it.
GUI/View/Realspace/TransformTo3D.cpp
+
1
−
20
View file @
6247a642
...
...
@@ -20,31 +20,12 @@
#include
"GUI/View/Realspace/RealSpaceCanvas.h"
#include
"Sample/HardParticle/HardParticles.h"
#include
<boost/polymorphic_cast.hpp>
using
boost
::
polymorphic_downcast
;
namespace
{
bool
isTopLayer
(
const
LayerItem
&
layerItem
)
{
auto
layers
=
polymorphic_downcast
<
MultiLayerItem
*>
(
layerItem
.
parent
())
->
layers
();
return
layers
.
indexOf
(
const_cast
<
LayerItem
*>
(
&
layerItem
))
==
0
;
}
bool
isBottomLayer
(
const
LayerItem
&
layerItem
)
{
auto
layers
=
polymorphic_downcast
<
MultiLayerItem
*>
(
layerItem
.
parent
())
->
layers
();
return
layers
.
indexOf
(
const_cast
<
LayerItem
*>
(
&
layerItem
))
==
layers
.
size
()
-
1
;
}
}
// namespace
double
GUI
::
View
::
TransformTo3D
::
visualLayerThickness
(
const
LayerItem
&
layerItem
,
const
SceneGeometry
&
sceneGeometry
)
{
double
thickness
(
0.0
);
if
(
isTopLayer
(
layerItem
)
||
isBottomLayer
(
layerItem
))
if
(
layerItem
.
isTopLayer
(
)
||
layerItem
.
isBottomLayer
())
thickness
=
sceneGeometry
.
topOrBottomLayerThickness
;
else
thickness
=
layerItem
.
thickness
();
...
...
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