CatxFish / motion-effect

obs-studio plugin for source item animation
https://obsproject.com/forum/resources/motion-filter.668/
GNU General Public License v2.0
212 stars 38 forks source link

Feature suggestion for motion-transition: option for sources only present in one scene to not move #36

Open sirsquidness opened 2 years ago

sirsquidness commented 2 years ago

Hello!

When using a motion transition between two scenes, all sources in that scene get moved. If the source is only visible in one of the two scenes, it scales from/to size zero. This makes the effect a little weird in some scenarios, for example where you have backgrounds in one scene but not another, the background disappears while the persistent source moves to its destination. It gives a weird transition via black.

Feature suggestion

A configurable option for the motion transition so that any sources not present in both scenes are not moved, and are instead present in their static position for the entire duration of the transition. Sources only in the destination scene are cut in as soon as the transition starts. Sources only in the original scene are disappeared as soon as the transition ends.

Hypothetical scenario :

You're doing an interview where the interviewer and interviewee are on separate cameras. As the interviewee responds to the question, you want to use motion transition to bring them fullscreen. Swapping between full screen and picture-next-to-picture scenes.

Source: Two cameras - A and B. A background image

Scenes: Scene 1: full screen camera A Scene 2: camera A and B are side by side (so taking up about a quarter of the screen each). Empty space is filled with a background image.

In this feature, because the only common element between the two scenes is Camera A, during transition Camera A would grow/shrink in size to/from the full screen in Scene 1 to the quarter size in Scene 2.

Scene 1 is visible. Camera A is fullscreen. As soon as the transition to Scene 2 starts, Camera B and background image are rendered in their final position, so they are slowly revealed as Camera A shrinks and moves to its final position. Transitioning back to Scene 1, all sources remain visible as Camera A grows back to fullscreen. At the end of the transition, Camera B and background disappear.

Workarounds

I know I can do this with the motion-filter plugin instead... but it would be a lot easier and more intuitive if I was able to achieve this with separate scenes.

Maybe this is a hard problem because now there's a list of sources from two scenes, and no intuitive way to know how to merge the Z-order of sources from both scenes. What if I have different backgrounds on both scenes? So maybe this option only works in specific edge cases.

Keen to hear your thoughts on if there's any merit to this idea and if it's something you'd consider either accepting a PR for or implementing!

(this issue would be greatly aided by some short video snippets to demonstrate my goals.. I'll try and make some tomorrow if I get time)