Skip to content

Conversation

ssteinbach
Copy link
Collaborator

@ssteinbach ssteinbach commented Jul 17, 2019

This PR replaces the pure-python core of OpenTimelineIO with python wrapped C++. The functionality should be the same. There are some differences:

  • RationalTime enforces float types for its values. Serialized otio files will see a lot of .0s added if files are compared before/after this change.
  • the Name field defaults to "" instead of None
  • The .metadata dictionaries are of type AnyDictionary, so OrderedDicts and other similar classes will lose their type when being added to the metadata immediately (instead of being lost on serialization).
  • There is no longer a .children attribute on container classes.
  • The tox.ini file was collapsed into the setup.cfg file, along with some tuning of the lint settings.

Note that the C++ core does not include support for any of the plugins. Those are still entirely implemented in python. Non-plugin features are present in C++:

  • Reading/writing .otio files
  • Iterating over objects
  • Manipulating OTIO objects

Much like the core python project, the C++ is split into two libraries: opentime for manipulating time objects, and opentimelineio, which has all the functionality of the OpenTimelineIO data structures.

This adds some dependencies to the project (managed through Git submodules in the src/deps directory). When you sync after this change you'll need to use the git submodule init command to sync the dependencies. These dependencies include:

  • CMake (note that pip install . should still work and invoke cmake correctly under the hood for python only users)
  • Rapidjson
  • AnyDictionary
  • Optional-lite
  • pybind11

This PR also includes some preliminary Swift bindings as well (see src/swift-opentimelineio).

Huge thanks to @davidbaraff who did the port to C++, as well as the python and swift bindings.

David Baraff and others added 30 commits April 8, 2019 14:43
added #pragma once
transactional semantics on python collection mutations
@ssteinbach ssteinbach added this to the 1.0 Release milestone Jul 17, 2019
@ssteinbach ssteinbach mentioned this pull request Jul 17, 2019
@codecov-io
Copy link

Codecov Report

Merging #540 into master will decrease coverage by 7.38%.
The diff coverage is 81.28%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #540      +/-   ##
==========================================
- Coverage   88.66%   81.28%   -7.39%     
==========================================
  Files          69       72       +3     
  Lines        7502     2731    -4771     
==========================================
- Hits         6652     2220    -4432     
+ Misses        850      511     -339
Flag Coverage Δ
#py27 81.29% <81.29%> (?)
#py36 81.29% <81.29%> (?)
#py37 81.29% <81.29%> (?)
Impacted Files Coverage Δ
src/opentimelineio/stringUtils.h 0% <0%> (ø)
src/opentimelineio/unknownSchema.h 0% <0%> (ø)
src/opentimelineio/timeline.h 100% <100%> (ø)
src/opentimelineio/track.h 100% <100%> (ø)
src/opentimelineio/marker.h 100% <100%> (ø)
src/opentimelineio/timeEffect.cpp 100% <100%> (ø)
src/opentimelineio/item.h 100% <100%> (ø)
...eio/opentimelineio-bindings/otio_anyDictionary.cpp 100% <100%> (ø)
src/opentimelineio/freezeFrame.cpp 100% <100%> (ø)
src/opentimelineio/gap.cpp 100% <100%> (ø)
... and 134 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0f9a426...ccc9b4e. Read the comment docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

10 participants