How to encode 720P HD files for Youtube.

Demistate

New member
Youtube supports up to 4K (4096 x 2304) playback. Users can select their desired resolution if available. Youtube just announced that you can upload up to a 15 minute clip now.

One final note: if you’re uploading a video that was previously rejected for being too long, you’ll have to go into “My Videos” and delete it before attempting to upload it again. Thanks and happy uploading!
WATCHHD.jpg



You can see my examples here:

http://www.youtube.com/watch?v=IDSFHVXOzow&fmt=22 (Fraternity house HD clip, HVX200 + M2)

http://www.youtube.com/watch?v=-Bn4wLDgqW0&fmt=22 (Dog’s Journey HD, Bare HVX200)

http://www.youtube.com/watch?v=-W7D_4m1j1Y&fmt=22 (Saints Row 2, Barack Obama V. John Mccain HD, Video Game HD footage)

http://www.youtube.com/watch?v=9iiwWqoqgI4&fmt=37 (1080P test from a downsampled 5d Mark II image sequence)

http://www.youtube.com/watch?v=5Z9QwPODcXQ (Canon t2i 1080P Horror short)


To send a direct link with HD enabled, add &fmt=22 added to the end of the URL for 720P and &fmt=37 for 1080P.


BEST SETTINGS TO GET YOUR VIDEO IN HD ON YOUTUBE:


  • Frame size up to 4096 x 2304
  • Less than 15 minutes
  • h.264 video codec
  • AAC Audio codec
  • .mp4 container
  • 2-pass encode
  • HIGH PROFILE @ level 5.1
  • Average bitrate as high as you can go without filesize over 2048 megabytes. I recommend a 10+ megabit per second video stream.
  • Audio Bitrates at 320Kbps and higher. Surround sound is supported, but will be downsampled to stereo at this time.
You should be able to do 27 MegaBits per second, with a 320 KilloBits per second audio track and not hit the 2048 MegaByte limit for a 10 minute film. Most hollywood Blu-Ray movies are 21 MegaBits per second average, so this is very very good quality. Keep in mind that uploading 2048 MegaBytes to Youtube will take a few hours on an American cable modem service.

You can use these same deliverables for Vimeo as well (Up to 1920x1080)

OTHER FORMATS DO WORK:

If you can't export h.264 above because of your encoding software here are some alternatives.

·WMV9 2-pass at 10,000Killobits per second Average Audio at 320Killobits per second
·Quicktime MOV files (QUICKTIME IS NOT A GOOD DELIVERY MEDIUM. You will get gamma shift and your video will look ugly. You have been warned.)

Check this site if you want to embed HD videos into your site:

http://www.mydigitallife.info/2008/...gh-definition-youtube-videos-fmt22-code-hack/

STANDARD QUALITY LOOKS BAD:

Tough Luck. Youtube is a free service and they are free to encode their videos however they want. Try other video sharing services, or add &fmt=18 to the end of the URL for a higher quality, 480P version.

MY VIDEO STILL LOOKS BAD, WHAT ELSE CAN I DO?

Try hiring a professional compressionist to create high quality deliverables for Youtube. A Professional will be able to pre-process your footage so that it compresses better for video sharing sites. Final Cut Pro/Adobe Premiere Pro are not good pre-processing tools and will give you sub-standard results if you do any scaling, de-interlacing, or color space conversions.

The answer to this question changes faster than I can update this thread.

YOU'RE WRONG ABOUT X.

I've tried to keep the information in this post as short as possible. There are some caveats to all kinds of file encoding. Let me know if you feel like I should change something.
 
Last edited:
Those videos in Youtube look great. The only problem I have with them is the file size. They take too long to view.
 
Also what format would you recommend filming in to produce high quality HD videos online, 720p or 1080i. Thanks
 
Shooting 1080P is always ideal, and then downsample with a good scaler like spline36 in Avisynth down to 720P.

Shooting interlaced always causes problems when trying to convert to progressive. It will never look right. Shoot 24pa in 1080 or 720P on your HVX.
 
I have a Sony HDR-FX7E High Def video cam. It can shoot in 1080i/Dv only. Would I be able to scale down to 720p via compressor? A 13 sec file I just tried to compressed with a 5000kbits, created a 15mb video file. Thats a little large for embedding into a website?
 
I have a Sony HDR-FX7E High Def video cam. It can shoot in 1080i/Dv only. Would I be able to scale down to 720p via compressor? A 13 sec file I just tried to compressed with a 5000kbits, created a 15mb video file. Thats a little large for embedding into a website?

You'll have to run it through a deinterlacer, which always takes away quality. I'm not familiar with how good Compressor's pre-processing capabilities are.

Deinterlace the source, and scale it down to 1280x720. You should get acceptable results.
 
Last edited:
Please add this to the original post:

It is VITAL that your audio's sampling rate be encoded at 48kHz, not 44.1kHz or anything else. Right now there is a glitch with YouTube HD videos which will cause your video to skip every few seconds and it ain't pretty. Stick with the standard digital video 48kHz setting and you'll be gold.
 
adamr316, are you saying the 48kHz is required for any uploads or only the non-reencoded versions using the method above?

Also, can anyone confirm if the loophole for getting in without reencode is still open?

Demistate, can you please publish your exact query or command line for FFMPEG? I have tried to replicate the settings using HandBrake and when YouTube processed the file, I got an error back saying the file could not be processed.
 
I never had issues with standard def videos encoded at a 44.1kHz sampling rate. When YouTube went HD...that's when I had to start using the standard 48kHz. The only reason I used 44.1 was because I figured I'd use those bits more efficiently but YouTube HD had issues with it.

I'm not sure about your other questions and re-ended material.
 
Youtube x264 HD looks great but normal quality worse

Youtube x264 HD looks great but normal quality worse

Hey i had never heard of x264! Its amazing. I was having all sorts of trouble with h.264 with color shifts and quality.

My source is 1280x720 23.98 fps.

Although the HD looks fantastic the normal quality looks worse than earlier non-hd type uploads. Any advice?

Also note I am on a mac and downloaded the x264 codec from apple
http://www.apple.com/downloads/macosx/video/x264encoder.html

Can you specify the difference between "highest quality for now" and "higher quality down the road" Some of the specification didn't necessarily seems to translate to making these differences in quicktime.

Thanks for the x264 tip!
 
Although the HD looks fantastic the normal quality looks worse than earlier non-hd type uploads. Any advice?

As of today: June 1, 2010. 360P quality looks pretty good on Youtube. This is the default for the Desktop player. Streams meant for 2g service (like iPhone) will not look so great. There is nothing you can do about this since its a 64kbps stream total for audio and video. It's like streaming video quality over dialup.




Also note I am on a mac and downloaded the x264 codec from apple
http://www.apple.com/downloads/macosx/video/x264encoder.html

This plugin is amazing. Does it work in Apple Compressor for outputting from a FCP timeline?
 
Last edited:
thanks, zeo transcoding, not ajust a matter of perception

thanks, zeo transcoding, not ajust a matter of perception

I broke this into a few numbers...

1) Thanks for the advice. Yes I think the x264 plu will work because it shoes up in QT. But haven't tested yet.

2) "Highest quality now basically allows you to upload your own file with zero transcoding."
I guess i don't really know how to achieve this since I am doing everything in qucitime pro on a mac. Let me know if there is any further info on this approach.

3) I don't agree that it is a matter of perception. There are quite a few discussions about how Youtube HD is compromising the quality of the normal quality and making it worse than average. here are a few:

http://help.youtube.com/group/youtu...=hd+makes+normal+quality+bad#89a2ef26c77054ed

http://help.youtube.com/group/youtube-issues/browse_thread/thread/9fff52cb28a3d4c1


And a new answer from my post...
http://help.youtube.com/group/youtu...lnk=gst&q=normal+quality+bad#98c1c76514d2080a


Here are examples of videos that good good both in Youtube normal quality and in HD.

http://www.youtube.com/watch?v=RDfpd8GV9dI&eurl=http://forums.creativecow.net/thread/117/857005

http://www.youtube.com/watch?v=Qq8Uc5BFogE&eurl=http://forums.creativecow.net/thread/117/857005

http://www.youtube.com/watch?v=UyYIyh5ObYM&eurl=http://forums.creativecow.net/thread/117/857005

There must be an answer somewhere.

Jesse
 
3) I don't agree that it is a matter of perception. There are quite a few discussions about how Youtube HD is compromising the quality of the normal quality and making it worse than average. here are a few:

http://help.youtube.com/group/youtu...=hd+makes+normal+quality+bad#89a2ef26c77054ed

http://help.youtube.com/group/youtube-issues/browse_thread/thread/9fff52cb28a3d4c1


And a new answer from my post...
http://help.youtube.com/group/youtu...lnk=gst&q=normal+quality+bad#98c1c76514d2080a


Here are examples of videos that good good both in Youtube normal quality and in HD.

http://www.youtube.com/watch?v=RDfpd8GV9dI&eurl=http://forums.creativecow.net/thread/117/857005

http://www.youtube.com/watch?v=Qq8Uc5BFogE&eurl=http://forums.creativecow.net/thread/117/857005

http://www.youtube.com/watch?v=UyYIyh5ObYM&eurl=http://forums.creativecow.net/thread/117/857005

There must be an answer somewhere.

Jesse

I found this interesting. It might explain what's going on:

The other thing is that 4x3 normal is encoded as a 320x240 flash,
while widescreen normal is encoded as 320x180. Since the YouTube
player has a vertical dimension of 360, the widescreen image is being
scaled up more that that of the same 4x3 image.

Since it's youtube's service there is really nothing you can do about how they encode. If you don't like it there are other video sharing services online. Google could always re-code the "base quality" for these videos later down the line and make them higher quality at "normal" eventually, but for now you get what Youtube gives you.
 
I think you are right. From everything i found this is an unsolved bug. Basically Youtube's HD encoding pipeline is causing the normal quality to be worse than average. Because HD was available I became fixated on solving or finding the absolute right method. I searched for several days and I think it may just be the way it encodes. I am going to down res and make my work available in higher quality for now.

However-- if anyone stumbles on this and finds a solution to make HD and normal quality both look good, Please post it here as well!
Thanks!
 
Hey, I have an issue with an audio out-of-sync thing when I upload

I encoded the audio through itunes 256 AAC, and I matched it against the original wave and it was exactly the same, so I mux the MP4 and M4A files together and then I checked the audio again in my editing program, still the same as wave, so I uploaded it to youtube, and it seemed a bit off sync, so I downloaded the youtube video and checked the audio against the wave again and it was off by almost half a second.

so I thought I'd give MP3 a try and see if youtube desyncs that, but it seems EVERY mp3 encode I do changes, no matter what I use :S

http://img10.imageshack.us/img10/7103/02132009021857sk9.jpg

Wave in middle, MP3 on top, mp3 try 2 on bottom (I used lame mp3 encoder through megui there, before I had tried the mp3s in vegas and in CDex)

Is this what MP3s just do? Btw, that MP3-Wave audio wave comparision is exactly what the uploaded youtubes audio looked like when compared with original M4A file...


anyway, I don't even need MP3, just a way to upload to youtube WITHOUT them desyncing my audio lol
 
Hey, I have an issue with an audio out-of-sync thing when I upload

I encoded the audio through itunes 256 AAC, and I matched it against the original wave and it was exactly the same, so I mux the MP4 and M4A files together and then I checked the audio again in my editing program, still the same as wave, so I uploaded it to youtube, and it seemed a bit off sync, so I downloaded the youtube video and checked the audio against the wave again and it was off by almost half a second.

so I thought I'd give MP3 a try and see if youtube desyncs that, but it seems EVERY mp3 encode I do changes, no matter what I use :S

http://img10.imageshack.us/img10/7103/02132009021857sk9.jpg

Wave in middle, MP3 on top, mp3 try 2 on bottom (I used lame mp3 encoder through megui there, before I had tried the mp3s in vegas and in CDex)

Is this what MP3s just do? Btw, that MP3-Wave audio wave comparision is exactly what the uploaded youtubes audio looked like when compared with original M4A file...


anyway, I don't even need MP3, just a way to upload to youtube WITHOUT them desyncing my audio lol


Mp3 and AAC can add an audio delay when encoding (by up to 24 frames!) Most video encoders that also encode the audio know the delay and will compensate for it, however encoding with separate applications is not recommended since you wont know the correct delay to trim or pad the audio file with for sync with the video.

If you're using AVIsynth with a DV file, I noticed every time I had any sort of still frame or null frame, I would loose sync with audio, so you may want to try and film "black" on your camera (lens cap on, then record) and place that behind any titles so that you don't have any non-moving parts of your video. Its just a limitation to the free encoder utilities.
 
Back
Top