FFMPEG

For all the users of Twilight Render (V1 & V2), to ask questions and get started
ntxdave
Posts: 1008
Joined: Tue Feb 23, 2016 7:05 pm
OS: Win 10
SketchUp: 2020Pro

FFMPEG

Post by ntxdave » Wed Dec 29, 2021 6:24 pm

I am suddenly having problems with FFMPEG. When I try to generate an MP4 file after generating a set on images, I am getting a "0" size file. Can someone give me an idea of something I should check.

I tried reinstalling FFMPEG and it did not solve the problem.

Fletch
Posts: 12903
Joined: Fri Mar 20, 2009 2:41 pm
OS: PC 64bit
SketchUp: 2016-2023
Contact:

Re: FFMPEG

Post by Fletch » Thu Dec 30, 2021 9:34 am

Sorry Dave, but I have little to no experience with FFMPeg, we only use it as a convenient tool to auto-generate video files. Twilight Render does not have anything to do with how FFMpeg works.

ntxdave
Posts: 1008
Joined: Tue Feb 23, 2016 7:05 pm
OS: Win 10
SketchUp: 2020Pro

Re: FFMPEG

Post by ntxdave » Thu Dec 30, 2021 2:29 pm

Ok - I understand. If I get to open my laptop today, I have a suspicion but I may be way off base. It has worked for me in the past.

BTW: I sent you a PM yesterday but I notice it is still sitting in my outbox and I cannot open it..

ntxdave
Posts: 1008
Joined: Tue Feb 23, 2016 7:05 pm
OS: Win 10
SketchUp: 2020Pro

Re: FFMPEG

Post by ntxdave » Thu Jan 06, 2022 9:31 pm

OK, I have tried a number of things and I cannot get this to work/generate a valid mp4 file (or any other movie).

Giving up............................ :wall:

ntxdave
Posts: 1008
Joined: Tue Feb 23, 2016 7:05 pm
OS: Win 10
SketchUp: 2020Pro

Re: FFMPEG

Post by ntxdave » Sun Jan 09, 2022 9:33 pm

Here are two screen shots that give you some idea of what I see when I run ffmpeg
Directory showing that an mp4 file generated
Directory showing that an mp4 file generated
ffmpeg-mp4-file.jpg (65.36 KiB) Viewed 4917 times
Error message that is displayed when you click on the mp4 file that was generated
Error message that is displayed when you click on the mp4 file that was generated
ffmpeg-error.jpg (53.89 KiB) Viewed 4917 times
I do not understand what is happening.

Chris
Posts: 5344
Joined: Sun Mar 08, 2009 3:00 am
OS: Win10
SketchUp: 2016

Re: FFMPEG

Post by Chris » Mon Jan 10, 2022 2:29 pm

What is the dimensions of your image? Twilight Render is supposed to make sure that it is using compatible dimensions but it is possible something isn't working. Most MP4 encoders require the width (and maybe the height?) to be a multiple of 4. If your image isn't evenly divisible by 4, try making it so and see.

Also, did something on your system change? I recall you have been able to create movies in the past (it's been a couple years I think).

ntxdave
Posts: 1008
Joined: Tue Feb 23, 2016 7:05 pm
OS: Win 10
SketchUp: 2020Pro

Re: FFMPEG

Post by ntxdave » Mon Jan 10, 2022 4:05 pm

Yes, I used to be able to create movies but I was using Fredo’s Animator plugin. This all started when someone asked about using animated textures wi TR. Hopefully I will be able to fire up my laptop later today and take a look at things. If so, I will let you know.

Fletch
Posts: 12903
Joined: Fri Mar 20, 2009 2:41 pm
OS: PC 64bit
SketchUp: 2016-2023
Contact:

Re: FFMPEG

Post by Fletch » Mon Jan 10, 2022 6:33 pm

Sorry to hear of troubles with ffmpeg.
As mentioned, I have no control over ffmpeg, and little experience or knowledge of the app.

If you have the separate rendered images, try creating the video with Windows Video Editor App or other video editing software.

ntxdave
Posts: 1008
Joined: Tue Feb 23, 2016 7:05 pm
OS: Win 10
SketchUp: 2020Pro

Re: FFMPEG

Post by ntxdave » Mon Jan 10, 2022 6:59 pm

OK - I think Chris may have pointed out the problem. Although I thought that my image sizes were divisible by 4 in both directions, I did some playing around with image sizes and it is working for me.

I went in to one of the directories where things did not work correctly and clicked on one of the images. I then looked at the properties and saw an odd image size of 800x421. I sure do not remember ever setting anything like that but it seems to verify what Chris said. I partially generated several more sets of images making sure that both the width and height were divisible by 4 and they all have worked. So maybe that seems to verify what Chris said.

ntxdave
Posts: 1008
Joined: Tue Feb 23, 2016 7:05 pm
OS: Win 10
SketchUp: 2020Pro

Re: FFMPEG

Post by ntxdave » Mon Jan 10, 2022 10:54 pm

OK guys, I think I have figured out what is really happening. When you look at the image below, you will notice that the images being generated are not what my setting is in the Animation Editor.
FileSize.jpg
FileSize.jpg (103.6 KiB) Viewed 4892 times
The image that was generated is an off size and is not divisible by 4 (on both the height and width) therefore FFmpeg will not generate the video.

Also, if you see the size of the gray box in the background you will notice that it’s shape does not match the size/shape defined in the image size box. It should be taller than it is wide. I have noticed that several times when generating animations but did not put two and two together. :-( to me!

Hope all of this is helpful.

Post Reply

Who is online

Users browsing this forum: No registered users and 26 guests