DO NOT reduce AVI file sizes that go up to YouTube
Our Reggie Dentmore just posted an article showing you how to reduce an AVI file’s size so as to make it upload to YouTube more quickly. My advice is that you DO NOT reduce AVI file sizes that go up to YouTube anymore than you have to and the reasons are as follows:
1. There’s a huge cost for that reduction. What you’re losing is “definition” (sharpness of image) and fidelity. When you reduce an 80mb video down 3mb you’re going to lose a lot of quality and in the final analysis, you do want to give your viewers the best possible viewing experience on their equipment right?
If you really want to reduce your file sizes, embed a mpg music file rather than a wav format audio file. That’ll save a huge chunk of data without loss of visual quality. YouTube converts all WAV formats to MPEG standard audio files anyway so embedding a WAV is really a waste of effort anyway.
2. YouTube is a streaming service and this has technical implications that needs to be factored into the equation. The factors that you need to consider are as follows:
a. A streaming service basically crams everything into a series of packages and sends it from their servers to your PC and will do it as quickly as both machines can cope with the data transfer with no checks for missing packages. Missing packages translates into skipped frames. So if you’re watching a video and sometimes it gets choppy, your connection is dropping frames.
A TCP/IP transfer like a file download is different, here if a package is missing the package is resent. So it may take a bit longer but you get the whole deal.
Don’t mix up the two protocols.
b. When you upload any video file to YouTube, their server will reprocess whatever you upload and make several copies of the video you uploaded. These different versions of your video gets sent out depending on the bandwidth available to the requesting PC. In other words, if you have a high speed broadband connection, YouTube will send the best quality version of the video to your PC. On the other hand, if you have a dial-up connection, their server is going to send you the most low quality version.
Also their video compression service/servers even factors in what kind of device is requesting the video – so they can accommodate for PCs, HDTVs and SmartPhones, etc.
c. So what’s the difference? It’s compression ratios and this means lose of data which in visual terms means loss of definition.
d. So factor these into your equation before you upload to YouTube. How much more definition are you willing to lose after their server recompressed your hard work?
e. Therefore, if you want your viewers to see the best possible version of your video do the following:
Render your videos to at least the size of your monitor screen (ie. full screen).
If you want to go HD then see here for more details on HD video file sizes; documentation.apple.com/en/finalcutpro/usermanual/index.html#chapter=C%26section=6%26tasks=true
In a nutshell I use 1280×720 for my videos, but if you can go 1920×1080, use that for HD quality videos. If you use either of these sizes there will be a “HD” notation next to your video on your YouTube file management page and trust me when I tell you that it does make a difference to the quality of the video served if your video has this notation. YouTube want people to watch their videos full screen and on large monitors.
Use a “sensible” compression ratio.
Each compression codec has a recommended setting for “hi def” videos, find out what it is and use that.
I use the Xvid Codec to compress my videos. It is open sourced (free) and one of the best codecs out there. I only use one of two settings, both defaults.
A setting for “standard” videos which balances economy of file sizes versus quality of imagery – these still qualify for a HD rating on YouTube if I render to one of the HD standard sizes. Most of my videos are around the 80mb mark when rendered with these settings. These all display fine and at the quality I expected when hosted by YouTube. Nice and sharp with good strong color renditions.
Or for maximum image quality I use their standard HD output setting. The file sizes for these can weigh in at around 200mb so I rarely use this setting, plus I know roughly what YouTube’s server will probably do if they encounter one of these files – to be fair they’ve done a pretty good job compressing these buggers, too.
Upload videos to these types of specs to YouTube and generally you will get the best results.
YouTube are the experts at what they’re doing. Let them figure out what the best compression ratio is for your video and the available bandwidth plus intended viewing device: PC, smart phone, HD TV or whatever. Just give them a reasonably high quality video to work with and you’ll get the best out of their service if you follow this advice.
A footnote from LearnMMD’s Kazuki Matsuoka…
I strongly agree with him.
I never ever try to minimize the file size; I have too much of a long history of experience in videos that are poor in quality and they are crappy.
Lower the space, the lower the quality, it’s a fact. Doesn’t matter how much space I may have, I am much happier with my HD 500MB videos. If I don’t have enough space, I burn them onto a DVD disk. Done– Kazuki M
why are my renders so large some can take up to 64gb
You must be using RAW as your video converter. … instead, choose a codec like UTvideo.
I rendered an AVI that is 6GB for some weird reason. Youtube is glitching out for me, and I’ve spent hours trying to upload with no success. How do I make the AVI file smaller without losing quality?
6Gb is a too-huge file! … What compressor did you use…RAW? … Not good… See this tutorial… might help you choose a codec compressor… and mid-way down, it discusses a software “HandBrake” … I have been using that with nice success. I render to AVI using the UTvideo codec… and the finished product will not upload to YouTube, but I get very nice quality and amazingly small file sizes after I run that video through Handbrake… it saves to an Mp4 and will upload to YouTube.
I have something to say about your first point. You said: “If you really want to reduce your file sizes, embed a mpg music file rather than a wav format audio file.”, however, as far as I know the only format that MMD accepts is WAV. Thus, using other formats would require to use an external tool to mix the audio and the video. VirtualDubMod could do the job and it has an option called “Direct Stream Copy” to process the video which will leave it as it is without re-encoding (Which means no quality loss). However, using that approach may cause audio de-sync.
Some MMDers DO keep the audio separate from the video… rendering to AVI without sound and use a video editing program to add an mp3 soundtrack. I have found that my method allowing MMD to render to AVI with the WAV soundtrack yields a huge file (because of that WAV) and then running it through the Prism Video Converter gets me a smaller file size… the “video portion” passes through the Prism system as “native” and the sound (WAV in my original animation) is encoded as mp3 as the new video is created… so the smaller finished file size is due to the mp3 replacing the WAV in the finished video file.
ah i see
My advice is without experience since I can’t get video output from MMD to work in Wine, but ffmpeg is good at avoiding desync if you’re aware of what the input files are like.
So even if you start at frame 300 of a motion, you can still sync it with external audio. That’s 10 seconds, so you want to sync it with external audio in mp3 format (or .m4a etc.) that would start at frame 0, you tell ffmpeg to start at 10 seconds in, and it will treat that as time 0. If you were copying both video and audio without reencoding either, the command would be
ffmpeg -i video.mp4 -ss 10 -i audio.mp3 -c copy -movflags faststart output.mp4
If the audio is already combined with a video, then this will copy a little bit of audio before the start, giving it negative timestamps in mp4 format. This might happen in some other cases as well. (It happens when trying to seek to opus format audio in YouTube and copying it.) It could also copy the second instead of the first, if the second is higher quality. In this case, you would want to tell it to trim everything before time=0, and to use the first video stream:
ffmpeg -i video.mp4 -ss 10 -i video_and_audio.mp4 -c copy -movflags faststart -ss 0 -map 0:v -map 1:a output.mp4
‘-movflags faststart’ is used for an mp4 file to let playback start immediately, instead of when the end of the file becomes available, which lets YouTube start processing it as soon as you start uploading.
Sometimes MMD videos with ‘canned’ motion on YouTube are out of sync, but I don’t know where this is happening.