Switching between 5 videos at random

Apr 12, 2010 at 9:14pm

Switching between 5 videos at random

OK, so I'm working on this patch where i want 4 videos played in random sequence one after the other. Each time the patch is opened the sequence should be different, once one video ends it should trigger the next to be played with no repeats. So far i have the [urn] object set up to choose between random numbers and I have that connected to the [umenu] object. However I can't figure out how to load my videos into [umenu] can anyone help?

below is a screenshot of my batch so far any suggestions at all are welcome.


  1. Screen_shot_2010-04-12_at_5.09.37_PM.png
Apr 12, 2010 at 10:36pm

send a 'path' message to 'thispatcher' to populate the umenu with your movies. I've attached an example which will read a folder called movies, if the folder is in the same location as your patch. nb, you will have to change this if you want to make a standalone.


  1. Picture_7.png
Apr 13, 2010 at 1:11am

Still having trouble loading movies into [umenu] i've put them into the menu items but I can't get the actual movies to play in the quicktime window. Here is a screen shot of my patch. my movies in the same folder as my patch which is entitled “movies”. the [urn] object seems to be working well enough in switching the videos but I can't get them to actually play the videos.


  1. Screen_shot_2010-04-12_at_9.00.54_PM.png
Apr 13, 2010 at 12:52pm

suggestions anyone?

Apr 13, 2010 at 3:56pm

Connect the second outlet of the umenu to the [prepend read], the first one will only give you the number of the selected item in the menu


Apr 14, 2010 at 3:13pm

ok, so i’ve got this to do just about everything i want it to except actually play my movies. i have a list of movies in the menu items information part of [umenu] my movies are located in a documents folder entitled movies. It is cycling through the movies at random each time a bang is sent until all movies are played but i won’t actually play the movies in the viewer.

Apr 14, 2010 at 4:53pm

post your patch
in edit mode, select all, edit menu, copy compressed, paste here


Apr 14, 2010 at 5:01pm

hey asmarquis, this is what i am currently working with.
could it be that you just forgot the metro object ?
I suppose its similar to your issue:

– Pasted Max Patch, click to expand. –
Apr 14, 2010 at 6:10pm

dimbels, could you post this as a screen shot? for some reason all i see is a bunch of code, no maxx patch

Apr 14, 2010 at 6:11pm
– Pasted Max Patch, click to expand. –
Apr 14, 2010 at 6:56pm

here you go.


  1. Untitled2.png
Apr 14, 2010 at 11:32pm
– Pasted Max Patch, click to expand. –
Apr 15, 2010 at 12:35am

How do i use that in my own patch? I just see a bunch of code. where do i plug it in?

Apr 15, 2010 at 1:12am

copy between —-begin—- & —-end—– (included)

> max > file menu > new from clipboard


Apr 16, 2010 at 3:56am

can’t open it. not sure why, running demo version of maxx and won’t let me open this code in maxx. anyway you could post a screen shot of this?

Also wanted to say thanks for all the help from everyone so far. As a newbie and someone not at all familiar with coding or maxx the help provided by everyone on this site have help me tremendously

Apr 16, 2010 at 6:50am
Apr 16, 2010 at 9:19pm

Maxx won’t even let me open new patch from clipboard. I don’t get it. i can open a new patcher window or new from template but specifically clipboard will not open

Apr 16, 2010 at 9:25pm

Here's a screenshot, I don't see any reason why copy/pasting would not work


  1. Image_1.jpg
Apr 17, 2010 at 6:16pm

make sure you have the latest version of max installed (5.1.3 i think)

if so, try reinstalling and trashing your preferences.

if no luck, contact support@cycling74.com

Apr 17, 2010 at 8:44pm

thanks rob. got it to work. apparently i wasn’t copying the entire code and just didn’t notice it


You must be logged in to reply to this topic.