Fix: VSE: Metastack channel preview with negative values

As mentioned in comments on #43646, a negative channel value in preview
view settings can be used to climb the metastack. But the functionality
did not work as expected in most cases.

This combines a one-line fix by Sergey with an updated description for the
property which documents the feature.

In the future we may want to change its operation to be less obscure,
since it has some use-cases in aligning strips within a metastrip with
those outside of it.
This commit is contained in:
John Kiril Swenson
2025-07-16 06:12:09 +02:00
committed by John Kiril Swenson
parent dfd4d2914f
commit 1cb30b9d1e
2 changed files with 3 additions and 1 deletions

View File

@@ -6449,7 +6449,8 @@ static void rna_def_space_sequencer(BlenderRNA *brna)
RNA_def_property_ui_text(
prop,
"Display Channel",
"The channel number shown in the image preview. 0 is the result of all strips combined");
"Preview all channels less than or equal to this value. 0 shows every channel, and negative "
"values climb that many metastrip levels if applicable, showing every channel there.");
RNA_def_property_range(prop, -5, blender::seq::MAX_CHANNELS);
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_SEQUENCER, "rna_SequenceEditor_update_cache");

View File

@@ -1992,6 +1992,7 @@ ImBuf *render_give_ibuf(const RenderData *context, float timeline_frame, int cha
count = max_ii(count + chanshown, 0);
seqbasep = ((MetaStack *)BLI_findlink(&ed->metastack, count))->oldbasep;
channels = ((MetaStack *)BLI_findlink(&ed->metastack, count))->old_channels;
chanshown = 0;
}
else {
seqbasep = ed->seqbasep;