Skip to content

Marker RGB Colors#2023

Open
semagnum wants to merge 2 commits into
AcademySoftwareFoundation:mainfrom
dreamworksanimation:rgb-marker-color
Open

Marker RGB Colors#2023
semagnum wants to merge 2 commits into
AcademySoftwareFoundation:mainfrom
dreamworksanimation:rgb-marker-color

Conversation

@semagnum
Copy link
Copy Markdown
Contributor

Fixes #1873

Summarize your change.

Part of ASWF Dev Days 2026. Removes redundant Marker::Color enum and replaces it with the standard Color class recently added for metadata.

  • replace Marker::Color and its std::string _color attribute with an optional Color equivalent (defaults kept the same)
  • updates Marker to schema 3
    • adds upgrade function: if the color name matches any of the previous Marker::Color enum names, it converts it to the Color equivalent. Otherwise, it preserves the original name
    • adds a downgrade function: if the Color name matches any of the Marker::Color enum names, it renames it to the all-caps name. Otherwise, it preserves the original name
  • maps the MarkerColor Python name to use Color. We can mark the name for deprecation in the future, but I figured this would be helpful for backwards compatibility for now
  • related issue, found when updating tests: adds != operator for Color class, binds the equality functionality into Python

Reference associated tests.

  • Marker-related baseline files updated
  • updated test_marker.py tests, added a test for upgrading schema to 3
  • updated test_clip.cpp, test_clip.py, test_console.py that references marker colors

Signed-off-by: Spencer Magnusson <spencer.magnusson@dreamworks.com>
@semagnum semagnum force-pushed the rgb-marker-color branch 2 times, most recently from 78d9430 to f071e02 Compare May 18, 2026 17:55
@codecov-commenter
Copy link
Copy Markdown

codecov-commenter commented May 18, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 84.76%. Comparing base (7adfb27) to head (19736ec).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #2023      +/-   ##
==========================================
+ Coverage   84.50%   84.76%   +0.25%     
==========================================
  Files         181      181              
  Lines       13225    13263      +38     
  Branches     1202     1209       +7     
==========================================
+ Hits        11176    11242      +66     
+ Misses       1866     1838      -28     
  Partials      183      183              
Flag Coverage Δ
py-unittests 84.76% <100.00%> (+0.25%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/opentimelineio/color.h 66.66% <100.00%> (+28.20%) ⬆️
src/opentimelineio/marker.cpp 100.00% <100.00%> (ø)
src/opentimelineio/marker.h 57.14% <100.00%> (+14.28%) ⬆️
src/opentimelineio/typeRegistry.cpp 83.15% <100.00%> (+3.41%) ⬆️
...entimelineio-bindings/otio_serializableObjects.cpp 84.29% <100.00%> (+1.08%) ⬆️
...y-opentimelineio/opentimelineio/schema/__init__.py 100.00% <100.00%> (ø)
.../py-opentimelineio/opentimelineio/schema/marker.py 100.00% <100.00%> (ø)
tests/test_clip.py 98.00% <100.00%> (ø)
tests/test_console.py 95.50% <ø> (ø)
tests/test_marker.py 97.14% <100.00%> (+1.58%) ⬆️

... and 3 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@semagnum semagnum force-pushed the rgb-marker-color branch from f071e02 to 6b21be5 Compare May 18, 2026 18:04
Signed-off-by: Spencer Magnusson <spencer.magnusson@dreamworks.com>
@semagnum semagnum force-pushed the rgb-marker-color branch from 6b21be5 to 19736ec Compare May 18, 2026 20:22
@timlehr
Copy link
Copy Markdown
Contributor

timlehr commented May 20, 2026

Hey @semagnum, thank you, this is a great addition. The code looks good, but I am wondering how to best approach the release of this change, since some adapters are likely using the marker color and expecting it to be a string value. We might have to do pass over the common adapters, check where we need to do some changes.

@apetrynet can you assign the devdays26 badge on this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Marker RGB colors

4 participants