What video container should I use?

8 days ago by printf("%s", name); to c/techsupport

Edit: I encode to/with(?) the codec h246. This question is about containers/filename extensions.

I am digitizing old video mediums, such as VHS, VHS-C and Mini DV. A few colleagues have asked me to do it for them, which is awesome and feels great. Now, for personal use, I encode save video with the .mkv container out of habit. I have no idea why that is bad or good. However, the question is, which container should I use to ensure maximum compatibility with my colleagues' phones, computers, possibly TVs? Is, for instance, .mpeg the way to go?

remon 8 points 8 days ago

Pretty sure every remotely modern device can open a .mkv container. It's much more important which video codec you used for the video inside the container, that's what will cause the compatibility issues. You want to use h264 for maximum compatibility (but at the expense of taking up more storage).

path: 0 26226942, hotness: undefined, score: 8, children: 8
ramble81 5 points 8 days ago

This is the best answer. MKV is just a container. It’s the codec that will matter the most. As mentioned H264 is going to be the most ubiquitous. Even if you were to try to do MP4 it’s still dependent on the codec. You could do an MKV with MPEG Layer 2, but that’s starting to become too old as well. Also for H264, the RF plays a big part too. Go for something higher like 22-24. It’ll make for a slightly larger file, but you’ll great quality without being a raw file size. Too low and you’ll end up with a potato.

As for audio, also stick with a safe codec like MP3. Using WAV is too large, AAC is limited as are some others as well.

path: 0 26226942 26227388, hotness: undefined, score: 5, children: 2
akunohana 4 points 8 days ago

Shoot! Thanks so much for mentioning the audio codecs! I was about to encode as flac because why not LOL. The audio of old family tapes are probably not considered high fidelity audiophile material anyway 🤣

path: 0 26226942 26227388 26227546, hotness: undefined, score: 4, children: 0
grue 1 point 7 days ago

Personally, I would value fidelity over ubiquity. After all, the recipient can transcode it themselves if they need to, but they're not necessarily going to be able to re-digitize it with higher quality in the future.

As such, I'd use the most modern video codec I could find (and use generous quality settings with it) and use FLAC for audio.

path: 0 26226942 26227388 26228957, hotness: undefined, score: 1, children: 0
hendrik 2 points 8 days ago

Edit: I didn't read properly... You're doing this for other people. Maybe you should go with the conservative option, then.

(I mean if their devices already support it, there's no harm in forgoing compatibility and just go with a more modern encoding format like HEVC or better AV1. It's not like the next laptop or TV will be unable to play it... But H264 is certainly a safe bet. That's supported everywhere.)

Also second the point about the container. It doesn't really matter, just go with mkv. In the unlikely case it doesn't work, you can always take the video an put it in a different container. That kind of conversion is fast and without loss.

path: 0 26226942 26227265, hotness: undefined, score: 2, children: 2
akunohana 2 points 8 days ago

Thanks! For some reason on Linux, I can (in some cases) "simply" rename the file with a different extension name. Would that be sufficient to do on the recipient's device, or would I need to process it more "properly" with ffmpeg (which I am using, by the way)?

path: 0 26226942 26227265 26227391, hotness: undefined, score: 2, children: 1
hendrik 2 points 7 days ago

You definitely want to do it properly with something like ffmpeg. Just renaming it leaves you with a misnamed mkv file. (Or whatever is inside.) Linux is clever enough to figure that out, because in the good old days, file extensions weren't all that important. But yeah, some other device might not. And even some Linux software might not get that. Also you won't really change anything, a name is just a name.

path: 0 26226942 26227265 26227391 26228208, hotness: undefined, score: 2, children: 0
akunohana 2 points 8 days ago

Ah, gotcha. Thanks! I was already using h246, so all good there then. :D

path: 0 26226942 26227372, hotness: undefined, score: 2, children: 0
Onomatopoeia 0 points 7 days ago

I've run into issues with MKV - like my Samsung TV can technically play them, but it does much better with MP4 (I still use MKV for future-proofing, and just deal with the tv being fickle).

Most people aren't like me, and won't tolerate that inconvenience.

path: 0 26226942 26228411, hotness: undefined, score: 0, children: 0
one_old_coder 5 points 8 days ago

I'm not an expert but MKV should be ubiquitous enough to please most people. You can tell reluctant people to install VLC and it should work with any codec.

I download most movies who are encoded in MP5/x265/whatever265 because it saves space, but MP4 could be better for people who only have iPhones or old TVs.

path: 0 26227269, hotness: undefined, score: 5, children: 3
akunohana 2 points 8 days ago

Thanks! My very first "customer" is a Samsung guy, so mkv should work in his case. I'll definitely try somebody's iPhone to see what containers and codecs they support.

path: 0 26227269 26227449, hotness: undefined, score: 2, children: 2
one_old_coder 2 points 8 days ago

For Apple users, MP4 has been the standard for decades.

path: 0 26227269 26227449 26227751, hotness: undefined, score: 2, children: 0
Onomatopoeia 2 points 7 days ago

As a Samsung TV owner, it can play MKV. But it does better (more consistent) with MP4.

To MKV is a more future-proof solution. MP4 is more compatible, today.

Tough call.

Though since it's for other people, I'd probably give them MP4, and highest quality those videos can benefit from.

path: 0 26227269 26227449 26228369, hotness: undefined, score: 2, children: 0
sexual_tomato 5 points 8 days ago

When I digitize stuff I used MKV because it was a format that was resilient to whatever program that created it crashing in the middle of creation. Mkv is segmented and doesn't need anything to be written about the entire file. It's just small sections kind of stitched together. In my opinion this is what you should digitize to initially and then if you need other codecs then transcode later.

path: 0 26227286, hotness: undefined, score: 5, children: 1
akunohana 2 points 8 days ago

Thanks! I'll definitely stay with mkv then! :)

path: 0 26227286 26227457, hotness: undefined, score: 2, children: 0
nicgentile 4 points 8 days ago

Maybe burn storage space, have a raw version that you use as the main source, and you can encode at your will to whatever as purpose requires.

path: 0 26226648, hotness: undefined, score: 4, children: 3
akunohana 4 points 8 days ago

Thanks! I always keep the raws, unless they explicitly ask me to delete them. My question is rather about which re-encoded/target container would be easiest to use for my colleagues and potential customers from a compatibility perspective.

path: 0 26226648 26226885, hotness: undefined, score: 4, children: 2
nicgentile 4 points 8 days ago

H264 MKV or MP4.

path: 0 26226648 26226885 26227050, hotness: undefined, score: 4, children: 1
akunohana 2 points 8 days ago

Thanks!

path: 0 26226648 26226885 26227050 26227412, hotness: undefined, score: 2, children: 0
Bo7a 3 points 8 days ago

anecdata - I recently sent a usb full of .mkvs to a buddy and they all came up unplayable on his TV. I converted them to mp4 and he was fine.

path: 0 26227323, hotness: undefined, score: 3, children: 1
akunohana 3 points 8 days ago

That's crazy, because I was in the very same situation a few weeks ago. A friend wanted some stuff and they specifically wanted to be able to simply play it from the USB stick on their TV. I anticipated compatibility issues, so I made sure to grab mp4 copies from the start. It worked. :D

path: 0 26227323 26227483, hotness: undefined, score: 3, children: 0
Labna 2 points 7 days ago

The question is partially answered by the other comments. I have just few details to had :

As it's the compatibility that matter you have a question of target player to answer :

  • to be compatible with older player, the most widespread container is AVI. It's the lightest to decode and I never found a player without this format
  • to be compatible with all the recent players, there is no alternative to mp4, but beware only the mpeg-2 and h264 compression are widespread
  • to be compatible with all future players : the mkv is the way, as it can expose multiple stream with alternative codec for audio and video (mp3 + aac + av1 + h264 in the same file) allow the player to open the one it can read

Now you can choose !

path: 0 26228923, hotness: undefined, score: 2, children: 0
gnufuu 1 point 8 days ago

Careful, you seem to confuse video encodings (e.g. mpeg, h264, h265, av1) with video containers (e.g. mkv, avi, webm). When digitizing old media, the encoding is much more important because changing it afterwards means losing quality whereas changing the container format doesn't.

path: 0 26227640, hotness: undefined, score: 1, children: 0
techsupport
techsupport

@lemmy.world

login for more options
3223
645
256

The Lemmy community will help you with your tech problems and questions about anything here. Do not be shy, we will try to help you.

If something works or if you find a solution to your problem let us know it will be greatly apreciated.

Rules: instance rules + stay on topic

Partnered communities:

You Should Know

Reddit

Software gore

Recommendations

go to feed...