Best Way To Convert Avi To Mp4 Without Losing Quality

5 views
Skip to first unread message

Trinidad Baltzell

unread,
Aug 4, 2024, 5:15:40 PM8/4/24
to centdalovab
Im stuck on which settings would be best for the conversion. I want to retain full quality. Do I just convert with the original settings and not change anything or is there any specific thing I need to change?

When you're using Handbrake to convert from one container format to the other (i.e. MKV to MP4 in your case), Handbrake will re-encode the video. See also the respective feature request that would have enabled video passthrough:


Since passthrough is not possible, ask yourself: Do I need to re-encode? If you only want to change the container from MKV to MP4, you usually don't need to encode anything, you just change the "wrapping" around the video. This doesn't lose quality, and it'll be a much faster process.


However, there's a big caveat: this only works if the audio and video codecs are supported in the target (MP4) container, which is the case for H.264/H.265 and AAC, for example, but not for many others. Also, subtitle format support for MP4 is different from MKV, and actually quite restricted, so this command may fail.


If this command does not work, and if your input uses the wrong codecs for the output container, you will probably have to re-encode. In this case, the codecs will be adapted to the output container.


To understand why this is necessary, it's important to learn the difference between video codecs and containers. This will help you understand why changing containers works and why the containers MP4 and MKV have little to do with video codecs, actually.


You can (usually) not retain full quality when encoding a video that was already encoded. This is because the original has already been compressed by throwing away information, and by doing it again you're introducing generation loss.


Often, you want to re-encode video when for example its dimensions change, or you need a specific bit rate to squeeze your video stream into, or your original video uses a codec that you can't play for whatever reason.


So, if you load your MKV video into Handbrake, and re-encode it with x264, the H.264 encoder Handbrake uses, store it in an MP4 container, you are going to lose quality no matter what, unless you set the bitrate or quality factor so high that you won't (really) see the difference. But then, the file size will be bigger as well.


Sane CRF values are from 19 to 24, where lower means "better". So, you could try with a Rate Factor of 19. Also, make sure to set the "High" profile, which enables the encoder to use all bells and whistles and optimize the quality for a given bit rate.


It seems to make no sense to force 320k, since some files will become many times larger than they need be. Similarly it makes no sense to destroy all my 320k files by converting them to something much lower than 96k. (At the moment, the files are being converted to about 50k.)


Does anyone know how I can do this? What I really want to do is tell ffmpeg to convert all m4a files in a directory into mp3's while retaining the current audio quality as best it can. (Of course there is likely to be some extra losses from converting from lossy to lossy file formats, above that which would be expected when converting from a lossless to lossy format.)


Update: Even though I don't recommend that, unfortunately, some low-quality and obsolete hardwares' developers still produce appliances which use mp3 and some people still request for that format... Agrhhhh, here it is:


Using existing answers as a basis I wrote a bash script which should do exactly what the question asks on an Ubuntu machine (tested on 16.04). You'll need to install avprobe which is in the libav-tools package. You can install avprobe with the following command


This requires a slightly different (and simpler) way to parse, so I wrote my own script to do that, with a twist: in my case, I have lots of albums on my Mac, some of which are in M4A, and which require converting to MP3 for my low-end car audio player. There are at least a gazillion tools that do that, some even just GUI-based front ends to ffmpeg but nothing like 'being in control' and do it from the bash!


If you work at 48 KhZ and at least 24-bit in the input file (from a file editor i.ex.) -q:a 0 will reproduce the 20 kHz at no so large file as flac... But low quality audio unless you reduce the noise from high frequencies (hiss) by dithering or nose reduction audio editors, created in conversions, that will be reproduced, then will use data file as a inaudible HF, but expensive noise.


Hello, I recently encountered a problem and hope to get your help. I have a bunch of HEIC format photos that need to be converted to JPEG format, and the operating system is Windows 11. I hope to maintain the original image quality as much as possible during the conversion process, and because there are a lot of photos, I hope to find a way to batch convert HEIC to JPG without losing quality. I have tried some online tools and software before, but I always feel that the quality of the converted pictures has declined, or the operation is not convenient enough.


I've had to batch convert pictures before and used TuneBro HEIC Converter, which I still use. This tool is really good and allows for high-quality conversions, so you can import your HEIC files and export them as JPG or PNG. It also allows you to adjust the quality settings to ensure that the images are not distorted.


@LukeHaverson2130HEIC images are not supported by Windows 11 or Windows 10 by default. However, if the Photoshop was installed on the PC, you can use it to convert heic to jpg without losing quality. You can only do this one by one.


I used iCloudConvert to convert a batch of HEIC to JPG, and the experience was pretty smooth. Just find the service online, drag the files onto it, select the option to convert to JPEG, click convert, and then download them after it's done. The platform is really intuitive, there are no complicated steps, and the conversion speed is pretty fast.


However, if there are any disadvantages, it is that sometimes when there are a lot of files or the Internet speed is not good, the upload and download will be slower, which is sometimes a bit anxious. Also, although they say that they protect privacy, I still feel worried because the files are uploaded to the Internet. So I usually don't use this method to process particularly private files.


I once needed to batch convert HEIC photos to JPEG, and I was using Windows 10. I found that the Windows Photos app can easily handle this problem. First, I opened the HEIC file directly in the Photos app, which has a very intuitive interface.


I often need to bulk convert HEIC photos to JPG format when using my iPhone. I found a simple trick to send the photos to myself directly by email. This method is super convenient and does not require installing any additional software.


It is also very straightforward to use: I just need to select the HEIC photos I want to convert in the album, then click the share button like sharing anything, and select the email app. In the email writing interface, after I add the photos, the iPhone will automatically prompt me if I want to convert HEIC to JPEG format and send them. I choose "yes", set the email address to my own, and send it. Not long after, the email arrived in my inbox, and when I opened it, I saw that the photos were already in JPEG format.


The advantage of this method is that it is simple to operate, and there is no need to worry about the quality of the pictures, because the quality is basically the same during the conversion process. Of course, this method is more suitable for converting a few pictures occasionally. If it is hundreds or thousands of HEIC pictures, you may need to consider other more automated batch processing methods.


I often use Google Photos to manage my photos, especially when I need to convert photos from HEIC to JPG format without losing quality on Windows 11. This method is not only simple, but because Google Photos is cloud-based, I can access my photos anytime, anywhere.


One of the great things about using Google Photos is that it's not just a conversion tool, but also a powerful photo management and backup solution. I don't need to worry about losing photos due to device loss or damage. At the same time, it also provides some basic editing functions, which is very convenient when I need to quickly adjust photos.


@LukeHaverson2130 There is a HEIF Image Extensions app from Microsoft Store for opening HEIC images on Windows 11. It is a software component that allows Windows devices to read and write files that use the High Efficiency Image File (HEIF) format, including the commonly used HEIC format.


Users can download and install it by searching for "HEIF Image Extensions" in the store. Once installed, it integrates with the operating system. After that, Windows 11 can natively view HEIC images and convert HEIC images to JPG or JPEG.


As an user who converts HEIC images to JPG frequently on a Windows 11 PC, I must say a dedicated HEIC image converter is much better than online conversion service, which you might come across in search engines.


First, Online services don't provide the same level of control over image quality settings as dedicated software applications. Converting large numbers of HEIC files or high-resolution images can be time-consuming due to upload and download speeds. Many online services have file size limits, which can be restrictive for large batches of photos.


@ToddRiveraI totally agree with you. Uploading images to an online heic to jpg conversion service means you are sharing your personal or sensitive photos with an unknown personal or company. This can raise privacy concerns, especially if the service does not have clear data protection policies. Online services might be vulnerable to hacking or data breaches, potentially exposing your images to unauthorized access.


Desktop HEIC to JPG Converter apps often provide additional features such as batch processing, image editing, and advanced settings for adjusting quality, resolution, and metadata. You can batch convert HEIC to JPEG offline with PC software, which is useful if you have limited or no internet access.

3a8082e126
Reply all
Reply to author
Forward
0 new messages