← All ideas
  • Published 27 Nov 2018

VSE - RENDER TIME

An uncomfortable subject, Render Time. I edit the same intro in HitFilm to compare the render time. Here is the results: Hitfilm: 30 seconds. Blender 9 minutes. I don't expect the same time, but something around. In this case, the difference is too much. Share this information is essential to improve VSE. If someone has an ideia to enhance the render, is a significant contribution. I now that have some add-ons, but even using an addon like parallel render, the difference is also so big.

RENDER TIME.png

100%

Development Status: Open

Upvote 13 Downvote 0
cezarfarias
27 Nov 2018

8 Comments

malachyduffin

Here's a quick hack to set the thread count to 0 for ffmpeg writing, for further testing. I've noticed a slight speed-up here ( from 1m20s to 1m10s ).

If you edit the file writeffmpeg.c, search for the line below...

c = st->codec;

It should occur in two places ( at around line 545 and 708 ). Now, add an additional line below each of the two places, so it looks like...

c = st->codec;

c->thread_count = 0;

The default here was 1. I also changed it to BLI_system_thread_count() - which required an extra line ( #include "BLI_threads.h" ), and gave the same results as setting to 0, so for current testing, c->thread_count = 0 is the easiest change to make for now.

I noticed that Blender seemed to take up all of the cores of my machine in either case, but the number of threads used for the Blender process was slightly more with this change.

2
pablovazquez

@malachyduffin: This is super interesting! Could you make a patch and put it up in developer.blender.org so other devs can discuss about it? It's just so strange that it was hardcoded to single thread, perhaps there was a limitation or it was hurting other parts of Blender back then. Now with a new depsgraph and other upgrades maybe this is not needed anymore.

2
malachyduffin

I was thinking, if the writing isn't multi-threaded, then the reading won't be either!

Edit FFMPEGReader.cpp, and add this somewhere around line 186 ( under the AUD_THROW lines )

m_codecCtx->thread_count = 0;

This seems to take the time down from 1:10s to around 1:05s ( from the original 1:20s ) when rendering ( around a 20% speed-up )

1
tintwotin

Could be maked as done after malachyduffin patch has been committed a long time ago.

tintwotin

The changes suggested by malachyduffin has been implemented. I don't know if this will allow for marking it as "Done". There is still a need on the Blender side of i/o to go multithreaded.

3dcinetv

Blender isn´t multi-core on VSE at the moment.

pauloup

Hi Cezar. Maybe Rigtht-Click-Select is not the right please to help you, so if you feel that's ok to share this blend file, I could take a look. I don't need the actual video/image/sound files. My email is pauloup at gmail dot com

cezarfarias Author

@Paulo José Oliveira Amaro: Hi, I think that this is important for developers. This is about how blender works with render. But tks, I send a mail and maybe ww can keep in touch ;)