Bug 385842 - slow transitions after splitting audio from clip
Summary: slow transitions after splitting audio from clip
Status: RESOLVED FIXED
Alias: None
Product: kdenlive
Classification: Applications
Component: Effects & Transitions (show other bugs)
Version: Appimage - Refactoring
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: Vincent PINON
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-17 04:00 UTC by S. Christian Collins
Modified: 2020-01-26 16:11 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
fritzibaby: Brainstorm+


Attachments
video showing the bug (2.36 MB, video/mp4)
2017-10-17 04:00 UTC, S. Christian Collins
Details
video for bug repro (1.35 MB, video/mp4)
2017-10-17 04:01 UTC, S. Christian Collins
Details

Note You need to log in before you can comment on or make changes to this bug.
Description S. Christian Collins 2017-10-17 04:00:28 UTC
Created attachment 108389 [details]
video showing the bug

Please see the attached video: "video showing the bug".

Steps to reproduce:
1. Download the attached video: "video for bug repro".
2. Place two copies of the video overlapping on two video tracks and create a dissolve transition between them..
3. Play the project. You will see a smooth transition.
4. Now, split the audio from both clips.
5. Play the project.

Result: The dissolve transition is incredibly slow and choppy, dragging my beefy desktop system to its knees and taking an extremely long time to play.

** My System **
Kdenlive: 17.08.2
MLT: compiled from git (reported as 6.5.0 by Kdenlive)
OS: KDE Neon 5.11.0 64-bit (Plasma Desktop 5.11.0, KDE Frameworks 5.38.0, Qt 5.9.1)
Linux Kernel: 4.10.0.37-generic
CPU: Intel Core i7 930 (2.8 GHz quad-core)
Video: NVIDIA GeForce GTX 970 w/ 4GB RAM (PCI Express)
NVIDIA video driver: 375.66
Comment 1 S. Christian Collins 2017-10-17 04:01:07 UTC
Created attachment 108390 [details]
video for bug repro
Comment 2 emohr 2018-12-27 15:58:32 UTC
Confirmed. Even in the Kdenlive_Nightly_Appimage 27.Dec 18.
Thank you for reporting.
Comment 3 Jean-Baptiste Mardelle 2018-12-30 11:52:51 UTC
Thanks for this report. After some testing, the slowdown is caused by the way we use producers in Kdenlive. Currently, for video only clips, we use instances of the same producer for each copy of the clip. This means that if you attempt to do a transition between 2 copies of the same clip using video only, MLT has to do a transition between 2 instances of the same producer, which causes the choppiness.
To solve this, we should treat video clips in the same way as audio clips: using a different producer for each track... will work on it.
Comment 4 emohr 2019-01-01 15:40:27 UTC
Hi Christian. Can you test with the actual Nightly build. It should be better.
https://binary-factory.kde.org/job/Kdenlive_Nightly_Appimage_Build/lastSuccessfulBuild/artifact/
Comment 5 S. Christian Collins 2019-01-03 19:59:58 UTC
So I see that audio clips are now split from video automatically in the current kdenlive nightly, so I can no longer compare transitions with/without the split. 

However, I can compare the nightly performance vs. 18.12.0, and here are the transition results:
* 18.12.0 video clips with audio integrated: full FPS, 16% CPU usage.
* 18.12.0 audio split to separate tracks: very low FPS, sound breaks up and playback rate slows considerably, 58% CPU usage.
* 2019-1-3 nightly with audio auto-split to separate tracks: very low FPS, but audio and playback speed are normal, 16% CPU usage.

(FYI, I have an i7 with hyperthreading, so the CPU usage numbers are not fully accurate.)

So, the experience has improved in regards to CPU usage and playback speed, but FPS is still not near where it is with the audio integrated with the video clip as it is in early versions of Kdenlive.

Also, what happened to the single-click dissolve transition? I used to be able to click on the corner of a video clip to add a dissolve transition with the clip beneath it.
Comment 6 emohr 2019-01-21 08:39:16 UTC
Task in GitLab: https://invent.kde.org/kde/kdenlive/issues/11
Comment 7 emohr 2019-02-21 17:43:35 UTC
Hi Christian. Could you make another test with the actual nightly build and disable the audio thumbnails (hit CTRL+SHIFT+, -> timeline -> un-tick audio in the Thumbnail window).
Comment 8 S. Christian Collins 2019-03-11 00:31:48 UTC
I don't notice any difference whether audio thumbnails show or not--it's choppy either way for me. Tested using the latest kdenlive nightly (kdenlive-19.03.70-9884299-x86_64.appimage).
Comment 9 emohr 2019-12-20 16:16:33 UTC
Hi Christian. Please try with the current Kdenlive AppImage version 19.12.0a which should solve the slow performance in the timeline.
Comment 10 S. Christian Collins 2020-01-26 16:11:22 UTC
This issue does appear to be resolved! I will mark the bug as fixed. Thank you :)