This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Rendering with threads=2 option didn"t work

Tags: None
(comma "," separated)
lxvidcut
Registered Member
Posts
54
Karma
0
Hi everybody,

the next problem is teasing me.
If I try to set the threads=2 option to the rendering profile to speed up encoding, the final clip has on 1pass encoding a very bad quality and on 2pass coding the final clip is empty.

This is my profile:
f=matroska threads=2 hq=1 acodec=ac3 ab=384k pix_fmt=yuv420p vcodec=libx264 minrate=0 b=18000k b_strategy=1 subcmp=2 cmp=2 coder=1 flags=+loop flags2=dct8x8 qmax=51 subq=7 qmin=10 qcomp=0.6 qdiff=4 trellis=1 aspect=%dar pass=2

Source is 1080i 25fps interlaced TFF DNxHD
Destination is also 1080i

Without the threads option, all works fine. CPU load is 60-70%. With threads option load is 95%.
CPU is AMD Athlon X2 5000

Transcoding of my AVCHD files to DNxHD with -threads 2 works fine.

mlt 0.5.6
ffmpeg 0.6 with g.marcos's static field order patch for x264 encoding
configuration: --shlibdir=/usr/lib64 --prefix=/usr --mandir=/usr/share/man --libdir=/usr/lib64 --enable-shared --enable-libmp3lame --enable-libvorbis --enable-libtheora --enable-libspeex --enable-libfaad --enable-libfaac --enable-nonfree --enable-libxvid --enable-postproc --enable-gpl --enable-x11grab --extra-cflags='-O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -fPIC -I/usr/include/gsm' --enable-libschroedinger --enable-libdirac --enable-libgsm --enable-avfilter --enable-libvpx --enable-version3 --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libx264 --enable-libdc1394 --enable-pthreads

Kdenlive 0.7.7.1

I've seen some posts from 2008-2009. But now is it possible to use more additional cores?
In future I'll setup a pure rendering Linux node for big projects on my media center PC which is equipped with a Quad-Core i5 CPU.

Thanks
christian
ddennedy
Registered Member
Posts
1315
Karma
1
In the past, I have had some problems in MLT with making dual-pass encoding work with multiple x264 threads. I believe I had got it working reliably in version 0.5.6. At least, I fixed it for me using my old openSUSE setup. Now, I am using KXStudio with the ffmpeg v0.6-based and x264 build 85 packages, and it still works for me. Now, I just built mlt v0.5.6 and tested that (was using git master tip), and it still works. I don't know what is wrong. Did you rebuild mlt after modifying x264 and ffmpeg, or if not was mlt built against the same version of ffmpeg that you modified?

P.S. I tested using a HDV 1080i 25fps TFF source and without x264 patch.


lxvidcut
Registered Member
Posts
54
Karma
0
This happens now on my "productive" OpenSuse 11.3 x64.
ffmpeg, mlt, kdenlive are binaries from packman repo.
To patch ffmpeg I've just removed it with it's own libs from my system (forced mode with breaking the chain).
After that I've patched the source rpm from packman (same version). Only 1 new printf message in ffmpeg.c and 1 new code line (g.marcos' patch) in libavcodec's libx264.c.
No mod's on x264 itself.
After building my patched rpm (without libspeex) I've installed it without any trouble. After that the dependency chain was now ok again.
No changes on Kdenlive and MLT.

Here is the link to the other thread about my procedure:
http://www.kdenlive.org/forum/how-proceed-after-ffmpeg-patch

The used procedure was my key question last week. Is it allowed to swap ffmpeg without getting trouble with all other stuff which depends on it or on it's libs? g.marco gaves me the tip to use the identical sources from the binary distributor. For my understanding this method should be clean and isn't it the benefit of shared objects libs? ffmpeg itself is definitely clean because it was build new including it's own libs and all was extern linked new because of the installed devel packages like x264-devel and so on.
My first try was to build ffmpeg from svn and I confessed this is nonsense.

Next I'll check what happens if I use the original ffmpeg again to see if there is the problem also present?

What do you think? Is it also necessary to rebuild MLT and Kdenlive? Then I'll first try to build also from source rpm.

lxvidcut
Registered Member
Posts
54
Karma
0
Update:
Ok, same problem with original Packman ffmpeg 0.6 binary packet.
Packman is deploying x264 build 98 btw... (0.98svn20100615-1.pm.3.2)

Do you know something about the used ffmpeg compiler options? Could this be an issue?
--extra-cflags='-O2 -g -m64 -fmessage-length=0 -D_FORTIFY_SOURCE=2 -fstack-protector -funwind-tables -fasynchronous-unwind-tables -fPIC -I/usr/include/gsm'

Meanwhile it's possible for me to build all stuff (Kdenlive, mlt 0.5.8 , ffmpeg) from sources into /usr/local. I've a few questions left so that I will open a new thread in the "build from sources section" the next days.

Is it a good idea to build with the compiler flags from above?

If this all won't work it seems that I should give up my Suse and try Ubuntu/KXStudio instead.




Bookmarks



Who is online

Registered users: Bing [Bot], blue_bullet, Google [Bot], Yahoo [Bot]