Skip to content

Commit 0dca468

Browse files
committed
list C++ example first
1 parent e536959 commit 0dca468

File tree

1 file changed

+11
-11
lines changed

1 file changed

+11
-11
lines changed

README.md

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -91,16 +91,6 @@ For detailed installation instructions and notes on how to run the included view
9191
Example Usage
9292
-------------
9393

94-
Python:
95-
96-
```python
97-
import opentimelineio as otio
98-
99-
timeline = otio.adapters.read_from_file("foo.aaf")
100-
for clip in timeline.clip_if():
101-
print(clip.name, clip.duration())
102-
```
103-
10494
C++:
10595

10696
```c++
@@ -111,7 +101,7 @@ C++:
111101
namespace otio = opentimelineio::OPENTIMELINEIO_VERSION;
112102

113103
void
114-
example()
104+
main()
115105
{
116106
otio::ErrorStatus err;
117107
otio::SerializableObject::Retainer<otio::Timeline> tl(
@@ -131,6 +121,16 @@ example()
131121
}
132122
```
133123
124+
Python:
125+
126+
```python
127+
import opentimelineio as otio
128+
129+
timeline = otio.adapters.read_from_file("foo.aaf")
130+
for clip in timeline.clip_if():
131+
print(clip.name, clip.duration())
132+
```
133+
134134
There are more code examples here: https://github.com/AcademySoftwareFoundation/OpenTimelineIO/tree/main/examples
135135

136136
Also, looking through the unit tests is a great way to see what OTIO can do:

0 commit comments

Comments
 (0)