Inconsistent "Always Fit Window" behavior in VLC for two different videos, one processed with kdenlive, the other with Tencoder (FFMPEG)

Two different videos:

  • both have same resolution (1920 x 1080)
  • one processed with Tencoder (frontend for FFMPEG), and the other processed with kdenlive (video editor that uses MLT framework)

The issue: they show up very differently in VLC.

  • One needs “Menu > Video > Always Fit Window” to be checked to fill the screen.
  • The other needs “Menu > Video > Always Fit Window” to be unchecked to fill the screen.

Video 1: processed using kdenlive (video editor that uses MLT framework) [link][1]:

How the file looks in the file system:

image

kdenlive project settings:

image

kdenlive render profile:

image

The MLT command looks like this in kdenlive (screenshot):

2024-11-26_002205

The MLT command in text form:

ab=160k acodec=aac channels=2 crf=23 f=matroska g=15 movflags=+faststart preset=veryfast real_time=-1 threads=0 vcodec=libx264

MediaInfo:

image

VLC with “Always Fit Window” checked: video underfills the screen:

image

VLC with “Always Fit Window” unchecked: video fills the screen:

image


Video 2: processed using Tencoder (frontend for FFMPEG):

How the file looks in the file system:

image

Tencoder encode settings:

image

MediaInfo:

image

VLC with “Always Fit Window” checked: video fills the screen:

image

VLC with “Always Fit Window” unchecked: video overfills the screen:

image


Summary:

  • despite the two videos having the same resolution (1920 * 1080)
  • to fill the screen, one video needs “Always Fit Window” unchecked and the other needs it checked.

Question for you dear reader: What can I do in kdenlive or MLT so that the video fills the screen in VLC with “Always Fit Window” checked?

Hi, and welcome to the forum and community.

I noticed that the display aspect ratio in the Kdenlive project profile is set to 5:4 with the dimensions being 1920x1080. This should be 16:9, but not sure whether this will change the VLC behavior. Perhaps VLC is looking for other data as well that is not provided by Kdenlive …

1 Like

Also, I’m pretty sure that vertical video source isn’t 1920x1080 …

If you’ve created your own profile, with made up numbers that have no relation to your actual source video, then who knows what the HAL 9000 might do with that once you’re in orbit around Jupiter.

I’d suggest that vlc isn’t ‘underfilling’ your screen at all - it’s perfectly fitting it to the 1920 wide video that your frankenstein profile created when you ask it to do that.

If I knew exactly what to do, I wouldn’t be here.

If I knew how to read minds, I’d have joined the circus.

You didn’t ask what to do - you said you created two 1920x1080 videos with two different applications and vlc behaved “inconsistently” when you tried to play them…

It didn’t. It displayed exactly what each of those applications created when you lied to them about the resolution of your source material.

If you don’t know what these words mean and why that’s a problem for you, you’re going to need to go and do some homework about the very basics of video before just clicking things at random and then hoping we can magically guess and explain everything that you don’t know about why that didn’t work. Sorry.

Thanks, @Ron , for pointing out the mixed up resolution/dimension settings. I missed that for my first reply.

@xmatic, a vertical video has a dimension of 1080x1920 pixels (or whatever size you want but the first number is always smaller than the second as it is given by width x height). There are project profiles for vertical videos available in Kdenlive, and IIRC also in the KDE Store.

Got it, thank you!

The following changes in the “Project Profile” worked:

  1. changing the resolution to 1080x1920
  2. changing the aspect ratio to 6:9 9:16
  3. changing the pixel dimensions to 1x1

Appreciate the help.

I sincerely hope this is just a typo and you set the aspect ratio to 16:9 :wink:

Glad the community could help …

Whoops, thanks for catching that, fixed. It should have been 9:16. (Very important to catch these errors, and fix them, because it’s like documentation for future actions.)