Age | Commit message (Collapse) | Author |
|
This separate probe rendering from viewport rendering, making possible to
run the baking in another thread (non blocking and faster).
The baked lighting is saved in the blend file. Nothing needs to be
recomputed on load.
There is a few missing bits / bugs:
- Cache cannot be saved to disk as a separate file, it is saved in the DNA
for now making file larger and memory usage higher.
- Auto update only cubemaps does update the grids (bug).
- Probes cannot be updated individually (considered as dynamic).
- Light Cache cannot be (re)generated during render.
|
|
|
|
This fixes T54439
|
|
|
|
|
|
The Eevee AO node supports the new Normal socket, but ignores Distance,
Samples, Inside and Only Local settings.
|
|
This includes making Eevee match Cycles behavior of inserting an emission
node when linking colors to closures.
|
|
This patch reduce the branching in the lamp loop, improving compilation time
noticeably (2372ms to 1785ms for the default shader).
This should not change the appearance of the shader.
Performance impact is negligeable.
|
|
Only generate shadow store shaders on demand and create a simpler shader
for small blur radius.
|
|
|
|
Do note that it does not match cycles implementation.
Also we could precompute the hash per strand before rendering but that would
suggest it's not per engine specific.
If we make the random value internal to blender then it won't be a matter
because other renderers will have access to the same value.
|
|
|
|
|
|
This now can shade actual poly strips that mimics cylinders.
This makes hair coverage exact compared to the line method and result in
smoother fading hair.
This does make the sampling a bit more exact but needs more samples to
converge properly.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
The implementation is pretty straightforward.
In Cycles, sampling the shapes is currently done w.r.t. area instead of solid angle.
There is a paper on solid angle sampling for disks [1], but the described algorithm is based on
simply sampling the enclosing square and rejecting samples outside of the disk, which is not exactly
great for Cycles' RNG (we'd need to setup a LCG for the repeated sampling) and for GPU divergence.
Even worse, the algorithm is only defined for disks. For ellipses, the basic idea still works, but a
way to analytically calculate the solid angle is required. This is technically possible [2], but the
calculation is extremely complex and still requires a lookup table for the Heuman Lambda function.
Therefore, I've decided to not implement that for now, we could still look into it later on.
In Eevee, the code uses the existing ltc_evaluate_disk to implement the lighting calculations.
[1]: "Solid Angle Sampling of Disk and Cylinder Lights"
[2]: "Analytical solution for the solid angle subtended at any point by an ellipse via a point source radiation vector potential"
Reviewers: sergey, brecht, fclem
Differential Revision: https://developer.blender.org/D3171
|
|
Patch D3205 by Kanzaki Wataru
Only implemented in Eevee for now. Collapse a closure to RGBA so we can
do NPR stuff on the resulting color.
Use an emission shader to convert the color back to a closure.
Doing this will break PBR and will kill any SSR and SSS effects the shader
the shader rely on. That said screen space refraction and ambient occlusion
are supported due to the way they are implemented.
|
|
SSR does not work with hair strands. Basically, the rays are too much
random to ever converge properly and just result in a soup of self
inter reflections.
So forcing it to not produce any SSR. Could potentially save some bandwidth
by not rendering hair to the SSR buffers.
|
|
Now it starts to look correct!
|
|
This is a hack to properly shade wire hairs. Use stochastic sampling and
let TAA solve the noise.
At least it's way more correct than the previous hack.
|
|
|
|
This means only one texture to draw to and only one sprite per pixel.
The texture is twice as large and near and far planes are side by side.
The sprite choose the biggest coc to expand to and is redirected to the
area (layer) it belongs to.
The fragment shader discard every pixel that does not belong to the correct
layer.
|
|
|
|
Due to the scatter operation being done at half resolution, undersampling
is visible at bokeh shape edges (because of the hard cut).
This commit adds a smoothing function to minimize the problem.
Also optimize the bokeh shape parametrization by precomputing a lot of
constants.
|
|
This new blending allows background to fill the gaps left by forground
objects. However this has a drawback, background objects that should be
partially occluded in this case can be seen through the blurred objects.
This does not fix the problem of blurred foreground over sharp background.
Also cleanup code to be simpler and remove unused geometry shader.
|
|
This mean we can now have different shadow resolutions for both.
However each shadow type keep the same size accross all lamps because of
future "real" Cube Shadowmaps limitation and to save texture sampler slots.
That said the cascade shadow resolution could (in the future) still be
changed to be adjustable per sun lamp.
|
|
|
|
It's usefull in some scenario to tweak the specular intensity of a light
without modifying the diffuse contribution.
Cycles allows it via lamps material which we currently not support in Eevee.
This is a good workaround for now.
|
|
|
|
- Fix the confusing naming in raycast()
- Fix raytrace acne caused by the rays not being correctly centered on
the texel.
|
|
|
|
This prevent any NANs pixel to spear accross the history. This does not
mean we should allow NANs at all!
|
|
The SSR has a bug that creates NAN pixels values. Reported here T54795.
|
|
|
|
Applied to newly added files in 2.8
|
|
This "improve" the viewport experience by reducing the noise from random
sampling effects (SSAO, Contact Shadows, SSR) when moving the viewport or
during playback.
This does not do Anti Aliasing because this would conflict with the outline
pass. We could enable AA jittering in "only render" mode though.
There are many things to improve but this is a solid basis to build upon.
|
|
This pass create a velocity buffer which is basically a 2D motion vector
texture. This is not yet used for rendering but will be usefull for motion
blur and temporal reprojection.
|
|
|
|
I haven't noticed any performance improvement but it could be more important
for other hardware. At least it's not slower!
|
|
|
|
This gets rid of the need of a geom shader and instancing.
Both are pretty slow compared to the new method.
The only moment the old method could be better is when scene is filled
with lots of objects and most of the objects in the shadow map appear
on every layer.
But even then, we could optimize the culling and minimize the overhead.
|
|
invert -> inverse
|
|
This refactor modernise the use of framebuffers.
It also touches a lot of files so breaking down changes we have:
- GPUTexture: Allow textures to be attached to more than one GPUFrameBuffer.
This allows to create and configure more FBO without the need to attach
and detach texture at drawing time.
- GPUFrameBuffer: The wrapper starts to mimic opengl a bit closer. This
allows to configure the framebuffer inside a context other than the one
that will be rendering the framebuffer. We do the actual configuration
when binding the FBO. We also Keep track of config validity and save
drawbuffers state in the FBO. We remove the different bind/unbind
functions. These make little sense now that we have separate contexts.
- DRWFrameBuffer: We replace DRW_framebuffer functions by GPU_framebuffer
ones to avoid another layer of abstraction. We move the DRW convenience
functions to GPUFramebuffer instead and even add new ones. The MACRO
GPU_framebuffer_ensure_config is pretty much all you need to create and
config a GPUFramebuffer.
- DRWTexture: Due to the removal of DRWFrameBuffer, we needed to create
functions to create textures for thoses framebuffers. Pool textures are
now using default texture parameters for the texture type asked.
- DRWManager: Make sure no framebuffer object is bound when doing cache
filling.
- GPUViewport: Add new color_only_fb and depth_only_fb along with FB API
usage update. This let draw engines render to color/depth only target
and without the need to attach/detach textures.
- WM_window: Assert when a framebuffer is bound when changing context.
This balance the fact we are not track ogl context inside GPUFramebuffer.
- Eevee, Clay, Mode engines: Update to new API. This comes with a lot of
code simplification.
This also come with some cleanups in some engine codes.
|
|
|