Skip to content

Commit

Permalink
[RodeoFx] cmx_3600 adapter: Support unnamed markers AcademySoftwareFo…
Browse files Browse the repository at this point in the history
  • Loading branch information
elabrosseRodeofx authored and jminor committed Oct 9, 2019
1 parent 9e4c203 commit ce13d17
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/py-opentimelineio/opentimelineio/adapters/cmx_3600.py
Expand Up @@ -454,7 +454,7 @@ def make_clip(self, comment_data):
# can handle more of them? Only real-world testing will
# determine this for sure...
m = re.match(
r'(\d\d:\d\d:\d\d:\d\d)\s+(\w*)\s+(.*)',
r'(\d\d:\d\d:\d\d:\d\d)\s+(\w*)(\s+|$)(.*)',
comment_data["locator"]
)
if m:
Expand Down Expand Up @@ -487,7 +487,7 @@ def make_clip(self, comment_data):
else:
marker.color = schema.MarkerColor.RED

marker.name = m.group(3)
marker.name = m.group(4)
clip.markers.append(marker)
else:
# TODO: Should we report this as a warning somehow?
Expand Down
2 changes: 1 addition & 1 deletion tests/sample_data/no_spaces_test.edl
Expand Up @@ -21,7 +21,7 @@ FCM: NON-DROP FRAME
*SOURCE FILE: ZZ100_507C.LAY2.01
007 ZZ100_50 V C 01:00:09:12 01:00:16:14 01:00:13:17 01:00:20:19
*FROM CLIP NAME: ZZ100_508 (LAY2)
*LOC: 01:00:15:13 GREEN CHANGE APPROVED
*LOC: 01:00:15:13 GREEN
*SOURCE FILE: ZZ100_508.LAY2.02
008 ZZ100_51 V C 01:00:13:10 01:00:19:02 01:00:20:19 01:00:26:11
*FROM CLIP NAME: ZZ100_510 (LAY1)
Expand Down
2 changes: 1 addition & 1 deletion tests/sample_data/screening_example.edl
Expand Up @@ -24,7 +24,7 @@ FCM: NON-DROP FRAME
* SOURCE FILE: ZZ100_507C.LAY2.01
007 ZZ100_50 V C 01:00:09:12 01:00:16:14 01:00:13:17 01:00:20:19
* FROM CLIP NAME: ZZ100_508 (LAY2)
* LOC: 01:00:15:13 GREEN CHANGE APPROVED
* LOC: 01:00:15:13 GREEN
* SOURCE FILE: ZZ100_508.LAY2.02

008 ZZ100_51 V C 01:00:13:10 01:00:19:02 01:00:20:19 01:00:26:11
Expand Down
3 changes: 3 additions & 0 deletions tests/test_cmx_3600_adapter.py
Expand Up @@ -103,6 +103,9 @@ def test_edl_read(self):
)
self.assertEqual(marker.color, otio.schema.MarkerColor.RED)

unnamed_marker = timeline.tracks[0][6].markers[0]
self.assertEqual(unnamed_marker.name, '')

self.assertEqual(
timeline.tracks[0][4].name,
"ZZ100_504B (LAY1)"
Expand Down

0 comments on commit ce13d17

Please sign in to comment.