Age | Commit message (Collapse) | Author |
|
Move keymap handler logic for keymap and gizmo handlers
into their own functions.
This makes it possible to refactor keymap handling
without large changes or duplicating code.
|
|
No functional change expected!
|
|
Conflicts:
source/blender/blenkernel/intern/library.c
source/blender/blenloader/intern/readfile.c
source/blender/editors/screen/screen_edit.c
|
|
to crashes).
Those are two cases where keeping infamous backward `parents` pointers
of collections in sync is kind of impossible to do... So rebuilding
those relationships from scratch instead.
Fixes e.g. a crash when undoing, then reloading a library, and likely
many more weird ones like that.
Uncovered while investigating T64764.
|
|
It's not always possible to keep 'by hand' parent relationships valid in
collections hierarchy. Add functions to remake those
(re-using/factorizing code from `readfile.c` `lib_link_collection_data()`
function).
Can't stress again how painful it is to have those kind of backward
relationships in our data structures, those *always* end up being
serious issues to keep in sync... Should only be generated on the fly
when needed, period. :(
|
|
Note that this only fixes the core issue reported (caused by own dummy
mistake in rBd0df7fb3b94ea), investigating that report uncovered at leat
two more issues, including a crasher (when reloading after an undo)...
|
|
|
|
Not re-reading linked data-blocks in undo/redo case also means that we
do not touch to their usercounts. Even worse, lib_link process in
readfile will increase those (for cases where local data uses linked
one).
Whole data management code is now heavily relying on valid consistent
refcount of all IDs, so we cannot allow that anymore.
Simple solution here could have been to then not increase that one for
linked IDs in `newlibadr_us()`, but unfortunately that would not be
totally bullet-proof, as some local users of linked data may be added or
removed by an undo step...
So I cannot think of any other solution than the ugly brute force one,
i.e. going over the whole Main database and recompute linked IDs users
count... Should not be a big issue performance wise though, this is
fairly cheap process.
|
|
This will be needed in undo/redo case, since we do not re-read linked
IDs, their usercounts become total garbage (especially in 'used by local
ID' cases)...
|
|
|
|
No functional nor visual change.
This is a partial revert of 0910932e71d2.
The toggle option was introduced on 6640bcca7422.
This allow us to simplify the outliner draw code so it uses the icon as
defined in the RNA (as oppose to get the value there once again).
|
|
Currently if a panel becomes empty (draw simply returns), it stays
at the last non-empty height. This seems to be caused by some legacy
checks that may be completely obsolete, but the safest fix is to at
least allow resetting height when the panel is open.
|
|
|
|
Use a default update function for user preferences that tags
dirty and redraws (if changed).
This avoids relying on button changes which fail in some cases.
|
|
Use so we can have a default update function,
that doesn't need to be set for every property.
|
|
|
|
|
|
The unit system is designed for displaying and editing and not for
rendering. Eevee, Workbench and GPencil used these settings to convert
the focal length and sensor size to world units. Making depth of field
render differently with Cycles.
For now we will remove the scale in the draw engines to match cycles,
until we implemented a camera parameters specific scale.
Reviewed By: brecht, fclem
Maniphest Tasks: T64988
Differential Revision: https://developer.blender.org/D4925
|
|
This patch fix the issue introduced by recent refactor and fixes
computation when using overscans.
|
|
When using FXAA when rendering to an image the alpha channel was not
correct what lead to visual artifacts.
These artifacts come from the FXAA function that overwrites the alpha
channel with the original Luma of the texel. In the shader this can be
turned on or off. But at the end it always overwrites the alpha with the
luminance.
We didn't use this feature, but the alpha of the resulting pixel still
contained the luma value what lead to render artifacts.
By overwriting the alpha channel with the original alpha we remove these
artifacts.
Reviewed By: fclem
Maniphest Tasks: T64947
Differential Revision: https://developer.blender.org/D4924
|
|
Add tags in fcurve.update(), keyframe_point.insert/add/remove(),
fmodifier.control_points.add/remove().
|
|
|
|
|
|
|
|
Rename it to GPU_batch_draw_advanced and use base instance when possible.
Also add GPU_batch_bind to bind the vao independantly of drawing commands.
|
|
|
|
|
|
Only update if the view changes.
|
|
|
|
|
|
|
|
|
|
Also get rid of clip_block which did the same as clipplanes inside
common_view_lib.glsl.
|
|
|
|
|
|
|
|
Remove the clear allocation flag as it has little impact since there should
be very few allocation per redraw.
Make BLI_memblock_alloc and BLI_memblock_iterstep much more cache efficient
removing them almost entirely from performance profiles.
|
|
Having both TAA and FXAA enabled at the same time resulted in conflicts.
The jitter_index was incremented twice before being used instead of once.
|
|
Continuing the transition to the new API
|
|
|
|
|
|
This should be handled by DST.view_default
|
|
This will have multiple benefit.
TODO detail benefits (culling, more explicit, handling of clipping planes)
For now the view usage is wrapped to make changes needed more progressive.
|
|
|
|
- Remove DST.frontface and DST.backface.
- Separate uniform update into its own function draw_update_uniforms.
|
|
|
|
|
|
This was the only remaining cases that used a string lookup, which didn't
work anymore now that it's no longer a real value in the context.
|
|
Don't allow changing it for painted images until they have been saved, similar
to sidebar panels. This could be solved better, for now the important thing is
not to lose changes.
|
|
|