I have been on a quest to create HDR video for a long time. This would be particularly useful for taking videos of lightsabers because of the intense brightness of the blades. If you watched season 7 of “Clone Wars” on an HDR TV, you know what I’m talking about.
Even if you did, you might not know what HDR is. HDR stands for High Dynamic Range, and if you don’t have it, you should fix that. Basically, HDR lets you use a higher range of brightness and colors than what is possible on an sRGB monitor or HD TV. In saber speak, this is the difference between “red” and “deep red”.
Youtube already has a good chunk of HDR videos on it. Here is one that I quite like:
Of course, you will need an HDR capable youtube player to view it properly…
Anyways, I recently bought a new camera that can actually take HDR videos. However, uploading HDR videos to youtube turns out to be interesting, because when youtube takes the HDR video and converts to a regular video. (Which is what most people will see…) the result is very very boring in most cases.
The solution turns out to be to incorporate a LUT (LookUp Table) into the video before uploading it. This LUT will tell youtube how to convert the video to regular video. Of course, most tools for working with LUTs are expensive and not open-source, but it turns out that the LUTs themselves are fairly simple things, so I wrote a small script to generate a lut.
mklut.pike (1.3 KB)
This script is pretty dumb right now, but it did work and my test video came out better. Next I plan to add some way to adjust the LUT for more/less brightness so that the output video can look better. I also need to write a small tool to extract a frame from the video, apply the LUT and show the frame so that I can adjust it until it looks good.
I plan to make some test videos with lightsabers soon, stay tuned.