Skip to content

Commit

Permalink
Bug fix: EDL transition cut event references A side
Browse files Browse the repository at this point in the history
  • Loading branch information
mikemahony committed Jan 2, 2018
1 parent 1c29e0a commit eae42b1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions opentimelineio/adapters/cmx_3600.py
Original file line number Diff line number Diff line change
Expand Up @@ -629,7 +629,7 @@ def write_to_string(input_otio, rate=None, style='avid'):
# |---------|
# 100

# Event line to represent this "shorted" A side
# Event line to represent this "shorter" A side
a_side_line = EventLine(
kind=kind,
edit_number=edit_number,
Expand Down Expand Up @@ -680,7 +680,7 @@ def write_to_string(input_otio, rate=None, style='avid'):
edit_number=edit_number,
rate=edl_rate
)
cut_line.reel = b_side_line.reel
cut_line.reel = a_side_line.reel
cut_line.source_in = a_side_line.source_out
cut_line.source_out = a_side_line.source_out
cut_line.record_in = a_side_line.record_out
Expand Down
8 changes: 4 additions & 4 deletions tests/test_cmx_3600_adapter.py
Original file line number Diff line number Diff line change
Expand Up @@ -393,6 +393,7 @@ def test_nucoda_edl_write_with_transition(self):
)

cl = otio.schema.Clip(
metadata={'cmx_3600': {'reel': 'Reel1'}},
source_range=otio.opentime.TimeRange(
start_time=otio.opentime.RationalTime(131.0, 24.0),
duration=otio.opentime.RationalTime(102.0, 24.0)
Expand All @@ -403,21 +404,20 @@ def test_nucoda_edl_write_with_transition(self):
out_offset=otio.opentime.RationalTime(43.0, 24.0)
)
cl2 = otio.schema.Clip(
metadata={'cmx_3600': {'reel': 'Reel2'}},
source_range=otio.opentime.TimeRange(
start_time=otio.opentime.RationalTime(280.0, 24.0),
duration=otio.opentime.RationalTime(143.0, 24.0)
)
)
cl3 = otio.schema.Clip(
metadata={'cmx_3600': {'reel': 'Reel3'}},
source_range=otio.opentime.TimeRange(
start_time=otio.opentime.RationalTime(0.0, 24.0),
duration=otio.opentime.RationalTime(24.0, 24.0)
)
)
tl.tracks[0].append(cl)
tl.tracks[0].append(trans)
tl.tracks[0].append(cl2)
tl.tracks[0].append(cl3)
tl.tracks[0].extend([cl, trans, cl2, cl3])

result = otio.adapters.write_to_string(
tl,
Expand Down

0 comments on commit eae42b1

Please sign in to comment.