Showing posts with label format. Show all posts
Showing posts with label format. Show all posts

Tuesday, 12 February 2013

4K codecs - the good, the big and the ugly. Part 2

The first part of this blog looked at the file sizes of a 1 second 4K video clip using various QuickTime codecs. This part looks at the image quality of the codecs that use an efficient lossy compression system. Some codecs can compress an image and uncompress it without any loss of information (lossless compression), but these produce extremely large file sizes and I have left them out of this test as they should, in theory, show no difference to the original.   

The codecs compared here are GoPro's Cineform, Avid's DNxHD, MJPEG A, MJPEG B, MPEG 4 and Photo JPEG. Here is the table of file sizes for the various versions I made:


File sizes of 4K 1 second clip
Here is the link to the 1 second clip at HD 1920x1080 size in the MPEG 4 codec at 90%.

I made 2 JPEG (100%) stills of the first frame of the clip. One is the full size 4K image and the other is a 640x360 pixel crop with the image zoomed up to 200%. The cropped image is the top of the tower with the crane by the side. All the images are shown below, but I also made a stack of the crops in Photoshop and sliced out the layers for a comparison. 


Quality of various codecs 90% quality. 200% zoom and cropped
I haven't included MJPEGB here because it is no different from MJPEGA, but both MJPEGs show a large variation in the original colour, lifting the gamma significantly. All the other codecs were consistent and matched the uncompressed version.


The original purpose of this test was to see if the Avid DNxHD codec was suitable for 4K use but when I saw how poor the quality was I looked at all the other codecs to see what was wrong. You can see from the sliced picture how blurred the image of the crane has become, but the MPEG4 version is as sharp as the Photo JPEG image below. I was surprised when I looked at the file size how much DNxHD was compressing the image because I hadn't seen such degradation when editing high definition material and the file size is larger than MPEG4. I rendered out this clip in 1920x1080 with the codecs again set to 90% quality. The DNxHD clip was 44 MB in size and the MPEG4 was only 14 MB in size.



To be precise the HD version of the DNxHD codec was 44,808 KB in size which is exactly the size of the 4K version, which gave the solution. The DNxHD codec is only designed for the 1920x1080 video space and when the image dimension goes beyond that the pixels are duplicated (or more) to fill in the gaps, hence why it is blurred and the file size doesn't increase.

I think this is a mistake and Avid should limit the dimension the codec can produce, like H.264 does. Or it should ignore file size and produce a similar quality of image that the other codecs show here. I assume Avid will come up with a native 4K codec very soon which can be used in the next generation of cameras such as the Blackmagic Design Cinema Camera and their edit tools.

Meanwhile the best solution for moving 4K videos around the web appears to be MPEG 4 because it scales well, reproduces the original colour and is the smallest of all the options. However I hope that the GoPro Cineform codec becomes more widely used (and free) as it is robust and platform agnostic. And of course we wait for the launch of H.265 which is likely to be the choice of the broadcast world.

For videographers producing 4K clips the only solution is to use a lossless codec 

Here are the JPEG images of all the test clips. Please download them to compare.


Cineform 90%
Cineform 90% crop with 200% zoom
Avid DNxHD 90%


Avid DNxHD 90% crop with 200% zoom
MPEG A 90%
MPEG A 90% crop with 200% zoom
MPEG 4 90%
MPEG 4 90% crop with 200% zoom
Photo JPEG 90%
Photo JPEG 90% crop with 200% zoom

Monday, 28 January 2013

Another new video format - H.265

For stock footage and stills of London go to London Photography and Video. 

There are nearly as many video formats in existence as there are spoofs of the Gangham Style video and they make a video editor's life hell. The producer's simple question of "could you just export a file for me to send to the client" is the start of a round of "fifty questions", forty-nine of which the producer doesn't know the answer to and the one he guesses is usually wrong.

There is no point or indeed desire to explain things like codecs, wrappers, bit-rate and dimensions to a producer who wants a 23 minute long video in HD quality but small enough to e-mail. Unless you want them to go and make a cup of tea. So the editor (me) takes an educated guess and produces something that will play on the client's Blackberry.

So when a new format emerges from the ITU that will "ease the pressure on global networks" I am likely to crawl into a dark corner and order more tea. But this one could be a goer since it is the successor to H.264 the (not very snappily named) codec that is now the lifeblood of the internet video world (80% of all video streamed on web is in H.264) and is liked by Apple and Microsoft OS's alike. 

The recently announced, excitingly named Recommendation ITU-T H.265 or ISO/IEC 23008-2 or High Efficiency Video Coding [I think I'll stick to H.265] is twice as efficient as its numerically challenged cousin at crunching numbers which means similar quality files will be half the size. At the moment a 23 minute programme (which is all you get in a 30 minute slot on a commercial station) in H.264 at full HD resolution creates a file that's about 1.4 Gb in size. Download four of those and your 5Gb 4G limit is exceeded and that is going to cost you, but with H.265 you get twice as much for your money.

Now I am very interested in how 4K television develops (don't get me started at dinner parties) and this new codec is designed with 4K and even 8K in mind and will start to make it possible to watch online over a fibre connection. It will take a while to phase the new format in but once it is on my desktop and my client's tablet, it is one less question to ask when exporting a video.

Sunday, 21 October 2012

To 4K and beyond... to Ultra HD


This week the Consumer Electronics Association (the CEA) made an announcement that the next jump in TV resolution will not be called 4K (as it has be called for the last four years) but Ultra HD or UHDTV (according to the ITU). Now before I get swallowed up by TLA's or even FLA's (five letter acronyms) I tried to work out what format I will be working with for the next eight years before 8K is expected to arrive.

With the help of my rusty calculator I did a few divisions and multiplications and worked out that the minimum resolution of 3840x2160 is indeed 16:9 but is a bit smaller than the 4096x2304 that is "real 4K". However it is both double the 1920x1080 we know and love and the format specified by the Society of Motion Picture and Television Engineers (SMPTE for FLA lovers) in 2007.

But the CEA press release reads as follows:
Minimum performance attributes include display resolution of at least eight million active pixels, with at least 3,840 horizontally and at least 2,160 vertically. Displays will have an aspect ratio with width to height of at least 16 X 9. To use the Ultra HD label, display products will require at least one digital input capable of carrying and presenting native 4K format video from this input at full 3,840 X 2,160 resolution without relying solely on up-converting.

So that's a minimum resolution. Sony have declared that they will retain the 4K description and call their products 4K UHD, which presumably means their TVs will be 4096 pixels wide and 2304 pixels high. So what will broadcasters choose? My money is on 3480x2160 which reduces an image by nearly 2 million pixels a frame, quite a saving. Sony will just have to upscale, which is never a pretty job.

All of this makes producing stock material for the future no easier than it is now with 1080p, 1080i and 720p all being used in the real world. Currently Red camera operators can chose to shoot both Ultra HD formats so they may have to make a decision at the time of shooting. Even the (not so) humble GoPro3 can now shoot 4K either in 3480x2160 or the cinemascope (17:9) 4096x2160.  

Choices, choices, choices. 

But 4K or thereabout videos are BIG and you don't want to upload more versions than is necessary, so I will stick with 4096 x 2304 for now because shrinking will always look better than stretching. Won't it?

Please note: 4K footage is not currently available to download from the London Photography And Video web-site, but can be supplied on request if available.

Tuesday, 9 October 2012

The boring but extremely important part of video making



You've just finished the most brilliant bit of work you have ever produced. Shot on Red, edited in 4K, graded, dubbed and in the preview theatre it looks and sounds amazing. Now what?


Well the video needs to be distributed to lots of different recipients with just as many requirements. Is it going to be shown in the cinema in 4K? Played by broadcasters in 1080p, 1080i, 720p, standard definition? Will it be put on a BluRay disk or a DVD? And if it is going to be watched on a computer, how good is the screen resolution and does the computer have the ability to play it back? 

There have always been multiple options when it comes to saving a piece of video or TV, even in the old days of  U-matic you could choose Hi-band or Low-band. But now if I am asked for a QuickTime file I ask at least 5 questions which are inevitably followed by blank stares and shoulder shrugs. 

Every four years or so there is a new format in town, the last biggy being HD with a top size of 1920 pixels by 1080. The next big step is 4K with either 4096 x 2304 pixels or 4096 x 2160 pixels. We can make this now and there are a lot of formats we can save it to such as old favourites like Apple ProRes and MPEG4 as well as a few new ones like GoPro's Cineform. Shortly HEVC or High Efficiency Video Encoding will be officially released by the MPEG and VCEG joint group. This new codec will have the same quality as MPEG4 but half the size (or the same size and twice the quality). 

Bored yet? Of course you are, but what is the point of producing a superb video when the only place it looks right is in the edit suite? A final thought; archive to the least compressed (preferably uncompressed) format you can so you can always produce new compressed copies from this master.