Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > General > Newbies

Reply
 
Thread Tools Search this Thread Display Modes
Old 19th July 2022, 00:36   #1  |  Link
kolamorx
Registered User
 
Join Date: Jun 2017
Posts: 47
Adding black bars to videos without re-encoding?

Is there any method to add black bars to videos without re-encoding?
kolamorx is offline   Reply With Quote
Old 19th July 2022, 14:08   #2  |  Link
Music Fan
Registered User
 
Join Date: May 2009
Location: Belgium
Posts: 1,743
You can make an Avisynth script which add black bars and you play it in real time. But it will be playable on pc only, not on an external player.
Music Fan is offline   Reply With Quote
Old 20th July 2022, 20:00   #3  |  Link
FranceBB
Broadcast Encoder
 
FranceBB's Avatar
 
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,883
Quote:
Originally Posted by kolamorx View Post
Is there any method to add black bars to videos without re-encoding?
By physically adding them to the file? No, you have to re-encode.

By making the player display them on the fly? Yes, you can.

Some players allow you to set how a file should be displayed.
For instance, for SD files on Omneon, not only you can add the 4:3 or 16:9 tag, but you can also add whether it should display black bars or crop. This information will be added into the .mxf container and it will be read by any player that supports it.

The problem with this is that if you do something like this there's no guarantee that it will work and only a few players will honour that and definitely not consumer players given that it's mxf. A more consumer friendly alternative would be to do this with MKVToolnix which allows you to set the aspect ratio and cropping parameters at container level. When the file plays, the player should read those values and apply the scaling on the fly, however this is not really very widespread either. I think it would be much better to re-encode, but if you insist on doing this without re-encoding, your best shot is MKVToolnix.
FranceBB is offline   Reply With Quote
Old 20th July 2022, 20:53   #4  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
Quote:
Originally Posted by kolamorx View Post
Is there any method to add black bars to videos without re-encoding?
Out of interest... What device will you be using to play such files?

Just about any software player will automatically add black bars, depending on the aspect ratio of the content and the display screen. Same goes for hardware play back devices.
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
SeeMoreDigital is offline   Reply With Quote
Old 21st July 2022, 21:29   #5  |  Link
kolamorx
Registered User
 
Join Date: Jun 2017
Posts: 47
Quote:
Originally Posted by FranceBB View Post
I think it would be much better to re-encode, but if you insist on doing this without re-encoding, your best shot is MKVToolnix.
Is MKVToolnix capable of adding black bars to videos?
kolamorx is offline   Reply With Quote
Old 21st July 2022, 21:34   #6  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
Quote:
Originally Posted by kolamorx View Post
Is MKVToolnix capable of adding black bars to videos?
In short... No!

Why do you need to add black bars. What device are you using to play your files?
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
SeeMoreDigital is offline   Reply With Quote
Old 22nd July 2022, 00:20   #7  |  Link
kolamorx
Registered User
 
Join Date: Jun 2017
Posts: 47
Quote:
Originally Posted by SeeMoreDigital View Post
What device are you using to play your files?
I use my personal computer (VLC media player for Windows) to play the files.
kolamorx is offline   Reply With Quote
Old 22nd July 2022, 08:11   #8  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
VLC player offers the ability to add black bars automatically.

If this isn't happening it must mean your sources have not been encoded correctly. With this in mind please run one of your problem sources through an application called MediaInfo, which must be set to text mode and post what it reports 'in full' as a text file.
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
SeeMoreDigital is offline   Reply With Quote
Old 22nd July 2022, 08:37   #9  |  Link
Music Fan
Registered User
 
Join Date: May 2009
Location: Belgium
Posts: 1,743
Quote:
Originally Posted by SeeMoreDigital View Post
In short... No!
And what if we put a higher resolution as display resolution than the actual resolution and set a cropping ?
Music Fan is offline   Reply With Quote
Old 22nd July 2022, 21:07   #10  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
You'll need to provide an example.

Personally I have dozens (720x480 and 720x576) of image only (ie: black border cropped) DVD back-ups on my NAS that are displayed perfectly on my 65" TV.

Lol... When this forum started (over 20 years ago), we all cropped the black borders from our DVD back-ups!
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
SeeMoreDigital is offline   Reply With Quote
Old 22nd July 2022, 22:24   #11  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Quote:
Originally Posted by SeeMoreDigital View Post
Lol... When this forum started (over 20 years ago), we all cropped the black borders from our DVD back-ups!
Some of us still do so.
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???
StainlessS is offline   Reply With Quote
Old 23rd July 2022, 19:32   #12  |  Link
FranceBB
Broadcast Encoder
 
FranceBB's Avatar
 
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,883
Quote:
Originally Posted by kolamorx View Post
Is MKVToolnix capable of adding black bars to videos?
Ah no, not adding. Looks like it's only supported in the Omneon Muxer and mxf container... what a bummer. I really thought MKV would support this 'cause mkv as a container generally supports (almost) literally anything...
FranceBB is offline   Reply With Quote
Old 23rd July 2022, 20:13   #13  |  Link
StainlessS
HeartlessS Usurer
 
StainlessS's Avatar
 
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
Quote:
Originally Posted by SeeMoreDigital View Post
VLC player offers the ability to add black bars automatically.

If this isn't happening it must mean your sources have not been encoded correctly. With this in mind please run one of your problem sources through an application called MediaInfo, which must be set to text mode and post what it reports 'in full' as a text file.
Lets forget adding black bars, the only sensible/sane way is as said by SeeMoreDigital.
It might just be a case of changing aspect ratio in container[sources have not been encoded correctly],
OR, just using correct settings in player.
Post output of MediaInfo.
__________________
I sometimes post sober.
StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace

"Some infinities are bigger than other infinities", but how many of them are infinitely bigger ???

Last edited by StainlessS; 23rd July 2022 at 20:19.
StainlessS is offline   Reply With Quote
Old 23rd July 2022, 22:20   #14  |  Link
stax76
Registered User
 
stax76's Avatar
 
Join Date: Jun 2002
Location: On thin ice
Posts: 6,837
For cases where a container option don't help, mpv supports file specific configuration files:

https://mpv.io/manual/master/#file-s...guration-files


In such a file, filters can be defined:

https://mpv.io/manual/master/#video-filters


It's not completely easy to learn how to use mpv, a good place to ask questions is Reddit:

https://www.reddit.com/r/mpv
stax76 is offline   Reply With Quote
Old 24th July 2022, 08:56   #15  |  Link
kolamorx
Registered User
 
Join Date: Jun 2017
Posts: 47
Quote:
Originally Posted by SeeMoreDigital View Post
VLC player offers the ability to add black bars automatically.
VLC player is not capable of adding black bars automatically.
https://forum.videolan.org/viewtopic...160309#p529433
kolamorx is offline   Reply With Quote
Old 24th July 2022, 10:14   #16  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
Quote:
Originally Posted by kolamorx View Post
VLC player is not capable of adding black bars automatically.
https://forum.videolan.org/viewtopic...160309#p529433
Oh yes it can!

I've just played a few minutes of the following 'cropped' (and very poorly encoded) movie in VLC,and it added the black bars: -

Code:
General
Complete name                            : \\SYNOLOGY_NAS\My Photos and Videos\Videos\My MPEG-4 Movie Test Files\Die Hard 4 (Live Free Or Die Hard) @ 123mins (628x254p25.000).avi
Format                                   : AVI
Format/Info                              : Audio Video Interleave
File size                                : 702 MiB
Duration                                 : 2 h 3 min
Overall bit rate                         : 795 kb/s
Writing application                      : VirtualDubMod 1.5.10.1 (build 2366/release)
Writing library                          : VirtualDubMod build 2366/release

Video
ID                                       : 0
Format                                   : MPEG-4 Visual
Format profile                           : Advanced Simple@L5
Format settings                          : BVOP2
Format settings, BVOP                    : 2
Format settings, QPel                    : No
Format settings, GMC                     : No warppoints
Format settings, Matrix                  : Default (H.263)
Codec ID                                 : DX50
Codec ID/Hint                            : DivX 5
Duration                                 : 2 h 3 min
Bit rate                                 : 673 kb/s
Width                                    : 628 pixels
Height                                   : 254 pixels
Display aspect ratio                     : 2.472
Frame rate                               : 25.000 FPS
Color space                              : YUV
Chroma subsampling                       : 4:2:0
Bit depth                                : 8 bits
Scan type                                : Progressive
Compression mode                         : Lossy
Bits/(Pixel*Frame)                       : 0.169
Stream size                              : 594 MiB (85%)
Writing library                          : XviD 1.0.3 (UTC 2004-12-20)

Audio
ID                                       : 1
Format                                   : MPEG Audio
Format version                           : Version 1
Format profile                           : Layer 3
Codec ID                                 : 55
Codec ID/Hint                            : MP3
Duration                                 : 2 h 3 min
Bit rate mode                            : Constant
Bit rate                                 : 112 kb/s
Channel(s)                               : 2 channels
Sampling rate                            : 48.0 kHz
Compression mode                         : Lossy
Stream size                              : 98.9 MiB (14%)
Alignment                                : Aligned on interleaves
Interleave, duration                     : 40  ms (1.00 video frame)
Interleave, preload duration             : 504  ms
So please post a MediaInfo report as previously requested?
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |

Last edited by SeeMoreDigital; 24th July 2022 at 10:25. Reason: MediaInfo Report Added
SeeMoreDigital is offline   Reply With Quote
Old 24th July 2022, 12:03   #17  |  Link
kolamorx
Registered User
 
Join Date: Jun 2017
Posts: 47
Quote:
Originally Posted by SeeMoreDigital View Post
Oh yes it can!
That's because your video has a 2.472 aspect ratio, of course any player will automatically add black bars when using a large window.
However, the video's width is maximal and my goal is to limit it and force it permanently to 16:9 aspect ratio by black bars. (I use only large VLC window.)
VLC developer says that the player is not capable of doing it.

Last edited by kolamorx; 24th July 2022 at 12:09.
kolamorx is offline   Reply With Quote
Old 24th July 2022, 12:17   #18  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
Just post a MediaInfo file report!
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
SeeMoreDigital is offline   Reply With Quote
Old 24th July 2022, 12:22   #19  |  Link
kolamorx
Registered User
 
Join Date: Jun 2017
Posts: 47
There is no point in doing that.
kolamorx is offline   Reply With Quote
Old 24th July 2022, 12:30   #20  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
Quote:
Originally Posted by kolamorx View Post
There is no point in doing that.
With respect, without providing detailed information about your source video, you are wasting everybody's time. Nobody can help you!

I have request this topic be closed.
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |

Last edited by SeeMoreDigital; 24th July 2022 at 19:23.
SeeMoreDigital is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 20:50.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.