Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--release/scripts/startup/bl_ui/space_userpref.py2
-rw-r--r--source/blender/draw/engines/overlay/overlay_engine.c2
-rw-r--r--source/blender/draw/engines/workbench/workbench_data.c2
-rw-r--r--source/blender/draw/engines/workbench/workbench_effect_antialiasing.c6
-rw-r--r--source/blender/draw/engines/workbench/workbench_private.h2
-rw-r--r--source/blender/editors/undo/memfile_undo.c2
-rw-r--r--source/blender/makesdna/DNA_userdef_types.h2
-rw-r--r--source/blender/makesrna/intern/rna_userdef.c8
8 files changed, 17 insertions, 9 deletions
diff --git a/release/scripts/startup/bl_ui/space_userpref.py b/release/scripts/startup/bl_ui/space_userpref.py
index 9848c8eb69a..10e7b43a310 100644
--- a/release/scripts/startup/bl_ui/space_userpref.py
+++ b/release/scripts/startup/bl_ui/space_userpref.py
@@ -2157,7 +2157,7 @@ class USERPREF_PT_experimental_system(ExperimentalPanel, Panel):
def draw(self, context):
self._draw_items(
context, (
- ({"property": "use_undo_speedup"}, "T60695"),
+ ({"property": "use_undo_legacy"}, "T60695"),
),
)
diff --git a/source/blender/draw/engines/overlay/overlay_engine.c b/source/blender/draw/engines/overlay/overlay_engine.c
index 207637fa131..13b3be21668 100644
--- a/source/blender/draw/engines/overlay/overlay_engine.c
+++ b/source/blender/draw/engines/overlay/overlay_engine.c
@@ -495,7 +495,7 @@ static void OVERLAY_draw_scene(void *vedata)
OVERLAY_motion_path_draw(vedata);
OVERLAY_extra_centers_draw(vedata);
- if (DRW_state_is_select()) {
+ if (DRW_state_is_select() || DRW_state_is_depth()) {
/* Edit modes have their own selection code. */
return;
}
diff --git a/source/blender/draw/engines/workbench/workbench_data.c b/source/blender/draw/engines/workbench/workbench_data.c
index 6ef9cbfab57..ce9ad2091ac 100644
--- a/source/blender/draw/engines/workbench/workbench_data.c
+++ b/source/blender/draw/engines/workbench/workbench_data.c
@@ -199,7 +199,7 @@ void workbench_private_data_init(WORKBENCH_PrivateData *wpd)
}
wpd->clip_state = clip_state;
- wpd->cull_state = CULL_BACKFACE_ENABLED(wpd) ? DRW_STATE_CULL_BACK : 0;
+ wpd->cull_state = CULL_BACKFACE_ENABLED(v3d) ? DRW_STATE_CULL_BACK : 0;
wpd->vldata = vldata;
wpd->world_ubo = vldata->world_ubo;
diff --git a/source/blender/draw/engines/workbench/workbench_effect_antialiasing.c b/source/blender/draw/engines/workbench/workbench_effect_antialiasing.c
index 094d13fb84c..5c960acbd78 100644
--- a/source/blender/draw/engines/workbench/workbench_effect_antialiasing.c
+++ b/source/blender/draw/engines/workbench/workbench_effect_antialiasing.c
@@ -187,6 +187,10 @@ void workbench_antialiasing_engine_init(WORKBENCH_Data *vedata)
wpd->view_updated = false;
}
+ if (wpd->taa_sample_len > 0 && wpd->valid_history == false) {
+ wpd->taa_sample = 0;
+ }
+
{
float persmat[4][4];
DRW_view_persmat_get(NULL, persmat, false);
@@ -420,6 +424,7 @@ void workbench_antialiasing_draw_pass(WORKBENCH_Data *vedata)
/* AA disabled. */
/* Just set sample to 1 to avoid rendering indefinitely. */
wpd->taa_sample = 1;
+ wpd->valid_history = false;
return;
}
@@ -432,6 +437,7 @@ void workbench_antialiasing_draw_pass(WORKBENCH_Data *vedata)
const bool last_sample = wpd->taa_sample + 1 == wpd->taa_sample_len;
const bool taa_finished = wpd->taa_sample >= wpd->taa_sample_len;
if (wpd->taa_sample == 0) {
+ wpd->valid_history = true;
/* In playback mode, we are sure the next redraw will not use the same viewmatrix.
* In this case no need to save the depth buffer. */
eGPUFrameBufferBits bits = GPU_COLOR_BIT | (!wpd->is_playback ? GPU_DEPTH_BIT : 0);
diff --git a/source/blender/draw/engines/workbench/workbench_private.h b/source/blender/draw/engines/workbench/workbench_private.h
index a5e80f417d3..2191e09bc24 100644
--- a/source/blender/draw/engines/workbench/workbench_private.h
+++ b/source/blender/draw/engines/workbench/workbench_private.h
@@ -267,6 +267,8 @@ typedef struct WORKBENCH_PrivateData {
float taa_sample_inv;
/** If the view has been updated and TAA needs to be reset. */
bool view_updated;
+ /** True if the history buffer contains relevant data and false if it could contain garbage. */
+ bool valid_history;
/** View */
struct DRWView *view;
/** Last projection matrix to see if view is still valid. */
diff --git a/source/blender/editors/undo/memfile_undo.c b/source/blender/editors/undo/memfile_undo.c
index 9954cf85157..f22e18de7a1 100644
--- a/source/blender/editors/undo/memfile_undo.c
+++ b/source/blender/editors/undo/memfile_undo.c
@@ -147,7 +147,7 @@ static void memfile_undosys_step_decode(struct bContext *C,
bool use_old_bmain_data = true;
- if (!U.experimental.use_undo_speedup) {
+ if (USER_EXPERIMENTAL_TEST(&U, use_undo_legacy)) {
use_old_bmain_data = false;
}
else if (undo_direction > 0) {
diff --git a/source/blender/makesdna/DNA_userdef_types.h b/source/blender/makesdna/DNA_userdef_types.h
index 2c938ab036f..622222307c7 100644
--- a/source/blender/makesdna/DNA_userdef_types.h
+++ b/source/blender/makesdna/DNA_userdef_types.h
@@ -618,7 +618,7 @@ typedef struct UserDef_FileSpaceData {
} UserDef_FileSpaceData;
typedef struct UserDef_Experimental {
- char use_undo_speedup;
+ char use_undo_legacy;
/** `makesdna` does not allow empty structs. */
char _pad0[7];
} UserDef_Experimental;
diff --git a/source/blender/makesrna/intern/rna_userdef.c b/source/blender/makesrna/intern/rna_userdef.c
index 2df2a481091..d1af3ea7910 100644
--- a/source/blender/makesrna/intern/rna_userdef.c
+++ b/source/blender/makesrna/intern/rna_userdef.c
@@ -6057,12 +6057,12 @@ static void rna_def_userdef_experimental(BlenderRNA *brna)
RNA_def_struct_clear_flag(srna, STRUCT_UNDO);
RNA_def_struct_ui_text(srna, "Experimental", "Experimental features");
- prop = RNA_def_property(srna, "use_undo_speedup", PROP_BOOLEAN, PROP_NONE);
- RNA_def_property_boolean_sdna(prop, NULL, "use_undo_speedup", 1);
+ prop = RNA_def_property(srna, "use_undo_legacy", PROP_BOOLEAN, PROP_NONE);
+ RNA_def_property_boolean_sdna(prop, NULL, "use_undo_legacy", 1);
RNA_def_property_ui_text(
prop,
- "Undo Speedup",
- "Use new undo speedup (WARNING: can lead to crashes and serious .blend file corruption)");
+ "Undo Legacy",
+ "Use legacy undo (slower than the new default one, but may be more stable in some cases)");
}
static void rna_def_userdef_addon_collection(BlenderRNA *brna, PropertyRNA *cprop)