Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Forums Adobe After Effects Expressions Simplest way to randomise playback of video clips

Tagged: 

  • Simplest way to randomise playback of video clips

  • Daniel Jewesbury

    June 16, 2021 at 11:14 pm

    I am entirely new to AE expressions and have been searching old threads in this forum… I am trying to do something EXTREMELY basic but I’m not sure how to adapt scripts I’m finding. I want to be able to put video clips of multiple different lengths (½ sec up to around 17 secs) into my timeline, make them play frames in a random order for x seconds (long enough to be a multiple of the original duration of the clip), and export them as new clips. I’m afraid I’m stumped on quite basic expressions and can’t quite understand how they’re being used. Apologies for this utterly rudimentary query.

    Daniel

  • Tomas Bumbulevičius

    June 17, 2021 at 8:55 am

    Hey Daniel, the task itself needs a bit more clarification here.

    1. You want to put N clips in the comp, incrementally one after another, varying lengths. To do that, drag and drop clips into the comp, select all of them, right click, Keyframe Assistant and Choose Sequence Layers. They will become ordered by in/out points. Thats probably the first step you need to do.
    2. Playbacking – thats not clear enough, but lets see. In a new comp, you need to drop composition created at 1st step. Thus, here you will have a single layer in the comp. Now, considering that, you prefer to have a playback, which randomly picks sections from the main edit and creates a sort of “reel”?
    3. To compliment 2nd point – you mentioned “export them as new clips”. What do you want to export here, as its in plural? Multiple random edits of 2nd step or something else?

  • Daniel Jewesbury

    June 17, 2021 at 9:21 am

    Thanks Tomas,

    Let me clarify my workflow. I’m actually working mainly in Premiere on a film project. What I’m trying to achieve is an effect that I can do with one click of a button in a live VJ environment like Resolume Avenue – when a clip is selected to play, the order in which it plays the frames in that clip can be from first to last, or reversed, or it can be randomised. Since Avenue is treating clips as loops the randomised playback will continue for as long as required, until another clip is selected.

    In my film I have transferred 16mm footage that would be great to use in a (pseudo) randomised way similar to this. In other words I’m trying to use AE to make new clips that will then end up back in Premiere. They will be exported from AE as new clips of a duration x times longer than the original duration, with completely randomised playback for that new duration.

    I don’t mind doing this one at a time, it’s not going to involve a massive number of clips and they aren’t long. So I don’t need to put them all in one comp, so long as I have a routine expression that I can just put in the same way for each one and then export to a new ProRes file.

    Hope that makes clearer what I’m trying to do!

    All best

    D

  • Kevin Camp

    June 17, 2021 at 4:28 pm

    If you just want random frames, this might work for you.

    Drag a clip from the project window onto the new comp icon (this will make a comp that matched the clips specs (size, frame rate, duration, etc), the choose layer > time > enable time remapping and add this expression:

    random( outPoint )

    then add the comp to the render queue.

  • Kevin Camp

    June 17, 2021 at 5:09 pm

    You might also checkout some of Dan Ebberts’ expressions on Motionscript.com. Here is a link to a page that covers a lot of uses for random:

    http://motionscript.com/mastering-expressions/random-3.html

    If you scroll down to ‘Only a Matter of Time’ there are 3 example s of expressions for time remapping clips — the previews are broken since Flash is dead, but if you simply copy/paste the expression onto a clip, you’ll see the result quickly.

  • Daniel Jewesbury

    June 18, 2021 at 1:03 pm

    Perfect. Thank you Kevin, and thanks for the links to Dan’s expressions – I had been looking at some of his posts on threads here at CC and had got bogged down in how everything was working. I wasn’t aware that it was possible to do what I wanted in such a fantastically simple way but it makes perfect sense. Perhaps I’ll take some of my summer holiday to read up on expressions a little more!

Viewing 1 - 6 of 6 posts

Log in to reply.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy