Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
docking
ocladock-fpga
Commits
b66fe92e
Commit
b66fe92e
authored
Nov 11, 2018
by
Leonardo Solis
Browse files
#30, corrected ligand branch read (ignored 2nd atom index in BRANCH keyword)
Former-commit-id:
4dcd8a10
parent
76c945d9
Changes
1
Hide whitespace changes
Inline
Side-by-side
ofdock_taskpar_xl/host/src/processligand.cpp
View file @
b66fe92e
...
...
@@ -735,11 +735,8 @@ int get_liganddata(const char* ligfilename, Liganddata* myligand, const double A
if
((
strcmp
(
tempstr
,
"HETATM"
)
==
0
)
||
(
strcmp
(
tempstr
,
"ATOM"
)
==
0
))
//if new atom, looking for open rotatable bonds
{
for
(
i
=
0
;
i
<
branch_counter
;
i
++
)
//for all branches found until now
if
(
branches
[
i
][
2
]
==
0
)
//in this case the rotatable bond is not open yet (this atom hasn't
branches
[
i
][
2
]
=
1
;
//to be rotated, but the next has to), so let's make it open
else
if
(
branches
[
i
][
2
]
==
1
)
//if it is open, the atom has to be rotated
atom_rotbonds_temp
[
atom_counter
][
i
]
=
1
;
//modifying atom_rotbonds_temp
if
(
branches
[
i
][
2
]
==
1
)
//if it is open, the atom has to be rotated
atom_rotbonds_temp
[
atom_counter
][
i
]
=
1
;
//modifying atom_rotbonds_temp
/*else it is 2, so it is closed, so nothing to be done...*/
myligand
->
atom_rigid_structures
[
atom_counter
]
=
current_rigid_struct_id
;
//using the id of the current rigid structure
...
...
@@ -768,9 +765,8 @@ int get_liganddata(const char* ligfilename, Liganddata* myligand, const double A
fscanf
(
fp
,
"%d"
,
&
(
branches
[
branch_counter
][
1
]));
(
branches
[
branch_counter
][
0
])
--
;
//atom IDs start from 0 instead of 1
(
branches
[
branch_counter
][
1
])
--
;
branches
[
branch_counter
][
2
]
=
0
;
//0 indicates, that the next atom that will be found in the file
//hasn't to be rotated around this bond (it is the bond's atom),
//so the branch is not open yet
branches
[
branch_counter
][
2
]
=
1
;
// 1 means the branch is open, atoms will be rotated
branch_counter
++
;
reserved_highest_rigid_struct_id
++
;
//next ID is reserved
...
...
Write
Preview
Supports
Markdown
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