-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmx3600 adapter assumes tracks start at 00:00:00:00 #6
Comments
I had the same thought - but it seems that 'source_range' requires a negative number here or a lot of the test_cmx3600_adapter tests fail. |
I've narrowed down the culprit for this to the use of range_in_timeline = clip.transformed_time_range(
clip.trimmed_range(),
tracks
) |
Found a (stale?) explanation of how record-in + out should be calculated, using transformed_time_range, rather than stored. I also found the definition in src/item.cpp but am too ignorant to figure out what's going on...
So I asked chatgpt:
|
The editors I work with generate
.edl
(s) that typically start at or around01:00:00:00
. The reason they do this is because of the convention established by broadcast television to start at 1 hour. The editors also relayed that most, if not all, NLEs default their timelines to start at01:00:00:00
. Ideally, we would not have to conform how editors initialize their timelines and the adapters just react to what an editor choose to set up their timeline.Here is a sample
.edl
When I run he following code, the
cmx3600
adapter throws an error.I looked through the
cmx3600
adapter code and stumbled across this snippet, where aRationalTime
is constructed at00:00:00:00
.This code explains how the track in the above example becomes negative. This code is use to initialize the the track's source range and I think the source range should be based on the timing of the first clip found in the
.edl
instead of zero. I think this can be accomplished by doing the following:This simple change has the
start time
of the track be therecord_in
determined from the clip and the duration be zero. From what I can tell, the duration of the track starts at zero because it gets extended later in thecmx3600
adapter based on the clips found during parsing of the.edl
.Another QOL of improvement that could be made to the
cmx3600
adapter would be setting the timeline'sglobal_start_time
in this same code block. Currently theglobal_start_time
is never set. Like thestart_time
of the track, thestart_time
of timeline should also be based on the first clip found in the.edl.
With that in mind, the previous code suggestion would look like this:The text was updated successfully, but these errors were encountered: