Jump to content

nutdanai

Depth of Field problem

Recommended Posts

Hi , I have problem about edge of model when use After effect camera lens blur or other plugin. I test plugin with gradient , the result seem right but when depth that come out from c4d will got problem.

 

When I render from c4d I use focus in front of object and rear blur behind object.

 

a.thumb.jpg.d8e889a055ee1731817381ea294017d2.jpg

 

This one is result that use depth from c4d

 

a2.thumb.jpg.88c98995fae6a61c0816ce9edfc2b7e8.jpg

 

This one is test by using gradient

 

png file that I attach is resource.

 

a.png

a_depth.png

Share this post


Link to post
Share on other sites

hmm, not sure what's up on your end, but I got it to work with the 2 images you provided.  See my comp and screen shot of effect settings, see if something looks different to you.

Screen Shot 2018-05-25 at 7.39.05 AM.png

Screen Shot 2018-05-25 at 7.39.09 AM.png

Share this post


Link to post
Share on other sites

First thing is the depth map needs to be inverted, usually white is closest and black is furthest away.

 

Second, you're still going to get bad fringing with AE's lens blur, I haven't been able to find a way around it and I think it's just a poor filter. I've used the Frischluft Lenscare plugin which gets better results if you can get your hands on a copy.

 

Here's a video which compares the two:

 

Overall though, I've noticed using a lens blur effect on scenes that have a lot of occluding/overlapping objects like your example will never get the best results, I think there just isn't a plugin that will correctly mask and blur the edges between high contrast distance objects.

 

To get best results for a scene with a lot of overlapping elements and high distance contrast I would suggest doing it at render time if you have the resources.

Share this post


Link to post
Share on other sites

Echoing Ninjad's assessment of Lens Blur, it is a hotmess.  If you really need it, go ahead and use it.  Another downfall of it, it is a single core effect.  This means your entire comp will only render w 1 core of your computer, regardless of how many cores you have.  Even if this effect is applied to 10 frames of a 1000 frame render, all 1000 frame will only render w 1 core.

 

If you can spare the extra money, invest in Frischluft's Lenscare plugin.  It does a GREAT job of applying DoF.  This plugin does a very convincing job of blurring edges of high contrast/large distance objects.

 

But yes, to get truly accurate blurring, you'd need to apply it in 3d at render time.  Unfortunately, this limits the flexibility in post.  There's always a tradeoff.

Share this post


Link to post
Share on other sites

You need to render your cubes with no background and an alpha channel. What's happening is that AE is blurring your black background, which sucks the neighboring pixels of your cube into the background - causing that unnatural halo from all the cubes - even the ones that are supposed to be in-focus. The filter simply isn't smart enough to exclude foreground pixels from blurring into your background pixels.

 

Below, I keyed out the black background of your render (and the white background of the blur map) to approximate what this would look like if it had been rendered with alpha. This still has errors in it where the cubes overlap, but it is much closer to a blur performed at render.

 

Blurring in post is fairly easy as long as you are able to split your scene into layers. For example, if I have a character in focus and the background is 100% blurred, I absolutely render them separately and blur in post. I do the same thing if I have an out-of-focus foreground object.

 

If a character is in-focus and the background needs true depth blurring, I render the character layer without DoF and the background layer with DoF - just to save on render time (especially if the character needs other effects, like motion blur).

 

blur.jpg.65cbe71a161fb183fcd78d1448a53634.jpg

  • Like 1

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

    No registered users viewing this page.

YOUTUBE CHANNEL:

ABOUT US:

C4D Cafe is the largest CINEMA 4D community. We provide facilities for discussion, showcasing and learning our favorite software :) Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, get your own private messenger, post status updates, manage your profile and much more. If you need to find solution to your problem or otherwise ask for help, Cafe is the right place.
×
×
  • Create New...