Skip to content
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

Container and codec limitation notification #8

Open
tin2tin opened this issue Sep 2, 2018 · 9 comments
Open

Container and codec limitation notification #8

tin2tin opened this issue Sep 2, 2018 · 9 comments

Comments

@tin2tin
Copy link

tin2tin commented Sep 2, 2018

I noticed that Parallel Render will only work with the mpeg-4 container and a h.264 codec when using Ffmpeg video. I guess, that this is not a bug, but probably a limitation. Apparently, ffmpeg does not have a codec limitation when concatenating media files. Is this an extension issue? Anyway, not having the right container and codec will cause errors, so maybe a check is needed, if these settings are correct, and inform the user if they are not correct.

@elmopl
Copy link
Owner

elmopl commented Sep 2, 2018

I tried with:

image

And it seems to have worked fine.
I probably should check if output is video, but other than that I can't seem to reproduce any issues.

What settings exactly did you try to use?
What was ffmpeg error?

elmopl added a commit that referenced this issue Sep 2, 2018
This relates to #8.
Not sure if the best way to approach issue of incorrect render settings
is to hide the add-on from Blender list.
@elmopl
Copy link
Owner

elmopl commented Sep 2, 2018

I have added fix to hide parallel render from available operators when render file format is wrong.
I am not convinced that is the best UX for this. Maybe it should always be there and when invoked with incorrect values it should fail with some error before it starts to render?
Here my issue I think is what is usual Blender UI/flow to indicate mismatch in configuration like this.

@tin2tin
Copy link
Author

tin2tin commented Sep 2, 2018

I used Quicktime as a container and DNxHD as codec - maybe the source file doesn't have a resolution which complies to HD.

I don't have time to test all codec combinations right now, but using AVI instead of ffmpeg caused also an error just when cleaning up started.

I'm sorry to pester you like that, but your solution is the only Blender UI based solution AFAIK and therefore in my eyes the winner among the various cmd vse-fast-render options out there. Actually, I think you should consider to add it to the UI as a new strip property tab, maybe called 'Render' for a better user experience?

[EDIT: Users will be puzzled if it just disappears. Probably it is better to inform them that the render settings are incompatible with the add-on?]

@elmopl
Copy link
Owner

elmopl commented Sep 2, 2018

So I tried:

  • Quicktime causes my Blender to crashes Blender
  • DNxHD doesn't work even without mu plug-in (with the error about mismatch in resolution)

I am not quite sure how I could discover those things are not going to work when even Blender itself doesn't seem to handle those cases (i.e. I can select those options, but they will not render even without my add-on).

I think you should first try to see if with current render config you can just "render animation" without using my add-on (even if you just try to render 10-20 frames only). If Blender can't render it, then obviously using my add-on will not help.

So in short: I don't think those two above issue are problems with add-on itself as it seems that problem is there with just pure Blender.

elmopl added a commit that referenced this issue Sep 2, 2018
This moves configuration from being in a popup when trying to execute
operator to a section under Render panel.

This closes #9.

This also touches on #8 as it now behaves just a bit better when output is not a video.
@elmopl
Copy link
Owner

elmopl commented Sep 2, 2018

image

I moved configuration to a section under Render.
There is also an entry in "Render" menu.

I will work a bit more later on the popup you get just before you start parallel render.

@tin2tin
Copy link
Author

tin2tin commented Sep 2, 2018

Wow, that's super cool with the UI! AVI RAW and Quicktime works here now. :-) DNxHD codec is not working here in Blender natively, so you're right that must be a bug in Blender.

Unfortunately, I'm still getting the error with a fresh and clean start up of Blender with an unsaved .blend. I had a look at the Power Sequencer add-on. And they are forcing the user to save the project this way:

if not bpy.data.is_saved:
layout.label('Please save your project')
layout.operator(
'wm.save_as_mainfile', icon='SAVE_AS', text='Save as')

From here: https://github.com/GDquest/Blender-power-sequencer/blob/master/ui/power_sequencer_menu.py

A thought on bad codecs/containers, maybe the addon could render one frame of the video and if it fails, it will abort the entire operation and give the user a message of "Unsupported codec/container"?

@elmopl
Copy link
Owner

elmopl commented Sep 2, 2018

For the unsaved .blend file there is #7 (it is easier to keep track of issues if they are separate).

A thought on bad codecs/containers, maybe the addon could render one frame of the video and if it fails, it will abort the entire operation and give the user a message of "Unsupported codec/container"?

That did cross my mind and currently am contemplating if that's the best I can do.
It might be what I will end up doing.

BTW. interesting add-on. Haven't seen it before and seems like it might be useful.

@tin2tin
Copy link
Author

tin2tin commented Sep 3, 2018

It seems to me that it is now only bad containers/codecs causing errors when rendering(outside the not-saved-.blend-error), so maybe a simple way to get around this problem is to add a line of text in the progress bar in the header after the error message, something along the lines of "Try a different container or codec.", and this may also work and be valid for image formats, so maybe no more need to close down the UI when ex. PNG?

@Coarist
Copy link

Coarist commented Jun 6, 2020

Blender 2.81a VSE Rarallel Render, "Encoding - Container"

Matroska: crash Blender during final "mixing down audio" stage.
MPEG-4: Good, as reported in tine2tin's posting above. 

Initially Blender crashed and dismissed itself after parallel render has almost finish showing "mixing down audio". Having read this posting, I changed "Encoding - Container" from "Matroska" to "MPEG-4". Parallel VSE render completed successfully after this change. Settings that works:

Blender 2.81a version, Windows 10 x64
FFmpeg video (Output File Format)
MPEG-4 (Encoding-Container)
H.264 (Video Codec)
MP3 (Audio Codec)

Parallel Render config:

2 Blender Instances
4 Number of Parts

Results 30FPS, 3742 frames, 1920x1080 HD

15 minutes, about 43% CPU utilisation, standard Blender VSE
10 minutes, about 70% CPU utilisation, Blender VSE with Parallel Render

GPU utilisation also increase correspondingly when using Parallel Render.

The audio (in the video) has slight disruption where the segments join.

A big thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants