Forums > Jitter

optimizing ARGB video workflow: tried Vade's patches

March 2, 2008 | 8:33 pm

I have applied all of Vade’s advice that I can but I’m constrained by the external object I’m working with. All inputs to (any 320×240 argb matrix) and outputs from the object must be argb.

It accepts a live input (must be ARGB) and overlays multiple 320×240 argb matrixes (jit.qt.movie is the most commonly used). Using the color mode UYVY distorts both the output and the input. I understand the best compression for the videos seems to be motion jpeg at 80%. With six of the right sized movies playing at once I can get about 19 fps on a Mac Pro and 14 fps on a macbook.

Are there any improvements I can make to the movies that will speed up the overall framerate? Would putting a speedlim on the overlayed movies be advisable?

Thanks.

Patch posted below:

#P window setfont "Sans Serif" 9.;
#P number 132 349 35 9 1 255 3 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 132 308 35 9 1 255 3 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 131 269 35 9 1 255 3 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P number 130 228 35 9 1 255 3 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P user jit.fpsgui 94 540 60 196617 0;
#P window linecount 1;
#P newex 269 547 219 196617 jit.gl.slab JiTag @automatic 0 @dimscale 2. 1.;
#P newex 410 104 35 196617 r met;
#P newex 308 523 35 196617 s met;
#P newex 278 500 40 196617 t b b b;
#P newex 233 597 93 196617 jit.gl.render JiTag;
#P newex 233 473 64 196617 t b b l erase;
#P newex 253 572 270 196617 jit.gl.videoplane JiTag @automatic 0 @transform_reset 2;
#P message 553 81 14 196617 0;
#P message 536 81 14 196617 1;
#P window setfont "Sans Serif" 12.;
#P comment 187 151 25 196620 3.;
#P comment 187 78 23 196620 2.;
#P comment 187 42 26 196620 1.;
#P window setfont "Sans Serif" 9.;
#P message 595 153 44 196617 read all;
#P user panel 184 150 460 21;
#X brgb 255 241 24;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P newex 632 419 32 196617 print;
#P toggle 234 79 15 0;
#P message 661 536 95 196617 CREDITS click here;
#P comment 544 521 212 196617 Max/MSP + Jitter: http://www.cycling74.com;
#P window linecount 4;
#P comment 544 452 211 196617 JiTag: Limited Release 0.1a Future Cinema 2 York University Augmented Reality Lab Unauthorized use or redistribution of this application or any part thereof is prohibited.;
#P window linecount 1;
#P comment 543 505 212 196617 ARTag: http://www.artag.net;
#P user panel 534 446 229 111;
#X brgb 191 191 191;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P toggle 84 397 15 0;
#P message 84 418 53 196617 invert $1;
#P newex 233 452 58 196617 jit.dimmap;
#P message 130 249 69 196617 chroma_a $1;
#P newex 676 171 20 196617 t b;
#P message 638 342 30 196617 read;
#P message 637 309 30 196617 read;
#P message 639 278 30 196617 read;
#P message 638 252 30 196617 read;
#P message 638 223 30 196617 read;
#P message 638 194 30 196617 read;
#P hidden newex 106 160 48 196617 loadbang;
#P message 131 367 69 196617 chroma_b $1;
#P message 131 328 69 196617 chroma_g $1;
#P message 131 289 69 196617 chroma_r $1;
#P message 589 342 27 196617 stop;
#P message 555 342 31 196617 start;
#P message 589 309 27 196617 stop;
#P message 555 309 31 196617 start;
#P message 589 279 27 196617 stop;
#P message 555 279 31 196617 start;
#P message 589 251 27 196617 stop;
#P message 555 251 31 196617 start;
#P message 589 224 27 196617 stop;
#P message 555 224 31 196617 start;
#P message 541 102 39 196617 vol $1;
#P message 589 195 27 196617 stop;
#P message 555 195 31 196617 start;
#P newex 348 373 197 196617 jit.qt.movie 320 240 @adapt 1 @unique 1;
#P newex 251 201 37 196617 r mov;
#P newex 455 130 37 196617 s mov;
#P newex 336 340 197 196617 jit.qt.movie 320 240 @adapt 1 @unique 1;
#P newex 321 312 197 196617 jit.qt.movie 320 240 @adapt 1 @unique 1;
#P newex 306 283 197 196617 jit.qt.movie 320 240 @adapt 1 @unique 1;
#P newex 287 256 197 196617 jit.qt.movie 320 240 @adapt 1 @unique 1;
#P message 455 103 46 196617 frame 1;
#P toggle 106 183 15 0;
#P message 106 204 66 196617 livevideo $1;
#P message 505 103 31 196617 clear;
#P window linecount 2;
#P newex 94 499 130 196617 jit.window JiTag @rect 50 50 670 530 @fsmenubar 0;
#P window linecount 1;
#P message 122 476 68 196617 fullscreen $1;
#P toggle 105 476 15 0;
#P newex 146 455 35 196617 sel 27;
#P newex 104 455 40 196617 key;
#P newex 234 418 393 196617 fcl.artagcube @tagid1 99 @tagid2 88 @tagid3 77 @tagid4 66 @tagid5 55 @tagid6 44;
#P newex 267 228 197 196617 jit.qt.movie 320 240 @adapt 1 @unique 1;
#P user jit.fpsgui 233 625 60 196617 0;
#P message 353 104 46 196617 settings;
#P message 313 104 33 196617 close;
#P message 283 44 30 196617 open;
#P newex 234 129 195 196617 jit.qt.grab 640 480 @vmode 2 @unique 1;
#P window linecount 2;
#P comment 455 74 35 196617 Sync Media;
#P comment 539 51 100 196617 Media Volume Control;
#P comment 125 178 100 196617 Optical or Video See-Through capabilities;
#P comment 15 369 86 196617 Video See-Though or Magic Mirror;
#P window linecount 1;
#P newex 234 102 51 196617 qmetro 2;
#P comment 295 82 100 196617 Live Camera Input;
#P user panel 184 41 136 21;
#X brgb 248 0 0;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P user panel 184 76 71 21;
#X brgb 255 124 8;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P connect 58 0 57 0;
#P fasten 18 0 19 0 127 495 99 495;
#P connect 19 0 80 0;
#P fasten 16 0 17 0 151 474 110 474;
#P hidden connect 47 0 22 0;
#P connect 22 0 21 0;
#P fasten 17 0 18 0 121 491 121 476;
#P connect 81 0 55 0;
#P connect 82 0 44 0;
#P connect 83 0 45 0;
#P connect 84 0 46 0;
#P fasten 15 0 16 0 145 472 145 457;
#P connect 14 0 56 0;
#P fasten 57 0 56 0 89 437 238 437;
#P connect 56 0 74 0;
#P fasten 74 3 75 0 292 495 238 495;
#P connect 74 0 75 0;
#P connect 75 0 12 0;
#P connect 64 0 3 0;
#P connect 3 0 8 0;
#P fasten 11 0 8 0 358 125 239 125;
#P fasten 10 0 8 0 318 125 239 125;
#P fasten 9 0 8 0 288 125 239 125;
#P connect 8 0 14 0;
#P fasten 55 0 14 0 135 265 239 265;
#P fasten 46 0 14 0 136 385 239 385;
#P fasten 45 0 14 0 136 345 239 345;
#P fasten 44 0 14 0 136 306 239 306;
#P fasten 21 0 14 0 111 411 239 411;
#P fasten 76 0 73 0 283 544 258 544;
#P fasten 79 0 73 0 274 568 258 568;
#P fasten 29 0 13 0 256 222 272 222;
#P fasten 48 0 13 0 643 222 272 222;
#P fasten 31 0 13 0 560 222 272 222;
#P fasten 32 0 13 0 594 222 272 222;
#P fasten 76 1 79 0 298 544 274 544;
#P connect 74 2 79 0;
#P fasten 74 1 76 0 256 495 283 495;
#P fasten 29 0 24 0 256 252 292 252;
#P fasten 35 0 24 0 594 252 292 252;
#P fasten 34 0 24 0 560 252 292 252;
#P fasten 49 0 24 0 643 252 292 252;
#P fasten 13 0 14 1 272 405 302 405;
#P fasten 29 0 25 0 256 277 311 277;
#P fasten 37 0 25 0 594 277 311 277;
#P fasten 36 0 25 0 560 277 311 277;
#P fasten 50 0 25 0 643 277 311 277;
#P connect 76 2 77 0;
#P fasten 29 0 26 0 256 307 326 307;
#P fasten 39 0 26 0 594 307 326 307;
#P fasten 38 0 26 0 560 307 326 307;
#P fasten 51 0 26 0 644 307 326 307;
#P fasten 29 0 27 0 256 335 341 335;
#P fasten 41 0 27 0 594 335 341 335;
#P fasten 40 0 27 0 560 335 341 335;
#P fasten 52 0 27 0 642 335 341 335;
#P fasten 29 0 30 0 256 368 353 368;
#P fasten 43 0 30 0 594 368 353 368;
#P fasten 42 0 30 0 560 368 353 368;
#P fasten 53 0 30 0 643 368 353 368;
#P fasten 24 0 14 2 292 405 365 405;
#P fasten 25 0 14 3 311 405 428 405;
#P fasten 78 0 28 0 415 125 460 125;
#P fasten 33 0 28 0 546 126 460 126;
#P fasten 20 0 28 0 510 126 460 126;
#P fasten 23 0 28 0 460 126 460 126;
#P fasten 26 0 14 4 326 405 491 405;
#P connect 71 0 33 0;
#P connect 72 0 33 0;
#P fasten 27 0 14 5 341 405 554 405;
#P fasten 30 0 14 6 353 405 617 405;
#P connect 14 1 65 0;
#P fasten 54 0 52 0 681 307 642 307;
#P fasten 54 0 48 0 681 192 643 192;
#P fasten 54 0 49 0 681 220 643 220;
#P fasten 54 0 50 0 681 250 643 250;
#P fasten 54 0 53 0 681 340 643 340;
#P fasten 54 0 51 0 681 276 644 276;
#P fasten 67 0 54 0 600 172 681 172;
#P window clipboard copycount 85;


Viewing 1 post (of 1 total)