I used to be on here all the time, usually giving advice but now technology have moved on and I haven't so now I'm here with a question. I'm putting together a video in DVD SD format so 720x576, 25 fps PAL. I want to add some clips from a dashcam which is .avi, H264 format in 1280x720. I've got handbrake which will allow me to crop the video down to 720x576 and convert but not to a format I can use. My geriatric video editor (that I spent months getting the hang of using so don't want to change now) can take Microsoft AVI and MPEG2 but Handbrake doesn't appear to be able to output in either of those formats. Is there anything reasonably simple that will do what I need to do or can handbrake do it but I just don't understand what settings I need to use?
+ Reply to Thread
Results 1 to 22 of 22
-
-
Handbrake, based on the ffmpeg kernel, may work. But I don't know if its MPEG2 encoder is a) recommendable in quality, and b) DVD compliant.
I know that the HCEnc is both. But it will prefer AviSynth scripts as video source. Furthermore, I would recommend using the FFMS2 or L-SMASH Works source plugins to handle this AVI, but that makes it a little more complex if you try that for the first time.
And you will also have to create a compatible audio stream, if the AVI does not already contain AC3. A MediaInfo report of your dashcam AVI may be useful to know a bit more. -
That I did not know. In this case you really need a different tool.
By the way, you will probably resize from 1280x720 to 720x576 directly, without cropping (which means cutting something off); the result will be skewed, but this is correct, material on DVD is always "anamorphic" (squeezed in its width), the created MPEG2 video has to be flagged with 16:9 DAR so that players know it has to be deskewed during playback.
If the video has 25 fps as well (720p25), you can probably encode a progressive MPEG2 video. If it had 50 fps (720p50), you would instead interlace after downscaling. Here your MediaInfo report will be useful to know. -
sneaker, that's what I found, Handbrake only gives me the option to output in mp4 or mkv and the editor won't accept them, only mpg or mpeg.
LigH.de, I'm grateful for you taking the time to reply but you may as well have replied in Chinese as I understand none of it. AviSynth scripts are something I have heard mentioned on these forums many times but, having looked at it years ago, have absolutely no idea how it is used. -
-
Here's one very short clip that I'm trying to use https://files.videohelp.com/u/46172/MOV_1269.AVI
If I crop 100pixels off the top and 44 off the bottom I don't lose anything worthwhile, even cropping 560 pixels off the sides (a bit off each side) doesn't lose much. Audio isn't important as there isn't any, the dashcam mic is turned off. -
Why would you want to crop off top and bottom to go from 16:9 (widescreen) to 4:3? Usually you would crop from the sides to get to 4:3 and then resize that to 720x576 (anamorphic). Or do you want to zoom in on the car/license plate? Then I understand.
But anyways: you can crop & resize in AviSynth like LigH said. Then either encode using e.g. HCEnc to MPEG-2 or create an AVI file from that. Either physical or virtual (avfs). -
Because the project is in 4:3, the bulk of the footage is DV AVI from an SD camcorder, I just want to add odd bits from the dashcam. If I crop 144 pixels off the top and bottom and 560 off the sides, I get a 720x576 file that is the same as the rest of the footage.
Remember, I started playing with video back in the days of analogue capture, have 3 Sony semi Pro SD camcorders use the footage to produce 4:3 DVD. I've never even produced a 16:9 DVD, although the camcorders can do it, all they do is crop the height and reduce the vertical pixel count so the quality suffers. -
Let AVSToDVD have it. It uses AviSynth scripts and you can choose the excellent HCEnc as your MPEG-2 encoder. The only reason to make it 4:3, I would think, is if the majority of the rest of the material is native 4:3 (1.33:1). Otherwise I'd encode for 16:9. When making a 1280x720 source suitable for 4:3 MPEG-2 encoding either cut from the sides to make it 960x720 before then resizing to 720x576 or add black to the top and bottom to make it 1280x960 before then resizing to 720x576. If AVSToDVD can't do this directly (and I'm pretty sure it can do the add black way), you can edit the AVS it'll use to do those things.
If I crop 144 pixels off the top and bottom and 560 off the sides, I get a 720x576 file that is the same as the rest of the footage. -
I hadn't thought about adding black top and bottom and resizing. Yes, the bulk of the material is 30 minutes of native 4:3, I just want to add probably no more than a minute of the dashcam footage. I've got various bits of older software, Handbrake and Sorenson Squeeze (full paid for version) but Squeeze doesn't recognise H264 as it's too new otherwise that would be ideal as it's pretty idiot proof.
No I don't. Normally the only video formats I work with are Full D1 SD in uncompressed (or almost) DV AVI and then convert to DVD compliant MPEG2 as a final format. These strange highly compressed formats are something I've never used before which is why I've come back here after over 10 years. -
Nope. M4Vs are MPEG-4, something else entirely and often the video portion in an MP4 container. Handbrake can not do it. And your plan is to edit and encode yet again? Do you care nothing about quality? If you have to make an intermediate encode before the final encode for DVD, it should be lossless.
Up to you, of course, as it's your video. -
Under the video tab in Handbrake I had a choice of H264, MPEG-4 (FFmpeg) and MPEG-2 (FFmpeg) so I selected MPEG-2 with a bitrate of 7000kbs. After changing the file extension from .m4v to .mpg, the video editor (Ulead MediaStudio Pro 7.0), accepted it and the file properties report it as MPEG 2. Here's the same clip after Handbrake https://files.videohelp.com/u/46172/Mov%201269-9.mpg
Yes I do care about quality which is why I normally only ever work in DV AVI and only encode to MPEG as a final format when all editing is finished but in this case, it isn't possible as the source is already highly compressed. Compared with the rest of the footage shot on a Sony VX2100 with it's f1.6 lens made from coated optical glass and a 3 CCD sensor against a £50 dashcam with a tiny (probably plastic) lens and sensor, nobody is going to expect quality. -
An all-purpose media editor like Ulead may accept files with changed extensions to make them appear in file dialog selections.
A DVD authoring tool will not. Most authoring tools will only accept raw/elementary MPEG-2 video streams (not contained inside any container format). HCEnc can produce those. And it is probably also better in distributing the quality over the whole playtime in the constraints of DVD compliant bitrates. I mean ... you did limit maximum and average bitrates (calculated according to playtime and DVD capacity) in Handbrake, did you? But you may still not be able to create MPEG-2 video in Handbrake which is checked not to exceed DVD Video compliant VBV limits. HCEnc instead can do that.
So even if your MPEG-2 video was encoded by Handbrake "successfully", your DVD authoring tool will probably reject it, except it doesn't care about DVD Video specifications (in this case, your DVD Video consumer player may choke on it later). -
As I said, I set the bitrate in Handbrake to 7000kbs so well within the DVD limits. My normal workflow is to start with DV AVI, edit, add titles, transitions, etc and only when it is completed save as DV AVI before importing the final version into my DVD authoring software to convert. This allows me to go back to the uncompressed AVI and edit further if (when) I notice something that isn't quite right. An alternative that I can use is to output from the editing software as DVD compliant MPEG and drop that straight into the authoring software. The advantage of that is that the authoring software gives me more flexibility on the final bitrates so, if I have a project that is slightly over the maximum size for a single layer DVD, I can reduce the bitrate slightly so it will fit.
I've just done a quick test by importing the file into the editor and then getting that to create a DV AVI output file and a DVD compliant MPEG file. Results are below.
Original dashcam footage
https://files.videohelp.com/u/46172/MOV_1269.AVI
Cropped and converted to MPEG2 by Handbrake
https://files.videohelp.com/u/46172/Mov%201269-9.mpg
Output as DV AVI (note the file size!)
https://files.videohelp.com/u/46172/DV%20test.avi
Output as DVD compliant MPEG2
https://files.videohelp.com/u/46172/mpeg%20test.mpg
Logic would say that the MPEG output should be the same quality as the MPEG file created by Handbrake and not require any further encoding but the resolution has been reduced from 960x720 down to 720x 576, hence a marginal drop in file size and the reduction in quality even when non-square rendering is used.
In both cases the quality has suffered and the video looks soft but when the source was a horrendously compressed format in the first place, I wouldn't expect any better. Despite what CSI would have you believe if the quality isn't therre in the first place, you can't improve on it. As I say, it's from a cheap dashcam with a horrible CMOS sensor so as well as the poor quality has reflections from the inside of the windscreen, dead flies on the windscreen from a 900 mile journey and the vertical lines that are the elements of the heated windscreen in my Range Rover. If I ever do a similar project I'll just mount a second VX2100 on the dash but would still get the reflections, flies and heating elements visible (unless I can work out a way of safely mounting it on the bonnet of the car). At the time I had never intended using any forward facing, moving, footage and only realised I'd got extra footage available later, even if it is from something that is only there in case of an accident. -
This is more or less irrelevant, in theory. You might be lucky that the result never violates the "Video Buffer Verifier", not even for one GOP during the whole playtime. Or you are unlucky and an authoring tool rejects it for this one GOP (half a second) that exceeds limits. Well, OK ... with this content (little motion, slow changes), chances to exceed limits will be very small, you will most probably be lucky. And the bitrate distribution is probably rather smooth, 1-pass ABR won't look too bad, compared to the still better 2-pass VBR method HCEnc uses. So all you need to care about is the maximum playing time at 7 Mbps.
Your audio is MP2 stereo 48 kHz; that should be compatible to most PAL DVD players. But depending on the original audio format, AC3 may preserve better quality and compatibility.
I'm still curious; if the dashcam recorded with 50 fps, producing an interlaced DVD video will preserve fluid motion. It's just a little issue that DV uses BFF dominance, while TV and DVD often prefer TFF (but not necessarily). If you produce progressive 25 fps video, tough, this is not very relevant either. -
2 pass is an option that I may use but at the moment just getting it into a format Mediastudio will accept was the main aim. The version of Mediastudio I have is 7.0, there was a later version 8.0 which could handle HD (and had a slightly more modern looking interface) but as I don't have any HD sources it didn't seem worth updating and after that Ulead sold out to Corel who made it into an all in one package rather than a dedicated editor as it originally was. Audio is unimportant as the main footage from the VX2100 is 48kHz, 16 bit and the final output will be AC3 Dolby Digital but as there was no audio on the dashcam footage I didn't bother setting that and left it at the default. The dashcam records 720p 50 fps so dropping it to 25 fps interlaced is going to retain as much of what little quality is there in the first place. The final thing will be around 20 minutes long but will probably use no more than a minute of the dashcam footage so not that important, it's just being added to give a bit of context and continuity.
I must admit, I hate the output from CMOS sensors, the way they can't handle movement and distort, you can see it on even the expensive ones like a GoPro. I've thought about upgrading to the Sony HVR-Z1E which will give me 1080p HD capability but as I already have a pair of VX2100s and a VX2000, and at around £500 a time for good used ones, it isn't going to be cheap. That would give me HD with backward compatibility if I don't change them all at the same time but the low light capability on the newer ones is around 3 lux compared with 1 lux on what I have and low light capability is something that is very important for the usual stuff I shoot. -
Your source is 720p30 , not "50p" . It looks like it was converted to to "25p" in handbrake by dropping frames => jerky . There are other options, but there aren't any "perfect" ways to convert the framerate - pros/cons
If you could import "microsoft avi" into mediastudio , did you try installing an AVC VFW decoder to import the original footage? NLE's from that generation used system installed VFW decoders. For example you could install x264vfw and enable the decoder. Another option might be ffdshow (probably 32bit , I'm guessing mediastudio 7 was x86), and enabled the AVC/h264 decoder (set to "libavcodec" in the VFW configuration) -
Advertizing crippleware when really unlimited free software is available too?
Similar Threads
-
Converting h264 to avi
By ziggy1971 in forum Video ConversionReplies: 12Last Post: 22nd Apr 2016, 18:13 -
Mpeg2 1920x1080 or H264 for Bluray format
By pchan in forum Authoring (Blu-ray)Replies: 3Last Post: 22nd Jun 2013, 06:52 -
Virtual dub: converting 4:3 to 16:9 without cropping-smart resizing filter
By Mållgan in forum Video ConversionReplies: 16Last Post: 16th Apr 2013, 17:23 -
Converting to H264 with CUDA
By magnu in forum Video ConversionReplies: 2Last Post: 2nd Oct 2012, 03:40 -
M2TS Creation (Either in h264 or Mpeg2 format)
By frmys in forum Video ConversionReplies: 3Last Post: 28th May 2012, 04:41