Commit ed039bf8 authored by Jacob Durrant's avatar Jacob Durrant
Browse files

Fixed minor bug loading some trajectories.

parent 122646bb
Changes
=======
1.1.1
-----
* Fixed a bug that prevented Pyrite from loading some multi-frame PDB
trajectories. Programs such as PyMOL separate frames using ENDMDL. Previous
versions of Pyrite worked best with VMD-formatted files, which separate
frames using END only.
1.1.0
=====
-----
* Updated Pyrite version number to 1.1.0.
* Made minimal Blender requirement 2.80.
* Added `CHANGES.md` file.
* Pyrite now uses the N-panel (Sidebar) rather than the T-panel, as required
......@@ -11,11 +21,11 @@
* Minor improvements to user messages and plugin descriptions.
1.0.1
=====
-----
* Trivial updates.
1.0.0
=====
-----
* Original version.
# Pyrite 1.1.0
# Pyrite 1.1.1
## Description
......
# Pyrite 1.1.0 is a Blender addon for visualization molecular dynamics
# Pyrite 1.1.1 is a Blender addon for visualization molecular dynamics
# simulations. Copyright (C) 2018 Jacob D. Durrant
#
# This program is free software: you can redistribute it and/or modify it
......@@ -283,9 +283,6 @@ class ProcessTrajectory(BackgroundJobParentClass):
except:
pass
# Sets next frame to add
bpy.context.scene.frame_set(self.frame_index)
if self.frame_index == 0 or position_all == True:
# Set all of them.
sel = self.selection_atoms_to_keep
......@@ -295,8 +292,21 @@ class ProcessTrajectory(BackgroundJobParentClass):
self.frame_index % self.frame_stride
]
# Get all the coordinates.
coors = self.current_frame.get_coordinates()
# If the coordinates are empty, skip. This happens with some
# multi-frame PDB files that end in:
# ENDMDL
# END
if len(coors) == 0:
return
# Get the coordinates of the appropriate atoms.
coors = self.current_frame.get_coordinates()[sel]
coors = coors[sel]
# Sets next frame to add
bpy.context.scene.frame_set(self.frame_index)
# Go through and set the appropriate empty object to the associated
# coordinate.
......
# Pyrite 1.1.0 is a Blender addon for visualization molecular dynamics
# Pyrite 1.1.1 is a Blender addon for visualization molecular dynamics
# simulations. Copyright (C) 2018 Jacob D. Durrant
#
# This program is free software: you can redistribute it and/or modify it
......
# Pyrite 1.1.0 is a Blender addon for visualization molecular dynamics
# Pyrite 1.1.1 is a Blender addon for visualization molecular dynamics
# simulations. Copyright (C) 2018 Jacob D. Durrant
#
# This program is free software: you can redistribute it and/or modify it
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment