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:
Diffstat (limited to 'source/blender/sequencer/intern/strip_transform.c')
-rw-r--r--source/blender/sequencer/intern/strip_transform.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/source/blender/sequencer/intern/strip_transform.c b/source/blender/sequencer/intern/strip_transform.c
index 087e2610bd6..2c9ab0a3335 100644
--- a/source/blender/sequencer/intern/strip_transform.c
+++ b/source/blender/sequencer/intern/strip_transform.c
@@ -297,6 +297,9 @@ static int shuffle_seq_time_offset_test(SeqCollection *strips_to_shuffle,
if (!SEQ_transform_test_overlap_seq_seq(seq, seq_other)) {
continue;
}
+ if (SEQ_relation_is_effect_of_strip(seq_other, seq)) {
+ continue;
+ }
if (UNLIKELY(SEQ_collection_has_strip(seq_other, strips_to_shuffle))) {
CLOG_WARN(&LOG,
"Strip overlaps with itself or another strip, that is to be shuffled. "
@@ -517,3 +520,18 @@ void SEQ_image_preview_unit_from_px(const Scene *scene, const float co_src[2], f
co_dst[0] = co_src[0] / scene->r.xsch;
co_dst[1] = co_src[1] / scene->r.ysch;
}
+
+void SEQ_image_transform_bounding_box_from_collection(
+ Scene *scene, SeqCollection *strips, bool apply_rotation, float r_min[2], float r_max[2])
+{
+ Sequence *seq;
+
+ INIT_MINMAX2(r_min, r_max);
+ SEQ_ITERATOR_FOREACH (seq, strips) {
+ float quad[4][2];
+ SEQ_image_transform_quad_get(scene, seq, apply_rotation, quad);
+ for (int i = 0; i < 4; i++) {
+ minmax_v2v2_v2(r_min, r_max, quad[i]);
+ }
+ }
+}