Particle filter

Thanks for the tip @Elusien.
Finally got HTML overlay to work. The implode/defragment sequence can be used for a transition or titling. Have to work on the explosion effect next.

https://streamable.com/y0c9h

Managed to get both defragment and fragment to work.


https://streamable.com/f5a3s

Both effects were created using @Elusien’s code copied from http://www.elusien.co.uk/shotcut/

In case any user wishes to use these effects I’ve put the folders containing the html code, and a sample image here.

Both effects are set to use Image.jpg for the frag/defrag effect. If you need to use a png, simple copy Image.png into the folder and edit the html code to to use Image.png instead of Image.jpg.

Capture%2002

The data control attribute is set to 2 seconds at 30 fps. The column width and height are set to 10.

The easiest way to use the effects is to copy the folder(s) to the project you are working on
and create one folder for each effect then use the overlay HTML filter to apply the effect to the image.

Capture%2001

Put the image you want to use in the folder and overwrite my sample image.

3 Likes

WOW - fantastic demos, @sauron . @elusien 's fragmentation/defrag work so well as transitions!!! Can’t wait to experiment with this. Thanks sauron for making the resources available for download. Excellent work :grinning::grinning::grinning::+1::+1::+1:

It took me a while to figure out how to modify the code.

Html overlay wasn’t working until 18.12.23. Now it’s working pretty well with the Beta. At times it slows to a crawl. Found it easier to use chrome browser to do most of the experimenting.

Looking forward to see what you do with the frag/defrag.

Hey, hey, HEY! - Success today making transitions (inspired by @sauron ’ s work above) using @Elusien 's Defragmentation feature (part of his WebVfx framework).

The result:

https://streamable.com/538l3

So, my demo has 8 images (they are frame captures grabbed using Shotcut, from a video). I called them image01.png, image02.png etc. I copied the “Defragmentation” HTML file 8 times, changing the image of each one to image01.png, image02.png etc…

My folder looked like this:
shotcut%20forum%20folder%2001

Then imported the 8 pngs onto 8 video tracks, as shown here:

Then split image01 into two, making the second bit 2 seconds long. Then applied “Defrag image02” to the Overlay HTML filter.

(It took me a while to realise that the HTML file should relate to the clip BELOW, not the clip itself…)

Then repeated the process with image02 - image07, but split these images into 3 bits (beginning transition, middle, end transition).

Finally, image08 was split into 2, and a fade-out applied.

It’s really a doddle to do. I think some users may be daunted by doing this but should have a go…
Grateful thanks to @elusien and @sauron!

1 Like

UPDATE - I just made a TITLE and added it to my video above:
Result:

https://streamable.com/yoo5j

Cheers!
Jon

3 Likes

I should have included my track layout and made things a bit easier. You have 7 tracks too many.:smile: Did mine with 1 track for the transitions and 1 audio track.

Made a 1 second split at 1A 2A 3A 4A and 5A. Then overlaid 2 on 1A, 3 on 2A. 4 on 3A, and 5 on 4A.

Ah, a much simpler solution! :grinning: Wish I’d done that!:yum::yum: Thank you.
Anyway I think it’s a really cool effect. I have no idea whatsoever how anyone can think of code to produce this effect. Mind-blowing!

Also, question to @elusien - could the code be adapted so as to achieve transitions between video clips, rather than still images? Thanks.

I’m afraid not. My HTML fragmentation code can only handle static images. You could get a snapshot image of the the last frame of one clip, apply the fragmentation filter to it, then get a snapshot image of the first frame of the next clip and apply the defragment filter to that. Similar to what you did in your video.

However, there are a whole set of different transitions (67 to be precise) showcased on here:

GL Transitions

To see how they perform you can play about with them by moving your mouse pointer across the individual images. You can tailor them by clicking on the image. Dan has been good enough to provide me with some code that I am using to make it simple for any user of Shotcut to make use of them. See here:

I have written the first bit of code and now it is fairly easy to do the rest. I should have something available for people to try within the next few days.

The code is an Overlay HTML filter that you apply to a transition. To use it:

  • You create a very simple HTML file that has just the HTML ‘<canvas>’ tag in it specifying the name of the transition you want to use and any of its parameters that you want changing e.g. ‘<canvas id=“swirl”></canvas>’

  • You then create a transition between two clips as would normally (dragging the left clip part way over the right).

  • You then select the transition area on the track and apply the Overlay HTML filter (with the WebVfx option ticked) to it.

Et voila - the transition is applied. It uses the GPU for rendering the transition.

I will make an announcement on the forum when I have the finished product for people to use. At some stage I might get round to adding some of my own transitions into this new framework.

1 Like

A bit of silliness.:grin:

https://streamable.com/4r0ck

1 Like

That sounds really exciting, @elusien ! Can’t wait to see the new framework and trying it out. :grinning::grinning:

Two for the price of one … :grinning::grinning:

Made a reasonable fragment transition between video clips. Used @Elusien’s suggested method with some modification.

https://streamable.com/1wd80

1 Like

Looking good, @sauron. Would it look OK if the transition was slightly slower? Or would it appear a bit stuttery because of the still frame?

The clip I used is 25 fps. I Set the transition to 12 frames for the demo. Tried it with a 16 frame transition. Looked OK just a sight stutter. Tried with a 1 sec transition. Didn’t look good.

I think using 1/2 the frame rate of the footage might be the best way until video can be used with the fragment code.

Great. Thanks. Will try it at 1/2 frame rate.

There might be a better way to do this. Here’s what I did.

1 Using Export frame, export 1 frame from the end of clip A and 1 frame from the beginning of clip B
2 Open the images, put them in the playlist.
3 Put both images on the timeline, create a 12 frame transition by overlapping A on B or B on A. Delete the excess at both ends.

image

4 Apply two overlay HTML filters to the transition. Fragment followed by de-fragment.
5 Put the transition between Clip A and B.

Frag%20Transition%202

6 This is the part I forgot to do. Trim 1 frame off the end of clip A and 1 off the beginning of Clip B, to avoid frame duplication and make the stutter less.

The transition can made longer or shorter. I used 12 frames and tried 16. Both looked reasonable.

In the fragment and de-fragment code I changed the values of start from 0.05 to 0.0 and the nh and nv values from 10 to 20, for a denser fragmentation.

Wow - ingenious and clever!! Have you a demo to show the result ? :grinning::grinning::+1::+1:

Might try to make a demo later.

No problem - only if you have time .:sunglasses:

This topic was automatically closed after 90 days. New replies are no longer allowed.