AB folder selection video player

Guy Wigmore's icon

Hi,

I hope someone can point me in the right direction here.

I want to make a video player for an installation.

The player will play videos from two folders and alternate between the two in an ABABAB pattern.

I want the videos to play randomly, but I don't want them to repeat.

Ideally, I would like to play a specific video: "start.mov" first and "end.mov" last before repeating the whole pattern.

If anyone can help, I'd be very grateful.

Noise Wrangler's icon

To get you started:

  • To alternate between folder, a simple bang to a trigger will alternate between zero and one - Use select 0 1 to choose which folder

  • For random play, use a coll to store an index and the name of the video files except the start and end video.

  • Play start.mov

  • Pick randomly from your coll the next file (random on the length of the coll)

  • When the coll is empty, play end.mov

Guy Wigmore's icon

Thanks! I’ll give this a shot

Guy Wigmore's icon

So I had a go. I struggled to get anywhere with the suggestions, but it did get me started.

I have something that works, except for playing the end.mp4 file.

Max Patch
Copy patch and select New From Clipboard in Max.

If anyone has any advice on how to make this work or how to make it a bit more streamlined I'd love to hear it.

Source Audio's icon

buddy bangs after both urns run to the end

Guy Wigmore's icon

Thanks, this helps clean things up a bit but I think it often causes the final file in the urn list to play twice.

I need a way to signal when the end.mp4 finishes playing and then play start.mp4 and begin the sequence again.

Currently, I'm using loopnotify, but this triggers the end and starts files simultaneously, so I only see start.mp4.

Source Audio's icon

then observe clip named end.mp4 to open gate for actions you need

Source Audio's icon

actually you don't use random A/B selection,

it is allways A B A B ... or B A B A ...

first urn which outputs done bang will do to reset the cycle

Max Patch
Copy patch and select New From Clipboard in Max.

Guy Wigmore's icon

Wow, this works so nicely. Thanks you for taking the time, still a lot to learn for me!