Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Extract exact grain pattern from a plate to regrain a comp

  • Extract exact grain pattern from a plate to regrain a comp

    Posted by Adhish Yajnik on November 29, 2018 at 11:37 pm

    Hi all,

    I saw this feature at another studio, but since it was executed via scripts, I never got to understand how it worked under the hood, and was wondering if anybody here had an idea:

    The script degrained the plate for you, using Neat Video’s Reduce Noise, and then also created a precomp that extracted the original grain pattern from the plate to use as a regrain layer at the top of the stack. This avoids Match Grain, which often doesn’t match well, or Add Grain, which is good, but manual.

    and created a grain layer at the top of the layer stack to regrain everything using the same grain rather than using a Match Grain or manually-tweaked Add Grain effect.

    I suspect it’s something like the degrained plate Difference’d against the original plate, but how do I adjust that comp so that when applied over the degrained comp, it will match the grain from the original plate?

    Thanks!

    Zachary Kinney replied 7 years, 2 months ago 3 Members · 3 Replies
  • 3 Replies
  • Adhish Yajnik

    February 19, 2019 at 11:03 pm

    Forgot to check this post for a while over the holidays, so pardon my late reply.

    This is a fairly common workflow at many major post houses that my colleagues and I have worked at here in LA on network and cable TV shows. They’ve all had proprietary scripts and plugins that handled the process under the hood, however. Maybe your experience has been different in Iowa.

    Here are some links to other VFX artists and supervisors who speak about this exact workflow in various compositing applications:

    Bradley Friedman’s blog post on achieving this workflow in Nuke:
    https://www.fie.us/2014/08/30/grain-management-101/

    By the way, the reason Friedman wrote this blog post is because Nuke specifically has a plugin called F_Regrain for this exact feature — suggesting that it’s not wrong at all — but his script works even better than F_Regrain.

    A Lynda tutorial from Steve Wright that discusses this grain workflow among others:
    https://www.lynda.com/Nuke-tutorials/28-101-Smart-grain-management-workflows/450279/702995-4.html

    A Reddit discussion on various grain workflows including this one:
    https://www.reddit.com/r/vfx/comments/8fjnit/what_are_your_grain_workflows/

    We like to degrain all our plates so that, yes, green screen keys can be pulled more cleanly, but also to make our lives easier doing paint, cleanup, and any other compositing work that doesn’t involve 3D renders. If we’re using freeze-framed parts of a plate for roto/paint work, we don’t want to freeze-frame the grain in that area. We could degrain that single patch and then regrain it, but that would introduce artifacts at the edges of the patch that take a lot of time to finesse. So degraining the whole plate, doing the comp work, and re-graining the whole plate at the end is more efficient timewise.

    And time is really at the heart of this question. When you’ve got a couple hundred VFX shots to pump out in a week and a half, an automatic degrain-regrain plugin saves you an entire step of adding an Add Grain effect and tweaking the channels intensities and sizes per shot. It’s a huge time saver. We’ve found that Match Grain rarely replicates the grain to any level of accuracy, and a manually-tweaked Add Grain is more reliable… yet time consuming.

    And believe it or not, grain is something our clients love to nitpick, so we’ve got to be pretty accurate with it. We’ve had shots rejected for minor grain matching issues.

    So, let’s open up the question to others with experience in this area: anybody have any idea how to translate Bradley Friedman’s Nuke script (https://www.fie.us/2014/08/30/grain-management-101/) to After Effects?

  • Michael Szalapski

    February 20, 2019 at 7:24 pm

    I know lots of people who have to degrain and regrain. It’s vital in VFX work – some people are VERY picky about their grain! I think Dave might not be very involved in that sort of work, you’ll have to forgive him.

    “I suspect it’s something like the degrained plate Difference’d against the original plate, but how do I adjust that comp so that when applied over the degrained comp, it will match the grain from the original plate?”

    AE has the Difference Matte effect you could use to pull the differences between the denoised and the original footage. But I’d need to put quite a bit more brainpower into figuring out the rest of that node setup that I don’t have to spare at the moment.

    – The Great Szalam
    (The \’Great\’ stands for \’Not So Great, in fact, Extremely Humble\’)

    No trees were harmed in the creation of this message, but several thousand electrons were mildly inconvenienced.

  • Zachary Kinney

    March 22, 2019 at 4:48 am

    Here’s how you regrain in AE manually:

    First you need to set your project to 32 bpc. This technique will only work in float because we need to use some negative color values here. Then degrain your plate. Neat Video is by far the best tool there is for this. Among other reasons, it keeps everything nice and sharp. It is one of the few 3rd party plugins I swear by and totally worth the money. Not sure if Red Giant’s Denoiser works in 32bit, but Ive never found it to be that good anyway, and AE’s built in Remove Grain definitely isn’t 32.

    Next you want to duplicate your comp. Name that new comp “Grain”. In there duplicate your footage layer and delete the degrain effect from the bottom layer. Then select Subtract for the color mode for the top layer. Your image should go black now. If you want to see that it’s working, crank up the exposure in the view window and you should see all the nice grain from your image.

    Now drop this “Grain” comp into your main comp on top of your degrained footage, and set it’s color mode to Add.

    And that’s it! Regrained footage that matches your source exactly.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy