Could you please implement original video passthrough for matroska output.

General questions or discussion about HandBrake, Video and/or audio transcoding, trends etc.
Post Reply
ibabaev
New User
Posts: 1
Joined: Tue Oct 31, 2017 6:49 pm

Could you please implement original video passthrough for matroska output.

Post by ibabaev »

Dear Handbrake developer.

I was wondering if you could please implement original video passthrough for MKV output in handbrake. This is because sometimes I want to re-encode the audio stream and keep the video stream as it is since I don't want the video quality to be degraded any further. I don't know if you need this information but I am using Ubuntu version of handbrake.

Thank you.
Sincerely,
Isaak Babaev.
WhatZit
Experienced
Posts: 77
Joined: Sat Feb 13, 2016 2:45 am

Re: Could you please implement original video passthrough for matroska output.

Post by WhatZit »

ibabaev wrote: Tue Oct 31, 2017 7:02 pmThis is because sometimes I want to re-encode the audio stream and keep the video stream as it is since I don't want the video quality to be degraded any further.
Here's the agonisingly torturous solution to your problem, if you dare go to this much back-breaking trouble:

1. Load source into HB
2. Set up your audio encode the way you want.
3. Set video encoder to H.264, CQ50, Superfast, no tune, "SAME AS SOURCE"+CONSTANT FRAME RATE
4. Turn OFF all filters
5. Set dimensions to Keep aspect, Height=128
6. Encode!
7. Load source into MKVToolnix GUI
8. Turn OFF source audio
9. Drag/drop encode into same MKVToolnix GUI window
10. Turn OFF encode video
11. Start multiplexing!
12. ???
13. Profit

Luckily, if you set up a HB preset using the above principles, then the process goes from "so-nightmarishly-complicated-that-you-could-never-even-think-of-it" to "absolutely-[Censored]-easy".
jkauff
Experienced
Posts: 95
Joined: Thu Nov 22, 2012 1:27 pm

Re: Could you please implement original video passthrough for matroska output.

Post by jkauff »

MakeMKV is your one-stop solution if you're using the most common audio codecs. It can re-code the audio and automatically mux it into an MKV container with the uncompressed video stream. Doesn't get any easier.
mduell
Veteran User
Posts: 8202
Joined: Sat Apr 21, 2007 8:54 pm

Re: Could you please implement original video passthrough for matroska output.

Post by mduell »

jkauff wrote: Fri Nov 10, 2017 12:23 pmautomatically mux it into an MKV container with the uncompressed video stream.
Uncompressed it is not.
jkauff
Experienced
Posts: 95
Joined: Thu Nov 22, 2012 1:27 pm

Re: Could you please implement original video passthrough for matroska output.

Post by jkauff »

mduell wrote: Fri Nov 10, 2017 4:48 pmUncompressed it is not.
I'm talking about MakeMKV, not Handbrake. Handbrake compresses the video, MakeMKV does not.
Woodstock
Veteran User
Posts: 4620
Joined: Tue Aug 27, 2013 6:39 am

Re: Could you please implement original video passthrough for matroska output.

Post by Woodstock »

I think the point was that the stream is still compressed by whatever algorithm the source used... It would get ridiculous if the output was really uncompressed. :)
mduell
Veteran User
Posts: 8202
Joined: Sat Apr 21, 2007 8:54 pm

Re: Could you please implement original video passthrough for matroska output.

Post by mduell »

jkauff wrote: Fri Nov 10, 2017 11:06 pm
mduell wrote: Fri Nov 10, 2017 4:48 pm
jkauff wrote: Fri Nov 10, 2017 12:23 pminto an MKV container with the uncompressed video stream.
Uncompressed it is not.
I'm talking about MakeMKV, not Handbrake. Handbrake compresses the video, MakeMKV does not.
The video on the DVD/Bluray is already highly compressed. MakeMKV copies the compressed video bitstream.

A 2h 1080p movie uncompressed would be about a terabyte! Blu-rays are ~2% of that.
Deleted User 11865

Re: Could you please implement original video passthrough for matroska output.

Post by Deleted User 11865 »

More like 504-631 GB depending on frame rate, but that doesn't change your point.
mduell
Veteran User
Posts: 8202
Joined: Sat Apr 21, 2007 8:54 pm

Re: Could you please implement original video passthrough for matroska output.

Post by mduell »

Rodeo wrote: Sat Nov 11, 2017 12:58 amMore like 504-631 GB depending on frame rate, but that doesn't change your point.
1TB, no?

edit: oh, 4:2:0 :\ the other channels aren't as many pixels
Deleted User 11865

Re: Could you please implement original video passthrough for matroska output.

Post by Deleted User 11865 »

Though I suppose 4:2:0 itself is a form of compression, possibly.
Deleted User 11865

Re: Could you please implement original video passthrough for matroska output.

Post by Deleted User 11865 »

…and of course once you're uncompressed you don't need the macroblock-sized height resolution, so 500 to 626 GB (where of course I mean GiB) :D
jkauff
Experienced
Posts: 95
Joined: Thu Nov 22, 2012 1:27 pm

Re: Could you please implement original video passthrough for matroska output.

Post by jkauff »

All quite true, of course, but the OP was simply trying to avoid further compression. As you all well know. :wink:
Bigo2
Novice
Posts: 59
Joined: Mon Apr 17, 2017 2:28 am

Re: Could you please implement original video passthrough for matroska output.

Post by Bigo2 »

Handy to know how to do it, thanks WhatZit. Recently I tried a different approach: I extracted the audio stream from a MKV file using MKVExtractGUI. Then I open the resulting audio file in a program called Xrecode II (trial version of a quite nice conversion program, which can convert between many different formats) and have redone it as I wanted. Then I took the resulting file and put it back to the original MKV container using MKVToolnix. It worked OK and it was quite quick!
Oh, I have forgotten to say that I'm talking about windows...
Post Reply