Age | Commit message (Collapse) | Author |
|
|
|
This fixes missing selection updates in UV editor, both with GPU subdivision
and with the Modified Edges display option for modifiers in general.
It also fixes the UV editor incorrectly showing the cage mesh with deformed
coordinates. These are not yet supported by the UV selection system.
Changes:
* Always read selection state from the editmesh when building batches. The
flags in the evaluated mesh can be outdated as selection bypasses depsgraph
evaluation for performance, and instead may just clear the batches.
* runtime.is_original is only valid for the bmesh wrapper. The check for
building the UV cage should only use that if the mesh is a bmesh wrapper.
* Don't create cage batches for objects whose mesh is in edit mode, but that
are not themselves in edit mode, there is no need.
Differential Revision: https://developer.blender.org/D15658
|
|
|
|
* Fixed crash in debug draw code. Apparently this is
only used by PBVH draw?
* Debug draw code can now be forcibly enabled in release
mode (i.e. RelWithDebugInfo) by uncommenting a commented
out #define.
* Fixed colors in debug draw mode.
* PBVH node boxes in debug mode now flash a different color
when they are updated.
|
|
This new implementation does all downsampling in a single compute shader
dispatch, removing a lot of complexity from the previous recursive
downsampling.
This is heavilly inspired by the Single-Pass-Downsampler from GPUOpen:
https://github.com/GPUOpen-Effects/FidelityFX-SPD
However I do not implement all the optimization bits as they require
vulkan (GL_KHR_shader_subgroup) and is not as versatile (it is only
for HiZ).
Timers inside renderdoc report ~0.4ms of saving on a 2048*1024 render for
the whole downsampling. Note that the previous implementation only
processed 6 mips where the new one processes 8 mips.
```
EEVEE ~1.0ms
EEVEE-Next ~0.6ms
```
Padding has been bumped to be of 128px for processing 8 mips.
A new debug option has been added (debug value 2) to validate the HiZ.
|
|
Contributed by luzpaz.
Differential Revision: https://developer.blender.org/D15680
|
|
These are meant to provide easy shape and AABB operation for culling.
They are currently incomplete but can be extended as one see fits.
The `common_debug_shape_lib.glsl` contains helper to draw thoses shapes.
|
|
It was impossible to print literals like `drw_print(5)`.
|
|
It was an oversight.
|
|
Be consistent with naming to avoid mixing MPoly/MFace.
|
|
This commit moves the hide status of mesh vertices, edges, and faces
from the `ME_FLAG` to optional generic boolean attributes. Storing this
data as generic attributes can significantly simplify and improve code,
as described in T95965.
The attributes are called `.hide_vert`, `.hide_edge`, and `.hide_poly`,
using the attribute name semantics discussed in T97452. The `.` prefix
means they are "UI attributes", so they still contain original data
edited by users, but they aren't meant to be accessed procedurally by
the user in arbitrary situations. They are also be hidden in the
spreadsheet and the attribute list by default,
Until 4.0, the attributes are still written to and read from the mesh
in the old way, so neither forward nor backward compatibility are
affected. This means memory requirements will be increased by one byte
per element when the hide status is used. When the flags are removed
completely, requirements will decrease when hiding is unused.
Further notes:
* Some code can be further simplified to skip some processing when the
hide attributes don't exist.
* The data is still stored in flags for `BMesh`, necessitating some
complexity in the conversion to and from `Mesh`.
* Access to the "hide" property of mesh elements in RNA is slower.
The separate boolean arrays should be used where possible.
Ref T95965
Differential Revision: https://developer.blender.org/D14685
|
|
|
|
|
|
This patch allows the viewport compositor to operate in Material Preview
mode.
Differential Revision: https://developer.blender.org/D15655
Reviewed By: Clement Foucault
|
|
This patch adds the core realtime compositor evaluator as well as a
compositor draw engine powered by the evaluator that operates in the
viewport. The realtime compositor is a new GPU accelerated compositor
that will be used to power the viewport compositor imminently as well as
the existing compositor in the future.
This patch only adds the evaluator and engine as an experimental
feature, the implementation of the nodes themselves will be committed
separately.
See T99210.
Differential Revision: https://developer.blender.org/D15206
Reviewed By: Clement Foucault
|
|
|
|
|
|
This might create nullptr dereference in some cases.
|
|
- Use references
- Reorder functions to remove unnecessary prototype
- Use the attribute API
- Use const where possible
- Split no-radius extraction a bit more, add multithreading
|
|
|
|
|
|
This is a complete rewrite of the draw debug drawing module in C++.
It uses `GPUStorageBuf` to store the data to be drawn and use indirect
drawing. This makes it easier to do a mirror API for GPU shaders.
The C++ API class is exposed through `draw_debug.hh` and should be used
when possible in new code.
However, the debug drawing will not work for platform not yet supporting
`GPUStorageBuf`. Also keep in mind that this module must only be used
in debug build for performance and compatibility reasons.
|
|
|
|
Ownership is transfered from the pool to the `Texture` and vice versa.
This allows to have history buffers with only 1 persistent texture.
|
|
|
|
|
|
|
|
NOTE: This is committed to the 3.3 branch as part of D15606, which we
decided should go to this release still (by Bastien, Dalai and me). That
is because these are important usability fixes/improvements to have for
the LTS release.
Adds `rna_path.cc` and `RNA_path.h`.
`rna_access.c` is a quite big file, which makes it rather hard and
inconvenient to navigate. RNA path functions form a nicely coherent unit
that can stand well on it's own, so it makes sense to split them off to
mitigate the problem. Moreover, I was looking into refactoring the quite
convoluted/overloaded `rna_path_parse()`, and found that some C++
features may help greatly with that. So having that code compile in C++
would be helpful to attempt that.
Differential Revision: https://developer.blender.org/D15540
Reviewed by: Brecht Van Lommel, Campbell Barton, Bastien Montagne
|
|
|
|
This avoids issue when the macro is followed by another operator.
Example:
`float result = weighted_sum(a,b,c,d,w) * 5.0;`
|
|
This allows finding missing binds more easily as the missing binds slots
won't be populated with previous texture binds.
|
|
Replaces `DRW_shgroup_call_procedural_triangles_indirect`.
This makes the indirect drawing more flexible.
Not all primitive types are supported but it is just a matter of adding
them.
|
|
Just like the name suggest, this adds a way to draw a series of proceduraly
positioned triangles using and indirect buffer.
|
|
|
|
This make using texture reference easier. But now, it makes it mandatory
for the wrapped type to implement the `swap()` static method.
|
|
|
|
|
|
This loosens the current implementation a bit to only force optimal
display when editing on cage. It used to be any editing mode.
Brings GPU based subdivision closer to the CPU version.
|
|
Adds `rna_path.cc` and `RNA_path.h`.
`rna_access.c` is a quite big file, which makes it rather hard and
inconvenient to navigate. RNA path functions form a nicely coherent unit
that can stand well on it's own, so it makes sense to split them off to
mitigate the problem. Moreover, I was looking into refactoring the quite
convoluted/overloaded `rna_path_parse()`, and found that some C++
features may help greatly with that. So having that code compile in C++
would be helpful to attempt that.
Differential Revision: https://developer.blender.org/D15540
Reviewed by: Brecht Van Lommel, Campbell Barton, Bastien Montagne
|
|
|
|
This reverts commit e2c02655c78b2c669468ae568ddf4b17953cc98d. It was already
reverted in the 3.2 branch, as it caused more serious issues than it solved.
Fixes T99805, T99323, T99296.
|
|
The new implementation leverage compute shaders to reduce the
number of passes and complexity.
The max blur amount is now detected automatically, replacing the property
in the render panel by a simple checkbox.
The dilation algorithm has also been rewritten from scratch into a 1 pass
algorithm that does the dilation more efficiently and more precisely.
Some differences with the old implementation can be observed in areas with
complex motion.
|
|
This removes the quirk of having to call the sync function for each new
render loop.
# Conflicts:
# source/blender/draw/engines/eevee_next/eevee_view.cc
|
|
Previously there was a special extraction process for "vertex colors"
that copied the color data to the GPU with a special format. Instead,
this patch replaces this with use of the generic attribute extraction.
This reduces the number of code paths, allowing easier optimization
in the future.
To make it possible to use the generic extraction system for attributes
but also assign aliases for use by shaders, some changes are necessary.
First, the GPU material attribute can now store whether it actually refers
to the default color attribute, rather than a specific name. This replaces
the hack to use `CD_MCOL` in the color attribute shader node. Second,
the extraction code checks the names against the default and active
names and assigns aliases if the request corresponds to a special active
attribute. Finally, support for byte color attributes was added to the
generic attribute extraction.
Differential Revision: https://developer.blender.org/D15205
|
|
|
|
This was caused by the world volume shader needing placeholder textures
that were not available until cache populate begins.
Adding a check and creating on the fly fixes the issue.
|
|
|
|
|
|
|
|
|