Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
L
libcifpp
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
open
libcifpp
Commits
492a1ad8
Unverified
Commit
492a1ad8
authored
Mar 08, 2021
by
Maarten L. Hekkelman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
LINK distance
parent
71da0ce3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
src/PDB2Cif.cpp
+4
-4
No files found.
src/PDB2Cif.cpp
View file @
492a1ad8
...
...
@@ -5787,6 +5787,8 @@ void PDBFileParser::Parse(std::istream& is, cif::File& result)
{
"ptnr1_label_asym_id"
,
"ptnr1_label_seq_id"
,
"ptnr1_label_atom_id"
,
"ptnr1_symmetry"
,
"ptnr2_label_asym_id"
,
"ptnr2_label_seq_id"
,
"ptnr2_label_atom_id"
,
"ptnr2_symmetry"
});
float
distance
=
1.0
f
;
try
{
auto
a1
=
atom_site
.
find1
(
"label_asym_id"
_key
==
asym1
and
"label_seq_id"
_key
==
seq1
and
"label_atom_id"
_key
==
atom1
);
...
...
@@ -5795,20 +5797,18 @@ void PDBFileParser::Parse(std::istream& is, cif::File& result)
const
auto
&
[
x1
,
y1
,
z1
]
=
a1
.
get
<
float
,
float
,
float
>
({
"cartn_x"
,
"cartn_y"
,
"cartn_z"
});
const
auto
&
[
x2
,
y2
,
z2
]
=
a2
.
get
<
float
,
float
,
float
>
({
"cartn_x"
,
"cartn_y"
,
"cartn_z"
});
float
distance
=
1.0
f
;
if
(
symm1
==
"1_555"
and
symm2
==
"1_555"
)
distance
=
mmcif
::
Distance
(
mmcif
::
Point
{
x1
,
y1
,
z1
},
mmcif
::
Point
{
x2
,
y2
,
z2
});
else
if
(
cif
::
VERBOSE
)
std
::
cerr
<<
"Cannot calculate distance for link since one of the atoms is in another dimension"
<<
std
::
endl
;
r
[
"pdbx_dist_value"
]
=
distance
;
}
catch
(
std
::
exception
&
ex
)
{
if
(
cif
::
VERBOSE
)
std
::
cerr
<<
"Error finding atom: "
<<
ex
.
what
()
<<
std
::
endl
;
}
r
[
"pdbx_dist_value"
]
=
distance
;
}
}
catch
(
const
std
::
exception
&
ex
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment