Do you think that Jitter would be able to do this project?

May 17, 2006 at 6:58am

Do you think that Jitter would be able to do this project?

Hey all.. :)

I’m trying to spec out a real-time video project, and some friends suggested I look into Jitter. The processing seems pretty straightforward, but I have only basic experience with MAX/MSP. If anyone comments on whether this is feasible in Jitter, I’d be really happy.

The project is basically to ‘speed up a party in realtime.’ So I’ll take a surveillance camera looking over a party, speed it up by 5X, and output it to a TV at the party. So for instance, if the camera has been filming for 5 minutes, it would playback in 1 minute. At the end of the minute of fast playback, it would then play the 6 minutes that have elapsed in 1 minute and 12 seconds or so. So it would keep repeating, getting longer and longer.

I’ve looked through some tutorials, and I see how to speed up playback. But the devil is in the details–so any suggestions would be lovely.

I’ve tried to break up the project in 5 parts:

1. Video from a surveillance camera is positioned over a crowded party. The camera uses a video RCA out (which I’m still trying to figure out how to connect to MAX… I think I need to borrow my friend’s G5 with the vid card). But let’s say I use an iSight to make it easy

2. I’d want to capture all the footage from the party (say 4 hours worth). so, I imagine that I take incoming footage and put it in a buffer. Let’s call it the ‘capture buffer.’ (Does Jitter work like this?)

3. Once the footage has begun recording, I’d want to copy the capture buffer to another ‘playback buffer’ , which is sent to playback, sped up by 5 times. (I saw the tutorial on speeding up video, but it seems like I have to save the video as a file first. is that right?)

4. At the end of the playback buffer I’d want to copy the capture buffer again (which would now be longer, having captured more footage during the playback) and send it to the playback buffer. So, the footage would be replayed again, at 5 times speed, but go a little bit longer.

5. Ideally this repetitive, sped up footage of the party would be outputted to a TV. That way people can watch a sped up version of the party they are at on TV. :)

Again, any suggestions or references would be super. Thank you!

#26009
May 17, 2006 at 9:12am

Hi Julia,

I am pretty sure this is possible in Jitter. I’d say:

Use the jit.qt.grab object to capture video from your video digitizer hardware and save it to disk once in a while.

-or- (if this results in gaps in the captured video)

Route the jit.qt.grab object’s video output into two alternating jit.qt.record objects and let these objects write to disk once in a while.

then

Append the new data from disk to the movie you are playing with the jit.qt.movie object. I didn’t try this before but I assume it is possible to append the new data as a quicktime reference, which means it wouldn’t be necessary to actually move data on your disk (meaning this shouldn’t be a time-consuming operation).

Speeding up a movie is a basic functionality of jit.qt.movie.

360 x 288 photo-jpeg compression should be fine if you want to send the output to a tv, which makes recording 4 hours of video reasonable.

Have a look at the help files of these objects. You will probably find working examples of the 5 parts you defined. Especially the ‘p editing’ in the help file of jit.qt.movie will probably be interesting for you.

We use an ADVC-100 video digitizer with the jit.qt.grab object to get RCA (composite) video into the computer. I recommend this hardware (when you are working on mac, never tested on pc), especially if audio quality is not your primary concern.

Outputting the video to a tv would probably require a scan converter to convert your VGA signal to composite video. I don’t like these things though, I always have the feeling this should be possible to do in an easy way and certainly shouldn’t have to be so expensive. Anyone has a hint here?

Good luck!
Mattijs

#77255
May 17, 2006 at 5:10pm

Hi Julia,
Basically, you are trying to do real-time time-lapse photography. You’ll
really only need to use jit.qt.grab and jit.matrixset if your computer
has enough RAM. Just set a metro to grab a frame every ~second or
whatever, and write it into the jit.matrixset. The jit.matrixset help
patch should get you there.

If your computer has S-video out, that can be sent to TV with minimal
effort and hardware.

Good luck and Happy Patching
Andrew B.

#77256
May 17, 2006 at 5:15pm

FWIW,
I did something like this a while ago using a 3d buffer coupled with
jit.xfade. I would accumulate every N frames into a 3dbuffer and
xfade between successive frames, creating a sped up look to the live
video.

wes

#77257
May 17, 2006 at 5:54pm

On May 17, 2006, at 12:15 PM, Wesley Smith wrote:

> FWIW,
> I did something like this a while ago using a 3d buffer coupled with
> jit.xfade. I would accumulate every N frames into a 3dbuffer and
> xfade between successive frames, creating a sped up look to the live
> video.

Crossfades? Phooey! For that real Davey and Goliath/Wallace
and Grommit/Ray Harryhausen/Gumby/animated desktop toy
fun, here’s something bone-simple from workshopland.

The metamessage here? There is almost always more than one
way to achieve a given end. Some are elegant and erudite and
require a certain level of propellorheadedness [a la matrix
demiurges Andrew and Wesley], and um… some are not.

I think it’s a lot more interesting to slow humans down than to
speed them up. But I also found The 24-hour stretch of
Beethoven’s Ninth to be a salutary experience as well
[a 20 minute subdominant? now *that's* what I call leaning
into something]. At any rate, it’s not your usual throbbing
donut or playing “pin the sample on the donkey I see on
the webcam in the gallery,” request, so let’s all sing wo-hee-la
and share….

max v2;
#N vpatcher 190 45 1179 765;
#P window setfont “Sans Serif” 20.;
#P window linecount 1;
#P comment 354 626 426 196628 5. punch the stop box when you’re done.;
#P window linecount 2;
#P comment 354 563 426 196628 4. move the stuff the camera’s pointing
at and hit the space bar or turn on the metro;
#P window linecount 3;
#P comment 354 473 426 196628 3. click on the write message box to
set the parameters for the recording you’re writing to disk;
#P window linecount 1;
#P comment 354 437 426 196628 2. turn on the metro to jit.qt.grab;
#P window setfont “Sans Serif” 14.;
#P window linecount 2;
#P comment 425 30 107 196622 or run it from a timer….;
#P window linecount 3;
#P comment 303 30 107 196622 write a frame using the space bar….;
#P window linecount 1;
#P comment 339 322 297 196622 stop recording;
#P toggle 426 90 19 0;
#P newex 426 127 116 196622 metro 2000;
#P message 283 322 49 196622 stop;
#P message 282 255 238 196622 write 30. jpeg normal 600;
#P newex 109 395 112 196622 jit.qt.record;
#B color 5;
#P newex 303 127 64 196622 sel 32;
#P newex 303 90 41 196622 key;
#P button 303 167 28 0;
#P newex 109 254 161 196622 jit.matrix @thru 0;
#P user jit.pwindow 13 436 322 242 0 1 0 0 1 0;
#P user jit.pwindow 13 189 82 62 0 1 0 0 1 0;
#P message 191 60 52 196622 open;
#P toggle 109 30 19 0;
#P newex 109 59 80 196622 metro 2;
#P newex 109 113 94 196622 jit.qt.grab;
#P window linecount 3;
#P comment 525 255 267 196622 This tells the jit.qt.record object
what kind of movie you want to make (frames/sec. codec quality
timebase);
#P window setfont “Sans Serif” 20.;
#P window linecount 2;
#P comment 354 374 426 196628 1. use the open message to jit.qt.grab
to select a device;
#P connect 2 0 6 0;
#P connect 8 0 7 0;
#P connect 4 0 3 0;
#P connect 3 0 2 0;
#P connect 5 0 2 0;
#P connect 2 0 8 0;
#P fasten 9 0 8 0 308 216 114 216;
#P connect 8 0 12 0;
#P connect 14 0 12 0;
#P connect 13 0 12 0;
#P connect 10 0 11 0;
#P connect 15 0 9 0;
#P connect 11 0 9 0;
#P connect 16 0 15 0;
#P pop;

#77258
May 17, 2006 at 6:20pm

Well, I was doing a cubic pass from [0, 1] on the crossfade so it
wasn’t so linear looking and muddy grey all the time. Most of the
fade was spent near the actual frames. The xfade was just to provide
that oh so subtle transition.

Actually, now that I think about more, the patch had a dual
purpose…slowmo and speedup. I think the xfade only happened on the
slowmo and I just showed raw frame on the speed up.

wes

#77259
May 17, 2006 at 7:16pm

Ah. Now *that’s* interesting. Perhaps I should invent a
fake newbie identity and post fake patch grovels designed
to flood the newsgroup with stuff I might find more
personally interesting….

Hi! I have an end-of-term project where I need to
combine slitscanning and very long crossfades.
Can someone send me a patch that does this?
And can you make it so that I can hide the menu
bar on your patch? Thanks!!!!

:-) :-) :-) :-)

#77260
May 17, 2006 at 7:46pm

max v2;
#N vpatcher 10 59 610 459;
#P window setfont “Sans Serif” 9.;
#P window linecount 1;
#P message 229 121 43 196617 size 40;
#P message 336 75 14 196617 1;
#P newex 302 42 48 196617 loadbang;
#P message 260 298 70 196617 fullscreen $1;
#P toggle 511 264 15 0;
#P newex 510 244 38 196617 sel 27;
#P newex 509 217 40 196617 key;
#P message 194 220 232 196617 position 0. -0.5 0. , color 1. 0. 0. 1
, text “STFU”;
#P window linecount 2;
#P message 252 181 245 196617 position 0. 0.5 0 , color 0. 0. 0. 1
, text “OMFG RTFM”;
#P window linecount 1;
#P message 119 279 112 196617 erase_color 1. 1. 1. 1.;
#P message 104 298 109 196617 erase_color 0. 0. 0. 1;
#P newex 140 146 41 196617 sel 0 1;
#P newex 194 251 87 196617 jit.gl.text2D stfu;
#P toggle 63 44 15 0;
#N counter 1;
#X flags 0 0;
#P newobj 140 111 66 196617 counter 1;
#P newex 275 330 180 196617 jit.window stfu @floating 1 @interp 1;
#P newex 63 327 86 196617 jit.gl.render stfu;
#P newex 63 118 58 196617 t b b erase;
#P newex 63 67 51 196617 qmetro 2;
#P connect 17 0 5 0;
#P connect 5 0 0 0;
#P connect 0 0 1 0;
#P connect 1 0 2 0;
#P connect 1 2 2 0;
#P connect 8 0 2 0;
#P connect 9 0 2 0;
#P connect 7 0 8 0;
#P connect 7 1 9 0;
#P connect 0 0 4 0;
#P connect 4 0 7 0;
#P connect 7 0 11 0;
#P connect 10 0 6 0;
#P connect 1 1 6 0;
#P connect 11 0 6 0;
#P connect 18 0 6 0;
#P connect 16 0 18 0;
#P connect 7 1 10 0;
#P connect 14 0 15 0;
#P connect 15 0 3 0;
#P connect 16 0 17 0;
#P connect 12 0 13 0;
#P connect 13 0 14 0;
#P connect 17 0 14 0;
#P pop;

#77261
May 17, 2006 at 7:57pm

On May 17, 2006, at 2:46 PM, vade wrote:

> max v2;
> #N vpatcher 10 59 610 459;

…..


Now who’s gonna clean up all the coffee that squirted out
my nose because I was laughing so hard and got all over
this new ish of EQ?

#77262
May 17, 2006 at 8:07pm

On May 17, 2006, at 2:46 PM, vade wrote:

> max v2;
> #N vpatcher 10 59 610 459;

and you forgot the epilepsy disclaimer.

“Hi! I’ve got an end-of-term project where I’d
like to simulate really hokey 70′s laser light
shows. Can you send me a patch? Thanks!!!!”

:-) :-) :-) :-)

#77263
May 17, 2006 at 9:00pm

I’ve tried using forums before, but this is amazingly helpful. :> I’ve had friends use Jitter and modify existing patches, but it is really intimidating to try to use a new program for a very specific effect, when you aren’t even sure if it will be useful. So thanks for the encouraging suggestions!!

I’ll try to post my progress– I think I have a good sense of where to go now, but I might toss out a few more questions..

I really liked the comment about slowing down Beethoven.. Did it maintain the original pitch? Was it based off of a score or a recording?

I’m interested in how changing time changes the way we interperet emotions. Have you ever seen the movie Koyanisquatsi? Gorgeous.

Thanks again~

#77264

You must be logged in to reply to this topic.