mirror of
https://github.com/DarklightGames/io_scene_psk_psa.git
synced 2024-11-15 10:47:39 +01:00
Fixed a bug in get_nla_strips_in_timeframe
This commit is contained in:
parent
15b27ac4d6
commit
bcf5117bae
@ -27,7 +27,9 @@ def get_nla_strips_in_timeframe(object, frame_min, frame_max) -> List[NlaStrip]:
|
||||
strips = []
|
||||
for nla_track in object.animation_data.nla_tracks:
|
||||
for strip in nla_track.strips:
|
||||
if strip.frame_start >= frame_min and strip.frame_end <= frame_max:
|
||||
if (strip.frame_start < frame_min and strip.frame_end > frame_max) or \
|
||||
(frame_min <= strip.frame_start < frame_max) or \
|
||||
(frame_min < strip.frame_end <= frame_max):
|
||||
strips.append(strip)
|
||||
return strips
|
||||
|
||||
|
@ -119,6 +119,7 @@ class PsaBuilder(object):
|
||||
pass
|
||||
elif options.sequence_source == 'TIMELINE_MARKERS':
|
||||
sequence_frame_ranges = self.get_timeline_marker_sequence_frame_ranges(armature, context, options)
|
||||
|
||||
for name, (frame_min, frame_max) in sequence_frame_ranges.items():
|
||||
export_sequence = ExportSequence()
|
||||
export_sequence.action = None
|
||||
@ -142,9 +143,10 @@ class PsaBuilder(object):
|
||||
|
||||
frame_min = export_sequence.frame_min
|
||||
frame_max = export_sequence.frame_max
|
||||
frame_count = frame_max - frame_min + 1
|
||||
|
||||
psa_sequence.name = bytes(export_sequence.name, encoding='windows-1252')
|
||||
psa_sequence.frame_count = frame_max - frame_min + 1
|
||||
psa_sequence.frame_count = frame_count
|
||||
psa_sequence.frame_start_index = frame_start_index
|
||||
psa_sequence.fps = context.scene.render.fps
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user