Skip to content

Commit ea0588f

Browse files
authored
Merge branch 'main' into feature/stream_channel_mapping_support
2 parents 22d72a5 + 267fe4b commit ea0588f

25 files changed

Lines changed: 948 additions & 1011 deletions

CMakeLists.txt

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,20 @@
11
# FindPython's Development.Module component was added in 3.18.
22
# Require 3.18.2+ because pybind11 recommends it.
33
cmake_minimum_required(VERSION 3.18.2)
4+
# This policy CMP0177 can be removed when we upgrade to CMake >= 3.31.
5+
cmake_policy(SET CMP0177 NEW)
46

57
#------------------------------------------------------------------------------
68
# Project Metadata
79
# TODO: read this information from a configuration file, here, and in setup.py
810

9-
set(OTIO_VERSION_MAJOR "0")
10-
set(OTIO_VERSION_MINOR "19")
11-
set(OTIO_VERSION_PATCH "0")
11+
file(READ "src/opentimelineio/version.h" VERSION_H)
12+
string(REGEX MATCH "VERSION_MAJOR ([0-9]*)" _ ${VERSION_H})
13+
set(OTIO_VERSION_MAJOR ${CMAKE_MATCH_1})
14+
string(REGEX MATCH "VERSION_MINOR ([0-9]*)" _ ${VERSION_H})
15+
set(OTIO_VERSION_MINOR ${CMAKE_MATCH_1})
16+
string(REGEX MATCH "VERSION_PATCH ([0-9]*)" _ ${VERSION_H})
17+
set(OTIO_VERSION_PATCH ${CMAKE_MATCH_1})
1218
set(OTIO_VERSION ${OTIO_VERSION_MAJOR}.${OTIO_VERSION_MINOR}.${OTIO_VERSION_PATCH})
1319

1420
set(OTIO_AUTHOR "Contributors to the OpenTimelineIO project")
@@ -187,7 +193,7 @@ if(WIN32)
187193
# Windows debug builds for Python require a d in order for the module to
188194
# load. This also helps ensure that debug builds in general are matched
189195
# to the Microsoft debug CRT.
190-
set(OTIO_DEBUG_POSTFIX "d")
196+
set(OTIO_DEBUG_POSTFIX "_d")
191197
endif()
192198

193199
set_property(GLOBAL PROPERTY USE_FOLDERS ON)

MANIFEST.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
include README.md README_contrib.md CHANGELOG.md LICENSE.txt NOTICE.txt CMakeLists.txt
1+
include README.md README_contrib.md CHANGELOG.md LICENSE.txt NOTICE.txt SECURITY.md CMakeLists.txt
22
recursive-include examples *
33
recursive-include src *
44
recursive-include tests *

README.md

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -111,19 +111,17 @@ C++:
111111

112112
#include "opentimelineio/timeline.h"
113113

114-
namespace otio = opentimelineio::OPENTIMELINEIO_VERSION;
115-
116114
void
117115
main()
118116
{
119-
otio::SerializableObject::Retainer<otio::Timeline> tl(
120-
dynamic_cast<otio::Timeline*>(
121-
otio::Timeline::from_json_file("taco.otio")
117+
OTIO_NS::SerializableObject::Retainer<OTIO_NS::Timeline> tl(
118+
dynamic_cast<OTIO_NS::Timeline*>(
119+
OTIO_NS::Timeline::from_json_file("taco.otio")
122120
)
123121
);
124122
for (const auto& cl : tl->find_clips())
125123
{
126-
otio::RationalTime dur = cl->duration();
124+
OTIO_NS::RationalTime dur = cl->duration();
127125
std::cout << "Name: " << cl->name() << " [";
128126
std::cout << dur.value() << "/" << dur.rate() << "]" << std::endl;
129127
}

SECURITY.md

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
<!-- SPDX-License-Identifier: Apache-2.0 -->
2+
<!-- Copyright Contributors to the OpenTimelineIO project -->
3+
4+
# Security Policy
5+
6+
## Reporting a Vulnerability
7+
8+
If you think you've found a potential vulnerability in OpenTimelineIO, please
9+
report it by filing a GitHub [security
10+
advisory](https://github.com/AcademySoftwareFoundation/OpenTimelineIO/security/advisories/new). Alternatively, email
11+
[security@opentimeline.io](mailto:security@opentimeline.io?subject=OpenTimelineIO%20Vulnerability%20Report&body=Impact%0A_What%20is%20it,%20who%20is%20impacted_%0A%0APatches%0A_Has%20it%20been%20patched%20and%20in%20which%20version_%0A%0AWorkarounds%0A_Is%20there%20a%20way%20for%20users%20to%20fix%20or%20remediate%20without%20upgrading_%0A%0AReferences%0A_Where%20can%20users%20visit%20to%20find%20out%20more_)
12+
and provide your contact info for further private/secure discussion. If your email does not receive a prompt
13+
acknowledgement, your address may be blocked.
14+
15+
Our policy is to acknowledge the receipt of vulnerability reports
16+
within 48 hours. Our policy is to address critical security vulnerabilities
17+
rapidly and post patches within 14 days if possible.
18+
19+
## Known Vulnerabilities
20+
21+
These vulnerabilities are present in the given versions:
22+
23+
* No known vulnerabilities
24+
25+
See the [release notes](https://github.com/AcademySoftwareFoundation/OpenTimelineIO/releases) for more information.
26+
27+
## Supported Versions
28+
29+
This gives guidance about which branches are supported with patches to
30+
security vulnerabilities.
31+
32+
| Version / branch | Supported |
33+
|------------------|------------------------------------------------------------------------------------------------------------------------------------|
34+
| main | :white_check_mark: :construction: ALL fixes immediately, but this is a branch under development and may be unstable in other ways. |
35+
| 0.18.x | :white_check_mark: All fixes that can be backported without breaking compatibility. |
36+
| 0.17.x | :white_check_mark: All fixes that can be backported without breaking compatibility. |
37+
| 0.16.x | :warning: Only the most critical fixes, only if they can be easily backported. |
38+
| <= 0.15.x | :x: No longer receiving patches of any kind. |
39+
40+
41+
### Software Dependencies
42+
43+
#### OpenTimelineIO C++
44+
45+
- [Imath](https://github.com/AcademySoftwareFoundation/Imath) - Provides Vector, Matrix, and Bounding Box primitives.
46+
- [rapidjson](https://github.com/Tencent/rapidjson/) - Used in serialization/deserialization of the `.otio` JSON file format.
47+
48+
#### OpenTimelineIO Python
49+
50+
- [pybind11](https://github.com/pybind/pybind11) (only if built with Python bindings) - Used to create Python bindings for the C++ library.
51+
- [importlib_metadata](https://pypi.org/project/importlib-metadata/) - Provides backward compatability for Python 3.7.
52+
53+
Optionally, OTIOView requires:
54+
55+
- [PySide2](https://pypi.org/project/PySide2/) - on x86_64.
56+
- [PySide6](https://pypi.org/project/PySide6/) - on AArch64.

docs/tutorials/adapters.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,6 @@ To also install a curated list of additional useful adapters, use the [OpenTimel
1919
- [burnins](https://github.com/OpenTimelineIO/otio-burnins-adapter)
2020
- [cmx_3600](https://github.com/OpenTimelineIO/otio-cmx3600-adapter)
2121
- [fcp_xml](https://github.com/OpenTimelineIO/otio-fcp-adapter)
22-
- [fcpx_xml](https://github.com/OpenTimelineIO/otio-fcpx-xml-adapter)
23-
- [hls_playlist](https://github.com/OpenTimelineIO/otio-hls-playlist-adapter)
2422
- [maya_sequencer](https://github.com/OpenTimelineIO/otio-maya-sequencer-adapter)
2523
- [svg](https://github.com/OpenTimelineIO/otio-svg-adapter)
2624
- [xges](https://github.com/OpenTimelineIO/otio-xges-adapter)
@@ -32,8 +30,9 @@ These adapters are supported by the broader OpenTimelineIO community. While the
3230
Below are some other adapters that may be useful to some users:
3331

3432
- [kdenlive](https://invent.kde.org/multimedia/kdenlive-opentimelineio)
33+
- [fcpx_xml](https://github.com/OpenTimelineIO/otio-fcpx-xml-adapter)
34+
- [hls_playlist](https://github.com/OpenTimelineIO/otio-hls-playlist-adapter)
3535

3636
## Custom Adapters
3737

3838
Adapters are implemented as plugins for OpenTimelineIO and can either be registered via an [environment variable](./otio-env-variables) or by packaging in a Python module with a particular entrypoint defined. For more detail, see the [Writing an OTIO Adapter](./write-an-adapter) tutorial.
39-

src/opentime/CMakeLists.txt

Lines changed: 3 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ set(OPENTIME_HEADER_FILES
77
rationalTime.h
88
stringPrintf.h
99
timeRange.h
10-
timeTransform.h)
10+
timeTransform.h
11+
version.h)
1112

1213
add_library(opentime ${OTIO_SHARED_OR_STATIC_LIB}
1314
errorStatus.cpp
@@ -16,12 +17,7 @@ add_library(opentime ${OTIO_SHARED_OR_STATIC_LIB}
1617

1718
add_library(OTIO::opentime ALIAS opentime)
1819

19-
target_include_directories(
20-
opentime
21-
PRIVATE
22-
"${PROJECT_SOURCE_DIR}/src"
23-
"${CMAKE_CURRENT_BINARY_DIR}/.."
24-
)
20+
target_include_directories(opentime PRIVATE "${PROJECT_SOURCE_DIR}/src")
2521

2622
set_target_properties(opentime PROPERTIES
2723
DEBUG_POSTFIX "${OTIO_DEBUG_POSTFIX}"
@@ -56,11 +52,6 @@ target_compile_options(opentime PRIVATE
5652
$<$<CXX_COMPILER_ID:MSVC>: /EHsc>
5753
)
5854

59-
configure_file(
60-
${CMAKE_CURRENT_SOURCE_DIR}/version.h.in
61-
${CMAKE_CURRENT_BINARY_DIR}/version.h
62-
)
63-
6455
if(OTIO_CXX_INSTALL)
6556
install(FILES ${OPENTIME_HEADER_FILES}
6657
DESTINATION "${OTIO_RESOLVED_CXX_INSTALL_DIR}/include/opentime")
@@ -98,12 +89,5 @@ if(OTIO_CXX_INSTALL)
9889
DESTINATION
9990
${OTIO_RESOLVED_CXX_INSTALL_DIR}/share/opentime
10091
)
101-
102-
install(
103-
FILES
104-
${CMAKE_CURRENT_BINARY_DIR}/version.h
105-
DESTINATION
106-
"${OTIO_RESOLVED_CXX_INSTALL_DIR}/include/opentime"
107-
)
10892
endif()
10993

src/opentime/version.h

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
// SPDX-License-Identifier: Apache-2.0
2+
// Copyright Contributors to the OpenTimelineIO project
3+
4+
#pragma once
5+
6+
#define OPENTIME_VERSION_MAJOR 0
7+
#define OPENTIME_VERSION_MINOR 19
8+
#define OPENTIME_VERSION_PATCH 0
9+
#define OPENTIME_VERSION v0_19_0
10+
#define OPENTIME_VERSION_NS v0_19
11+
12+
namespace opentime {
13+
namespace OPENTIME_VERSION_NS {
14+
}
15+
16+
using namespace OPENTIME_VERSION_NS;
17+
} // namespace opentime

src/opentime/version.h.in

Lines changed: 0 additions & 17 deletions
This file was deleted.

src/opentimelineio/CMakeLists.txt

Lines changed: 3 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,8 @@ set(OPENTIMELINEIO_HEADER_FILES
4545
transition.h
4646
typeRegistry.h
4747
unknownSchema.h
48-
vectorIndexing.h)
48+
vectorIndexing.h
49+
version.h)
4950

5051
add_library(opentimelineio ${OTIO_SHARED_OR_STATIC_LIB}
5152
color.cpp
@@ -95,12 +96,7 @@ add_library(opentimelineio ${OTIO_SHARED_OR_STATIC_LIB}
9596

9697
add_library(OTIO::opentimelineio ALIAS opentimelineio)
9798

98-
target_include_directories(
99-
opentimelineio
100-
PRIVATE
101-
"${PROJECT_SOURCE_DIR}/src"
102-
"${CMAKE_CURRENT_BINARY_DIR}/.."
103-
)
99+
target_include_directories(opentimelineio PRIVATE "${PROJECT_SOURCE_DIR}/src")
104100

105101
if(OTIO_FIND_RAPIDJSON)
106102
target_include_directories(opentimelineio
@@ -148,11 +144,6 @@ target_compile_options(opentimelineio PRIVATE
148144
$<$<CXX_COMPILER_ID:MSVC>: /EHsc>
149145
)
150146

151-
configure_file(
152-
${CMAKE_CURRENT_SOURCE_DIR}/version.h.in
153-
${CMAKE_CURRENT_BINARY_DIR}/version.h
154-
)
155-
156147
if(OTIO_CXX_INSTALL)
157148
install(FILES ${OPENTIMELINEIO_HEADER_FILES}
158149
DESTINATION "${OTIO_RESOLVED_CXX_INSTALL_DIR}/include/opentimelineio")
@@ -192,11 +183,4 @@ if(OTIO_CXX_INSTALL)
192183
DESTINATION
193184
${OTIO_RESOLVED_CXX_INSTALL_DIR}/share/opentimelineio
194185
)
195-
196-
install(
197-
FILES
198-
${CMAKE_CURRENT_BINARY_DIR}/version.h
199-
DESTINATION
200-
"${OTIO_RESOLVED_CXX_INSTALL_DIR}/include/opentimelineio"
201-
)
202186
endif()

src/opentimelineio/serializableObject.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ class OTIO_API_TYPE SerializableObject
162162
template <typename T>
163163
bool read(std::string const& key, Retainer<T>* dest)
164164
{
165-
SerializableObject* so;
165+
SerializableObject* so = nullptr;
166166
if (!read(key, &so))
167167
{
168168
return false;

0 commit comments

Comments
 (0)