Post & the DI

Back to Post & the DI...

s-log and other log modes. (2 replies)

Bahy Ghoneim
5 days ago
Bahy Ghoneim 5 days ago

Hello Mr. Deakins. I was reading up on s-log and other log modes and its somewhat confusing me. I was hoping you or other filmmakers on this forum can explain to me what log is in the most simplest form. I would really appreciate it!

Hope your other projects are going well!

4 days ago
dmullenasc 4 days ago

There's sort of two issues here, one visual and the other mathematical.

With film negative, exposure creates density of silver or color dyes (after development), but there is not a linear correlation between the two if you plot it on a chart. An increase in exposure causes an equal increase in density only in the midrange -- in the shadows and the highlights it takes more exposure to create density. So when plotted on a chart, you get an S-shape curve, which is a logarithmic function. See:»»»

Digital sensors are (more or less) linear however, there is an equal amount of signal generated for an equal amount of exposure, so if plotted on a chart, you get a straight diagonal line.  This means that as the subject gets brighter and brighter, at some point the detail just abruptly clips to pure white when you hit the limit of what can be recorded and the sensor is overloaded.  With film negative, because it gets harder and harder to increase density with exposure, overexposed areas burn out more gradually to white.  So if the sensor can provide a decent dynamic range of exposure, it is possible to "bend" the linear response to light at the top and bottom of the exposure to create an artificial S-curve so that it is logarithmic instead of linear.  This gives the digital image a more film-like quality.  It also allows you to cram more stops of dynamic range into the limits of a 10-bit or 12-bit file and uses that limited recording range more efficiently, otherwise most of the bits are used by the lower end of the exposure if left linear.

However, there is some danger in using log modes for 8-bit recording because if you cram a wider dynamic range into a small number of discrete steps, what happens is that you start to see banding artifacts in smooth gradients.

At the other end of the scale, if you start recording and working in 16-bit files, like ACES does, then you have plenty of room to keep all the sensor data in linear mode and just create log versions as needed in post.

When cameras were only capable of capturing 12-stops or less of dynamic range, then the log versions made from the linear data were fairly mild but the log version of the data from the Alexa, which captures 14.5-stops of dynamic range, looks a lot "flatter" if viewed on a Rec.709 monitor without any conversion to a display gamma (contrast).  Scans of film negative are stored as log files and the Alexa Log-C file is very similar to a film scan.

So log is used for a number of reasons -- to store more dynamic range into a recording that is less than 16-bits, to be more efficient in assigning the bits to exposure information, to allow colorists to color-correct footage in a manner that is similar to color-correcting log scans of film negative, to help roll-off overexposed information as it goes to white in a more gradual fashion.

Now my descriptions are probably not completely accurate from an engineer's point of view, this is just my layman's understanding.

3 days ago
Wouter 3 days ago

Related image

Brilliant David!

It's a way to store all (or most) of the camera data (after in-camera demosaicing and minor processing) in a format with values from 0 all the way up to 1. This way you can display it on a monitor and see all the information that is there.. but it will look washed out and David explained why. Also, because a log image is already debayered (in camera), it can be stored with much less data without sacrificing much if *any* visually discernable quality. This makes the post process a lot more affordable and faster.

RAW files on the other hand are (or should be) untouched linear(ish) sensor data, ranging from 0 all the way up to "who knows..." These files are big... because a lot of data is needed to transform them into something that makes sense to a display as well as your eyes.

So the other problem with RAW data is that it is not fit to display. All the values beyond 1 are "lost" when you display it on a monitor (1 = fully white on a monitor), so what you're seeing is a very small part of the actual image.

This is why a log intermediate exists: it's a good balance between manageability and image quality.

Of course, IF you CAN record RAW, go nuts! Even more options later! But in the end you won't see much difference between a display referred image properly derived from a log encoding vs a raw file (unless something went wrong in the pipeline).

The cool thing about ACES is that you can transform the intermediate log image back into a scene referred linear working space. It is always beneficial to start from a linear source when compositing or transforming an image for final display as the math performed on the data is much more consistent. ACES is also the answer to the lack of imaging standardization.

ACES' colour science is pretty much the best I've ever used. ACES looks right as is.. out of the box. I've personally only used it with my FS700 but having tested many camera profiles and various transformation software, ACES is by far the easiest to work with and best looking out of the box. The sRGB output transfer looks very real, colours are on point and the highlight roll off and desaturation look very filmic.

However, it is limited to a certain amount of software. Although you can test it for free in Blender as well as Davinci Resolve. (Resolve does need to fix some of their imaging tools to properly work in a linear space - the color wheels work fine but things like keying, blurring, basic compositing math, noise reduction, etc.. are very lacking.

Another good tool to get familiar with it is the non-commerical version of Nuke. It is based on OCIO (same as Blender) and offers you the chance to toy around with it for yourself. Be aware; it can become an addiction very fast.

I'm also not 100% sure that everything I've said is correct in engineering terms, but I gave it my best anyway! Feel free to correct if necessary.

But *learning* ACES won't be a waste of time, in any case! 🙂

Back to Post & the DI...