Forums > Jitter

makin' waves

April 19, 2006 | 6:20 pm

Hi,

I would love any creative suggestions or pointers for this piece. I’m trying to improve an installation that I have been working on. Ultimately I would like to use my version of Brecht’s panorama patch (from a few weeks ago), where 4 jit.gl.texture-sketch are used as tiles. However, I’d like to simulate water/waves over these planes – similar to the pool-3d-nurbs.pat from the examples folder. I’m using a 1.67ghz mac 1gb ram 128 vram powerbook tiger 10.4.4

(my simple version of Brecht’s patch at bottom of email)

First, here’s a patch of the basic "look" of what I am trying to accomplish. This patch allows you to draw the waves and then with jit.op and jit.brass it mixes with a video file. So I basically eliminated the nurb from the example patch (which I’d rather not do – but am willing to if it takes too much processing). I’d rather eliminate the op and brass.

#P user jit.pwindow 451 555 322 242 0 1 0 0 1 0;
#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 758 429 69 196617 prepend mask;
#P user multiSlider 758 379 128 36 -20. 20. 4 2665 47 0 0 2 0 0 1;
#M frgb 0 0 0;
#M brgb 255 255 255;
#M rgb2 127 127 127;
#M rgb3 0 0 0;
#M rgb4 37 52 91;
#M rgb5 74 105 182;
#M rgb6 112 158 18;
#M rgb7 149 211 110;
#M rgb8 187 9 201;
#M rgb9 224 62 37;
#M rgb10 7 114 128;
#P message 573 431 173 196617 atint $1 , rtint $2 , gtint $3 , btint $4;
#P user multiSlider 573 381 175 44 0. 1. 4 2681 47 0 0 2 0 0 1;
#M frgb 0 0 0;
#M brgb 255 255 255;
#M rgb2 127 127 127;
#M rgb3 0 0 0;
#M rgb4 37 52 91;
#M rgb5 74 105 182;
#M rgb6 112 158 18;
#M rgb7 149 211 110;
#M rgb8 187 9 201;
#M rgb9 224 62 37;
#M rgb10 7 114 128;
#P newex 476 459 49 196617 jit.brass;
#P user ubumenu 510 486 60 196617 0 1 1 0;
#X add *;
#X add +;
#X prefix_set 0 0 0;
#P newex 535 507 72 196617 prepend op;
#P newex 452 529 34 196617 jit.op;
#P message 452 341 30 196617 read;
#P newex 452 362 105 196617 jit.qt.movie 320 240;
#P newex 33 353 113 196617 jit.clip @min 0 @max 1;
#P hidden message 309 56 55 196617 onscreen 0;
#P newex 33 333 105 196617 jit.op @op * @val 0.5;
#P newex 33 313 99 196617 jit.op @op + @val 1.;
#P message 145 57 162 196617 0.1 0.4 0.1 0.4 0. 0.4 0.1 0.4 0.1;
#P newex 290 229 73 196617 append val 0.9;
#P newex 290 205 75 196617 prepend setcell;
#P newex 330 101 71 196617 r pwind_dump;
#P newex 183 530 71 196617 s pwind_dump;
#P newex 330 161 48 196617 pack i i;
#P newex 290 182 50 196617 gate;
#P newex 330 139 86 196617 unpack i i i;
#P newex 330 120 63 196617 route mouse;
#P newex 33 103 104 196617 jit.qball @mode usurp;
#P newex 145 33 50 196617 loadbang;
#P user jit.pwindow 32 403 162 122 0 1 0 0 1 0;
#P newex 211 251 124 196617 jit.matrix swap1 @thru 0;
#P window linecount 2;
#P newex 199 452 114 196617 jit.op @op * @val 0.99 @in2_dim 160 1;
#P window linecount 1;
#P newex 33 135 50 196617 t b b b;
#P newex 199 429 64 196617 jit.op @op !-;
#P newex 199 278 192 196617 jit.matrix t2 1 float32 160 120 @thru 0;
#P window linecount 3;
#P newex 33 189 84 196617 jit.matrix t1 1 float32 160 120 @thru 0;
#P window linecount 1;
#P newex 33 285 101 196617 jit.convolve;
#P newex 145 78 75 196617 jit.fill kernel 0;
#P user jit.pwindow 144 121 38 38 0 0 0 0 1 0;
#P newex 145 101 145 196617 jit.matrix kernel 1 float32 3 3;
#P flonum 78 56 35 9 0.5 0 1 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P toggle 33 58 15 0;
#P newex 33 82 55 196617 metro 20;
#P newex 33 373 129 196617 jit.matrix 4 char 160 120;
#P window linecount 2;
#P comment 35 529 100 196617 drawing here makes waves;
#P window linecount 1;
#P comment 572 488 174 196617 setting to add works well;
#P comment 575 366 156 196617 find a nice blue for water;
#P comment 758 363 100 196617 sets emboss level;
#P connect 42 0 43 0;
#P connect 40 0 41 0;
#P connect 38 1 37 0;
#P connect 39 0 36 1;
#P fasten 41 0 39 0 578 452 481 452;
#P fasten 43 0 39 0 763 452 481 452;
#P connect 4 0 18 0;
#P fasten 4 0 39 0 38 396 481 396;
#P connect 36 0 44 0;
#P fasten 37 0 36 0 540 526 457 526;
#P connect 34 0 36 0;
#P connect 35 0 34 0;
#P connect 20 0 15 0;
#P connect 20 0 34 0;
#P connect 22 1 24 1;
#P connect 24 0 23 1;
#P connect 22 0 24 0;
#P connect 21 0 22 0;
#P connect 26 0 21 0;
#P connect 19 0 29 0;
#P hidden fasten 19 0 32 0 150 53 314 53;
#P connect 27 0 28 0;
#P connect 23 0 27 0;
#P fasten 22 2 23 0 411 158 295 158;
#P connect 11 0 30 0;
#P fasten 11 0 14 1 38 306 258 306;
#P fasten 15 1 17 0 58 183 216 183;
#P fasten 28 0 17 0 295 248 216 248;
#P connect 12 0 11 0;
#P fasten 12 0 17 0 38 237 216 237;
#P connect 14 0 16 0;
#P connect 13 0 14 0;
#P fasten 15 2 13 0 78 166 204 166;
#P fasten 17 0 13 0 216 272 204 272;
#P connect 18 1 25 0;
#P connect 8 0 9 0;
#P hidden fasten 32 0 9 0 314 97 150 97;
#P connect 10 0 8 0;
#P connect 29 0 10 0;
#P fasten 9 0 11 1 150 275 129 275;
#P connect 7 0 5 1;
#P connect 33 0 4 0;
#P connect 31 0 33 0;
#P connect 30 0 31 0;
#P fasten 16 0 12 0 204 558 22 558 22 179 38 179;
#P fasten 15 0 12 0 38 164 38 164;
#P connect 5 0 20 0;
#P connect 6 0 5 0;
#P window clipboard copycount 45;

and here’s the jit.gl.texture-sketch patch… is there a way to draw on the "texture-sketch" like you can with the nurb (ctlmatrix)? or is there a way to route the "texture-sketch" output to texture the nurb which is being drawn? I’ve tried several ways to cut/paste these two patches together, but the cpu/gpu take too much of a hit.

#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 12 232 56 196617 s loadbang;
#P newex 12 212 48 196617 loadbang;
#P message 12 171 70 196617 fullscreen $1;
#P toggle 12 153 15 0;
#P newex 12 190 80 196617 jit.window bart;
#B color 6;
#P message 141 163 30 196617 read;
#P message 141 145 30 196617 read;
#P message 141 199 30 196617 read;
#P message 141 182 30 196617 read;
#N vpatcher 265 193 1257 738;
#P window setfont "Sans Serif" 9.;
#P message 444 114 43 196617 0.0002;
#N comlet metro;
#P inlet 12 60 15 0;
#N comlet bangs;
#P inlet 130 66 15 0;
#P newex 783 47 56 196617 r loadbang;
#P newex 420 257 20 196617 t b;
#P newex 392 256 27 196617 + 0.;
#P newex 299 257 20 196617 t b;
#P newex 271 256 27 196617 + 0.;
#P newex 178 258 20 196617 t b;
#P newex 150 257 27 196617 + 0.;
#P newex 57 255 20 196617 t b;
#P newex 29 254 27 196617 + 0.;
#P newex 445 234 47 196617 * 10.72;
#P newex 445 216 27 196617 int;
#P newex 445 196 44 196617 < -5.36;
#P newex 324 234 47 196617 * 10.72;
#P newex 324 216 27 196617 int;
#P newex 324 196 44 196617 < -5.36;
#P newex 203 234 47 196617 * 10.72;
#P newex 203 216 27 196617 int;
#P newex 203 196 44 196617 < -5.36;
#P newex 82 234 47 196617 * 10.72;
#P newex 82 216 27 196617 int;
#P newex 82 196 44 196617 < -5.36;
#P newex 375 155 27 196617 + 0.;
#P newex 375 133 60 196617 float -2.68;
#P newex 382 283 20 196617 t b;
#P newex 375 325 31 196617 float;
#P newex 375 304 27 196617 + 0.;
#P newex 392 234 52 196617 * -10.72;
#P newex 375 175 31 196617 float;
#P newex 392 216 27 196617 int;
#P newex 392 196 39 196617 > 5.36;
#P newex 254 155 27 196617 + 0.;
#P newex 254 133 43 196617 float 0.;
#P newex 261 283 20 196617 t b;
#P newex 254 325 31 196617 float;
#P newex 254 304 27 196617 + 0.;
#P newex 271 234 52 196617 * -10.72;
#P newex 254 175 31 196617 float;
#P newex 271 216 27 196617 int;
#P newex 271 196 39 196617 > 5.36;
#P newex 133 155 27 196617 + 0.;
#P newex 133 133 55 196617 float 2.68;
#P newex 140 283 20 196617 t b;
#P newex 133 325 31 196617 float;
#P newex 133 304 27 196617 + 0.;
#P newex 150 234 52 196617 * -10.72;
#P newex 133 175 31 196617 float;
#P newex 150 216 27 196617 int;
#P newex 150 196 39 196617 > 5.36;
#P newex 12 109 53 196617 t b b b b;
#P newex 12 155 27 196617 + 0.;
#P newex 12 133 55 196617 float 5.36;
#P newex 12 325 31 196617 float;
#P newex 12 304 27 196617 + 0.;
#P newex 29 234 52 196617 * -10.72;
#P newex 12 175 31 196617 float;
#P newex 29 216 27 196617 int;
#P newex 29 196 39 196617 > 5.36;
#P newex 382 475 99 196617 pak position 0. 0. 0.;
#P newex 382 434 99 196617 pak position 0. 0. 0.;
#P newex 382 392 99 196617 pak position 0. 0. 0.;
#P message 482 475 290 196617 reset , position -2.68 0. 0. , plane 1.34 1.005 , texture water4;
#P newex 482 496 305 196617 jit.gl.sketch bart @blend_enable 1 @automatic 0 @depth_enable 1;
#P message 482 434 273 196617 reset , position 0. 0. 0. , plane 1.34 1.005 , texture water3;
#P newex 482 456 305 196617 jit.gl.sketch bart @blend_enable 1 @automatic 0 @depth_enable 1;
#P message 482 392 285 196617 reset , position 2.68 0. 0. , plane 1.34 1.005 , texture water2;
#P newex 482 414 305 196617 jit.gl.sketch bart @blend_enable 1 @automatic 0 @depth_enable 1;
#P newex 382 350 99 196617 pak position 0. 0. 0.;
#P message 482 351 285 196617 reset , position 5.36 0. 0. , plane 1.34 1.005 , texture water1;
#P newex 484 371 305 196617 jit.gl.sketch bart @blend_enable 1 @automatic 0 @depth_enable 1;
#P newex 19 283 20 196617 t b;
#P connect 71 0 21 0;
#P connect 21 0 19 0;
#P connect 19 0 20 0;
#P connect 20 0 15 0;
#P connect 15 0 17 0;
#P fasten 0 0 17 0 24 301 17 301;
#P connect 17 0 18 0;
#P fasten 61 0 0 0 34 277 24 277;
#P fasten 72 0 20 1 449 153 34 153;
#P fasten 15 0 13 0 17 193 34 193;
#P connect 13 0 14 0;
#P connect 14 0 16 0;
#P connect 16 0 61 0;
#P connect 62 0 61 0;
#P connect 61 0 17 1;
#P fasten 51 0 61 1 87 252 51 252;
#P fasten 18 0 19 1 17 342 9 342 9 131 62 131;
#P fasten 51 0 62 0 87 252 62 252;
#P fasten 15 0 49 0 17 193 87 193;
#P connect 49 0 50 0;
#P connect 50 0 51 0;
#P fasten 21 1 29 0 31 131 138 131;
#P connect 29 0 30 0;
#P connect 30 0 24 0;
#P connect 24 0 26 0;
#P fasten 28 0 26 0 145 301 138 301;
#P connect 26 0 27 0;
#P fasten 54 0 28 0 208 254 145 254;
#P fasten 25 0 28 0 155 254 145 254;
#P fasten 63 0 28 0 155 278 145 278;
#P fasten 72 0 30 1 449 153 155 153;
#P fasten 24 0 22 0 138 193 155 193;
#P connect 22 0 23 0;
#P connect 23 0 25 0;
#P connect 25 0 63 0;
#P connect 64 0 63 0;
#P connect 63 0 26 1;
#P fasten 54 0 63 1 208 254 172 254;
#P fasten 27 0 29 1 138 342 130 342 130 131 183 131;
#P fasten 54 0 64 0 208 254 183 254;
#P fasten 24 0 52 0 138 193 208 193;
#P connect 52 0 53 0;
#P connect 53 0 54 0;
#P fasten 21 2 38 0 45 131 259 131;
#P connect 38 0 39 0;
#P connect 39 0 33 0;
#P connect 33 0 35 0;
#P fasten 37 0 35 0 266 301 259 301;
#P connect 35 0 36 0;
#P fasten 57 0 37 0 329 254 266 254;
#P fasten 34 0 37 0 276 254 266 254;
#P fasten 65 0 37 0 276 278 266 278;
#P fasten 72 0 39 1 449 153 276 153;
#P fasten 33 0 31 0 259 193 276 193;
#P connect 31 0 32 0;
#P connect 32 0 34 0;
#P connect 34 0 65 0;
#P connect 66 0 65 0;
#P connect 65 0 35 1;
#P fasten 36 0 38 1 259 342 251 342 251 131 292 131;
#P fasten 57 0 65 1 329 254 293 254;
#P fasten 57 0 66 0 329 254 304 254;
#P fasten 33 0 55 0 259 193 329 193;
#P connect 55 0 56 0;
#P connect 56 0 57 0;
#P fasten 21 3 47 0 59 131 380 131;
#P connect 47 0 48 0;
#P connect 48 0 42 0;
#P connect 42 0 44 0;
#P fasten 46 0 44 0 387 301 380 301;
#P connect 44 0 45 0;
#P fasten 60 0 46 0 450 254 387 254;
#P fasten 43 0 46 0 397 254 387 254;
#P fasten 67 0 46 0 397 278 387 278;
#P fasten 72 0 48 1 449 153 397 153;
#P fasten 42 0 40 0 380 193 397 193;
#P connect 40 0 41 0;
#P connect 41 0 43 0;
#P connect 43 0 67 0;
#P connect 68 0 67 0;
#P connect 67 0 44 1;
#P fasten 60 0 67 1 450 254 414 254;
#P fasten 18 0 3 1 17 346 416 346;
#P fasten 27 0 10 1 138 388 416 388;
#P fasten 36 0 11 1 259 430 416 430;
#P fasten 45 0 12 1 380 471 416 471;
#P fasten 60 0 68 0 450 254 425 254;
#P fasten 45 0 47 1 380 342 372 342 372 131 430 131;
#P fasten 69 0 72 0 788 72 449 72;
#P fasten 42 0 58 0 380 193 450 193;
#P connect 58 0 59 0;
#P connect 59 0 60 0;
#P fasten 69 0 2 0 788 349 487 349;
#P fasten 69 0 5 0 788 390 487 390;
#P connect 70 0 4 0;
#P connect 5 0 4 0;
#P fasten 10 0 4 0 387 412 487 412;
#P fasten 69 0 7 0 788 432 487 432;
#P connect 70 0 6 0;
#P connect 7 0 6 0;
#P fasten 11 0 6 0 387 453 487 453;
#P fasten 69 0 9 0 788 473 487 473;
#P connect 70 0 8 0;
#P connect 9 0 8 0;
#P fasten 12 0 8 0 387 494 487 494;
#P connect 70 0 1 0;
#P fasten 3 0 1 0 387 369 489 369;
#P connect 2 0 1 0;
#P pop;
#P newobj 320 99 55 196617 p sketchin;
#P user jit.fpsgui 12 119 60 196617 0;
#P newex 176 233 284 196617 jit.gl.texture bart @type char @name water4 @dim 800 600;
#B color 5;
#P newex 176 214 284 196617 jit.gl.texture bart @type char @name water3 @dim 800 600;
#B color 5;
#P newex 176 195 284 196617 jit.gl.texture bart @type char @name water2 @dim 800 600;
#B color 5;
#P newex 176 175 284 196617 jit.gl.texture bart @type char @name water1 @dim 800 600;
#B color 5;
#P toggle 12 26 15 0;
#P newex 12 71 58 196617 t b b erase;
#P newex 12 46 51 196617 qmetro 2;
#P newex 12 98 306 196617 jit.gl.render bart @erase_color 0. 0. 0. 1. @ortho 2 @up 0. -1. 0.;
#P window linecount 2;
#P comment 178 143 100 196617 read in 800×600 image files;
#P fasten 3 1 10 1 41 93 370 93;
#P connect 2 0 3 0;
#P fasten 2 0 10 0 17 67 325 67;
#P connect 12 0 8 0;
#P connect 11 0 7 0;
#P connect 14 0 6 0;
#P connect 13 0 5 0;
#P connect 18 0 19 0;
#P connect 17 0 15 0;
#P connect 16 0 17 0;
#P connect 1 0 9 0;
#P connect 3 0 1 0;
#P fasten 3 2 1 0 65 93 17 93;
#P connect 4 0 2 0;
#P window clipboard copycount 20;

http://www.bartwoodstrup.com
http://www.vodstrup.com


Viewing 1 post (of 1 total)