What's The Deal With Depth Of Field

preview_player
Показать описание
Present in every game cinematic you've ever seen and now making its way to real time rendering, depth of field is one of the most, if not the most important effect for taking your graphics to the next level.

Topics covered: How cameras work, circle of confusion generation, proper near and far field blending, the bokeh blur, the karis average, and inverse tonemapping.

Download my GShade shader pack!

Support me on Patreon!

Socials:

References:
Practical Gather-based Bokeh Depth of Field - Wojciech Sterna
Efficiently Simulating the Bokeh of Polygonal Apertures in a Post-Process Depth of Field Shader - L. McIntosh, B. E. Riecke and S. DiPaola

Music:
Sandgem Town (Day) - Pokemon Diamond OST
Joy - Persona 3
During The Test - Persona 3
Afternoon Break - Persona 3
This Mysterious Feeling - Persona 3
Like A Dream Come True - Persona 4
Soft Oversight - Sonny Boy OST
ソウとセイジ - Sonny Boy OST
GO!GO!STYLE - Paradise Killer OST

arrow in thumbnail drawn by thlurp

Thanks for watching!

This video is dedicated to my friend, Alotryx.

#acerola #graphics #gamedev #unity3d #graphics #shaders
Рекомендации по теме
Комментарии
Автор

Sorry everyone I had to make an emergency vet visit so I couldn't catch the audio error

Thankfully it's not very important, I just said that a camera doesn't distribute rays along a gaussian, so gaussian bad. Hope that helps!

Acerola_t
Автор

I love how much art skill this guy has, and he still includes the "transparent" background for the arrow.

nguyenhoangminhtrung
Автор

As someone without perfect vision, depth of field just makes things look like my vision got 5x worse and it hurts, so I turn it off in almost every game

ShuckleII
Автор

and remeber kids, once you setup your post-processing effects; reduce them all by 75% : )

spuddie
Автор

Thank you for making graphics programming accessible, understandable, and of course, fun ❤

denovodavid
Автор

this is seriously one of my favorite channels on this platform, god tier content

clearskyy
Автор

dude i really wasn't getting it until he explained it at 4:39, thank you bro 🙏

cubo
Автор

Something useful that I think may have been missed here is that optically, 1/3 of the "blurring" occurs on the far side of the focus distance while 2/3 on the near side. That may be why some of the examples are a little off of realistic, since they have a 50/50 split making the background more blurred and the foreground less blurred than they should be. (But I am just a photographer, not a shader programmer, great video! ✌️)

artsyaidan
Автор

The octagon blur is probably more accurate if you're trying to simulate lenses with a smaller aperture, since a smaller aperture will exaggerate the actual shape of the aperture rather than averaging it to a circle. And since many lenses in the consumer market have between 6 and 10 aperture blades it would mean that on lower aperture values you would get a none circular bokeh. So if you really wanna go for ultimate realism you might wanna consider implementing a blending between circle and octagon or heptagon if the intesity of the blur gets lessened.

toastbrot
Автор

Just to clarify, a "small" aperture like f1.2 will have a smaller range of focus, but small is a misnomer. While the number gets smaller, the opening of the aperture actually gets bigger, so a large aperture like f18 will be a physically smaller opening, letting less light through, but also increasing the range of focus.

timrobins
Автор

Every time you drop a new video I’m ready for your humor, wit, and condensed learning. You’re one of my favorite gaming channels lately. You’re out of my depth of field in skill.

VetNovice
Автор

loved the part where you said 👍🏾

ratguy
Автор

The amount of talent you display in these immensely technical yet wonderfully engaging videos is just unreal.

LukeFlavel
Автор

I love the jab about how much of a PITA it is to learn anything about graphics programming, and I'm very thankful for your videos that do an amazing job of filling that gap.

_sophies
Автор

That moment when you check the playlist and stumble on an unlisted video

Dawwo-qoky
Автор

I absolutely love your videos! I just recently got into shaders and "But you'll notice that the only result that appears is a random comment in some code" is so accurate! Just brilliant humor throughout! I also really like the contents, your videos are very helpful in understanding the idea behind all these visual effects! (especially since I'm too stupid to understand them myself...)

ancientpixel
Автор

It's all good until you can only clearly see where the game thinks you're trying to look. Now we need eye trackers just to make this practical. But the eye strain would probably be unreal. But I always appreciate some good, efficient programming concepts explained at the right level of abstraction for a cursory glance. You always hit it out of the park.

RAndrewNeal
Автор

Acerola manages to mix being serious and informative, but also somehow keep the video funny.

Great job dude!

KoshakiDev
Автор

I love u man. every time I watch one of ur videos I can't stop thinking about ways i could implement this in my games. I started experimenting with shaders a few months ago and I'm hooked ever since.

urselhorst
Автор

Thank you for breaking this down! I add DOF to almost every screenshot I take in a game, but always end up fighting with the grass because I didn't really know how DOF worked. The way you explained it makes a lot of sense! I'm excited to take more photos now that I know how the shaders work :3
(also the audio error was funny, even if it wasn't intended.)

Lain-