Forums > Jitter

Peculiar size problem when importing tiff

December 7, 2006 | 10:25 am

Hi List,

Anybody know why my images are being resized when imported to jit.qt.movie?

I adapted Wesley Smith’s uvuy blend patch (thanks Wesley) from a few
weeks ago – using a camera input as the "blend." With jit.3m, I
trigger a matrix to grab a frame from the image being rendered to the
GPU. I then want that frame to be loaded into the
jit.qt.movie/videoplane that is the foreground image of the "blend."
It works, but each time a new image loads in it gets progressively
bigger.

I guess you’ll have to look at the patch for it to make sense. I
tried to annotate it thouroughly.

The images I was using are here:

http://bartwoodstrup.com/mount.tif

http://bartwoodstrup.com/mount_back.tif

Max 462 Jitter 162 Mac ppc 1.87ghz 1gb ram 128 vram OSX Tiger

I have to install this in a few days and this is the only thing
holding me back – any help is very much appreciated! Maybe you’ll get
an idea for what I am trying to do – there might be an easier way with
jit.op? I’m open to suggestions.

max v2;
#N vpatcher 68 56 1326 890;
#P window setfont "Sans Serif" 9.;
#P window linecount 2;
#P comment 311 71 204 196617 machine vision used to blend images – use
spacebar to set difference calculation point;
#P window linecount 1;
#P newex 465 617 68 196617 prepend read;
#P newex 998 535 51 196617 zl slice 1;
#P newex 998 514 93 196617 route exportimage;
#P newex 573 420 27 196617 int;
#P newex 573 460 104 196617 prepend exportimage;
#P newex 573 440 116 196617 sprintf scape_0%ld tiff;
#N counter;
#X flags 0 0;
#P newobj 590 367 66 196617 counter;
#P newex 683 376 53 196617 t b b b b;
#P newex 705 492 303 196617 jit.matrix @usesrcdim 1 @srcdimstart 0 599
@srcdimend 799 0;
#P message 748 411 125 196617 reset , glreadpixels vessel;
#P newex 725 434 154 196617 jit.gl.sketch blend @automatic 0;
#P newex 705 455 161 196617 jit.matrix vessel 4 char 800 600;
#P newex 590 318 47 196617 past 30.;
#P newex 564 291 88 196617 unpack 0. 0. 0. 0.;
#P newex 550 270 53 196617 jit.3m;
#P newex 137 244 202 196617 jit.slide @slide_up 350 @slide_down 1000;
#P comment 181 716 100 196617 background;
#P number 230 205 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 137 223 103 196617 jit.op @op > @val 20;
#P newex 137 268 129 196617 jit.matrix 2 char 320 240;
#P newex 137 138 54 196617 jit.change;
#P newex 304 139 65 196617 sel 32;
#P newex 304 119 42 196617 key;
#P newex 304 163 162 196617 jit.matrix @thru 0;
#P newex 137 185 125 196617 jit.op @op absdiff;
#P message 137 94 53 196617 open;
#P newex 137 117 98 196617 jit.qt.grab 320 240;
#P user jit.fpsgui 10 195 60 196617 0;
#P newex 465 666 243 196617 jit.gl.texture blend @colormode uyvy @name mov2;
#P newex 538 712 47 196617 r draw2;
#P newex 465 738 249 196617 jit.gl.videoplane blend @blend_enable 1
@automatic 0;
#P newex 33 690 76 196617 append blender;
#P newex 33 667 243 196617 jit.gl.texture blend @colormode uyvy @name mov1;
#P newex 137 290 325 196617 jit.gl.texture blend @colormode lumalpha
@apply blend @name blender;
#P newex 130 714 47 196617 r draw1;
#N vpatcher 174 130 421 368;
#P window setfont "Sans Serif" 9.;
#P window linecount 0;
#P newex 49 124 30 196617 t b b;
#P newex 69 146 54 196617 s render2;
#P newex 49 168 54 196617 s render1;
#P newex 135 124 30 196617 t b b;
#P window linecount 1;
#P newex 155 146 47 196617 s draw2;
#P newex 135 168 47 196617 s draw1;
#P newex 24 54 66 196617 t b b b erase;
#P inlet 24 34 15 0;
#P outlet 24 85 15 0;
#P connect 1 0 2 0;
#P fasten 2 1 0 0 47 79 29 79;
#P fasten 2 3 0 0 83 79 29 79;
#P connect 2 0 8 0;
#P connect 8 0 6 0;
#P connect 8 1 7 0;
#P fasten 2 2 5 0 65 88 140 88;
#P connect 5 0 3 0;
#P connect 5 1 4 0;
#P pop;
#P newobj 10 120 41 196617 p draw;
#P newex 33 739 249 196617 jit.gl.videoplane blend @blend_enable 1 @automatic 0;
#P message 567 620 30 196617 read;
#P newex 465 643 188 196617 jit.qt.movie 800 600 @colormode uyvy;
#P message 93 618 30 196617 read;
#P toggle 33 597 15 0;
#P newex 33 617 57 196617 qmetro 20;
#P newex 33 644 188 196617 jit.qt.movie 800 600 @colormode uyvy;
#P toggle 30 464 15 0;
#P message 30 484 68 196617 fullscreen $1;
#P newex 30 502 84 196617 jit.window blend;
#P toggle 10 29 42 0;
#P newex 10 75 51 196617 qmetro 2;
#P newex 10 175 91 196617 jit.gl.render blend;
#P newex 30 444 35 196617 sel 27;
#P newex 30 423 40 196617 key;
#P comment 589 714 100 196617 foreground;
#P user panel 129 49 401 287;
#X brgb 191 191 191;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P user panel 541 235 128 128;
#X brgb 191 191 191;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P window linecount 4;
#P comment 671 242 100 196617 < << this triggers a frame grab from GL
when the camera sees something;
#P user panel 698 404 332 108;
#X brgb 191 191 191;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P window linecount 1;
#P comment 1031 405 114 196617 < < this grabs from GL;
#P user panel 564 404 128 101;
#X brgb 191 191 191;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 435 443 123 196617 This saves file to disk>>>;
#P window linecount 2;
#P comment 300 694 158 196617 < << blend happens here>>> (thanks to
Wesley Smith);
#P window linecount 1;
#P comment 612 537 400 196617 This loads the composite blend from the
GL back into the foreground videoplane>>>>;
#P connect 14 0 13 0;
#P connect 13 0 25 0;
#P connect 25 0 12 0;
#P connect 12 0 33 0;
#P connect 10 0 11 0;
#P connect 11 0 17 0;
#P connect 17 0 16 0;
#P connect 16 0 15 0;
#P connect 20 0 19 0;
#P fasten 19 0 18 0 38 642 38 642;
#P fasten 21 0 18 0 98 640 38 640;
#P connect 18 0 28 0;
#P connect 28 0 29 0;
#P fasten 26 0 24 0 135 735 38 735;
#P connect 29 0 24 0;
#P fasten 13 0 34 0 15 113 142 113;
#P fasten 35 0 34 0 142 113 142 113;
#P connect 34 0 40 0;
#P connect 40 0 36 0;
#P connect 36 0 42 0;
#P connect 42 0 45 0;
#P connect 45 0 41 0;
#P connect 41 0 27 0;
#P connect 43 0 42 1;
#P fasten 37 0 36 1 309 182 257 182;
#P connect 38 0 39 0;
#P fasten 40 0 37 0 142 158 309 158;
#P connect 39 0 37 0;
#P fasten 59 0 60 0 1003 566 470 566;
#P fasten 23 0 22 0 572 638 470 638;
#P connect 60 0 22 0;
#P fasten 19 0 22 0 38 640 470 640;
#P connect 22 0 32 0;
#P fasten 31 0 30 0 543 734 470 734;
#P connect 32 0 30 0;
#P fasten 45 0 46 0 142 264 555 264;
#P connect 46 1 47 0;
#P connect 53 1 57 0;
#P connect 57 0 55 0;
#P connect 55 0 56 0;
#P connect 47 1 48 0;
#P connect 48 0 54 0;
#P connect 54 0 57 1;
#P fasten 48 0 53 0 595 348 688 348;
#P fasten 53 2 49 0 716 419 710 419;
#P fasten 56 0 52 0 578 485 710 485;
#P connect 49 0 52 0;
#P connect 53 3 50 0;
#P fasten 51 0 50 0 753 430 730 430;
#P connect 52 1 58 0;
#P connect 58 0 59 0;
#P pop;

thank you thank you thank you


December 8, 2006 | 5:07 am

I figgured it out. The problem can be solved by adding @ortho 2 to
the jit.gl.render. I can post the solution if anyone is curious…
works great now.

bbw

On 12/7/06, bart woodstrup wrote:
> Hi List,
>
> Anybody know why my images are being resized when imported to jit.qt.movie?
>
> I adapted Wesley Smith’s uvuy blend patch (thanks Wesley) from a few
> weeks ago – using a camera input as the "blend." With jit.3m, I
> trigger a matrix to grab a frame from the image being rendered to the
> GPU. I then want that frame to be loaded into the
> jit.qt.movie/videoplane that is the foreground image of the "blend."
> It works, but each time a new image loads in it gets progressively
> bigger.
>
> I guess you’ll have to look at the patch for it to make sense. I
> tried to annotate it thouroughly.
>
> The images I was using are here:
>
> http://bartwoodstrup.com/mount.tif
> http://bartwoodstrup.com/mount_back.tif
>
> Max 462 Jitter 162 Mac ppc 1.87ghz 1gb ram 128 vram OSX Tiger
>
> I have to install this in a few days and this is the only thing
> holding me back – any help is very much appreciated! Maybe you’ll get
> an idea for what I am trying to do – there might be an easier way with
> jit.op? I’m open to suggestions.
>
>
> max v2;
> #N vpatcher 68 56 1326 890;
> #P window setfont "Sans Serif" 9.;
> #P window linecount 2;
> #P comment 311 71 204 196617 machine vision used to blend images – use
> spacebar to set difference calculation point;
> #P window linecount 1;
> #P newex 465 617 68 196617 prepend read;
> #P newex 998 535 51 196617 zl slice 1;
> #P newex 998 514 93 196617 route exportimage;
> #P newex 573 420 27 196617 int;
> #P newex 573 460 104 196617 prepend exportimage;
> #P newex 573 440 116 196617 sprintf scape_0%ld tiff;
> #N counter;
> #X flags 0 0;
> #P newobj 590 367 66 196617 counter;
> #P newex 683 376 53 196617 t b b b b;
> #P newex 705 492 303 196617 jit.matrix @usesrcdim 1 @srcdimstart 0 599
> @srcdimend 799 0;
> #P message 748 411 125 196617 reset , glreadpixels vessel;
> #P newex 725 434 154 196617 jit.gl.sketch blend @automatic 0;
> #P newex 705 455 161 196617 jit.matrix vessel 4 char 800 600;
> #P newex 590 318 47 196617 past 30.;
> #P newex 564 291 88 196617 unpack 0. 0. 0. 0.;
> #P newex 550 270 53 196617 jit.3m;
> #P newex 137 244 202 196617 jit.slide @slide_up 350 @slide_down 1000;
> #P comment 181 716 100 196617 background;
> #P number 230 205 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
> #P newex 137 223 103 196617 jit.op @op > @val 20;
> #P newex 137 268 129 196617 jit.matrix 2 char 320 240;
> #P newex 137 138 54 196617 jit.change;
> #P newex 304 139 65 196617 sel 32;
> #P newex 304 119 42 196617 key;
> #P newex 304 163 162 196617 jit.matrix @thru 0;
> #P newex 137 185 125 196617 jit.op @op absdiff;
> #P message 137 94 53 196617 open;
> #P newex 137 117 98 196617 jit.qt.grab 320 240;
> #P user jit.fpsgui 10 195 60 196617 0;
> #P newex 465 666 243 196617 jit.gl.texture blend @colormode uyvy @name mov2;
> #P newex 538 712 47 196617 r draw2;
> #P newex 465 738 249 196617 jit.gl.videoplane blend @blend_enable 1
> @automatic 0;
> #P newex 33 690 76 196617 append blender;
> #P newex 33 667 243 196617 jit.gl.texture blend @colormode uyvy @name mov1;
> #P newex 137 290 325 196617 jit.gl.texture blend @colormode lumalpha
> @apply blend @name blender;
> #P newex 130 714 47 196617 r draw1;
> #N vpatcher 174 130 421 368;
> #P window setfont "Sans Serif" 9.;
> #P window linecount 0;
> #P newex 49 124 30 196617 t b b;
> #P newex 69 146 54 196617 s render2;
> #P newex 49 168 54 196617 s render1;
> #P newex 135 124 30 196617 t b b;
> #P window linecount 1;
> #P newex 155 146 47 196617 s draw2;
> #P newex 135 168 47 196617 s draw1;
> #P newex 24 54 66 196617 t b b b erase;
> #P inlet 24 34 15 0;
> #P outlet 24 85 15 0;
> #P connect 1 0 2 0;
> #P fasten 2 1 0 0 47 79 29 79;
> #P fasten 2 3 0 0 83 79 29 79;
> #P connect 2 0 8 0;
> #P connect 8 0 6 0;
> #P connect 8 1 7 0;
> #P fasten 2 2 5 0 65 88 140 88;
> #P connect 5 0 3 0;
> #P connect 5 1 4 0;
> #P pop;
> #P newobj 10 120 41 196617 p draw;
> #P newex 33 739 249 196617 jit.gl.videoplane blend @blend_enable 1 @automatic 0;
> #P message 567 620 30 196617 read;
> #P newex 465 643 188 196617 jit.qt.movie 800 600 @colormode uyvy;
> #P message 93 618 30 196617 read;
> #P toggle 33 597 15 0;
> #P newex 33 617 57 196617 qmetro 20;
> #P newex 33 644 188 196617 jit.qt.movie 800 600 @colormode uyvy;
> #P toggle 30 464 15 0;
> #P message 30 484 68 196617 fullscreen $1;
> #P newex 30 502 84 196617 jit.window blend;
> #P toggle 10 29 42 0;
> #P newex 10 75 51 196617 qmetro 2;
> #P newex 10 175 91 196617 jit.gl.render blend;
> #P newex 30 444 35 196617 sel 27;
> #P newex 30 423 40 196617 key;
> #P comment 589 714 100 196617 foreground;
> #P user panel 129 49 401 287;
> #X brgb 191 191 191;
> #X frgb 0 0 0;
> #X border 1;
> #X rounded 0;
> #X shadow 0;
> #X done;
> #P user panel 541 235 128 128;
> #X brgb 191 191 191;
> #X frgb 0 0 0;
> #X border 1;
> #X rounded 0;
> #X shadow 0;
> #X done;
> #P window linecount 4;
> #P comment 671 242 100 196617 < << this triggers a frame grab from GL
> when the camera sees something;
> #P user panel 698 404 332 108;
> #X brgb 191 191 191;
> #X frgb 0 0 0;
> #X border 1;
> #X rounded 0;
> #X shadow 0;
> #X done;
> #P window linecount 1;
> #P comment 1031 405 114 196617 < < this grabs from GL;
> #P user panel 564 404 128 101;
> #X brgb 191 191 191;
> #X frgb 0 0 0;
> #X border 1;
> #X rounded 0;
> #X shadow 0;
> #X done;
> #P comment 435 443 123 196617 This saves file to disk>>>;
> #P window linecount 2;
> #P comment 300 694 158 196617 < << blend happens here>>> (thanks to
> Wesley Smith);
> #P window linecount 1;
> #P comment 612 537 400 196617 This loads the composite blend from the
> GL back into the foreground videoplane>>>>;
> #P connect 14 0 13 0;
> #P connect 13 0 25 0;
> #P connect 25 0 12 0;
> #P connect 12 0 33 0;
> #P connect 10 0 11 0;
> #P connect 11 0 17 0;
> #P connect 17 0 16 0;
> #P connect 16 0 15 0;
> #P connect 20 0 19 0;
> #P fasten 19 0 18 0 38 642 38 642;
> #P fasten 21 0 18 0 98 640 38 640;
> #P connect 18 0 28 0;
> #P connect 28 0 29 0;
> #P fasten 26 0 24 0 135 735 38 735;
> #P connect 29 0 24 0;
> #P fasten 13 0 34 0 15 113 142 113;
> #P fasten 35 0 34 0 142 113 142 113;
> #P connect 34 0 40 0;
> #P connect 40 0 36 0;
> #P connect 36 0 42 0;
> #P connect 42 0 45 0;
> #P connect 45 0 41 0;
> #P connect 41 0 27 0;
> #P connect 43 0 42 1;
> #P fasten 37 0 36 1 309 182 257 182;
> #P connect 38 0 39 0;
> #P fasten 40 0 37 0 142 158 309 158;
> #P connect 39 0 37 0;
> #P fasten 59 0 60 0 1003 566 470 566;
> #P fasten 23 0 22 0 572 638 470 638;
> #P connect 60 0 22 0;
> #P fasten 19 0 22 0 38 640 470 640;
> #P connect 22 0 32 0;
> #P fasten 31 0 30 0 543 734 470 734;
> #P connect 32 0 30 0;
> #P fasten 45 0 46 0 142 264 555 264;
> #P connect 46 1 47 0;
> #P connect 53 1 57 0;
> #P connect 57 0 55 0;
> #P connect 55 0 56 0;
> #P connect 47 1 48 0;
> #P connect 48 0 54 0;
> #P connect 54 0 57 1;
> #P fasten 48 0 53 0 595 348 688 348;
> #P fasten 53 2 49 0 716 419 710 419;
> #P fasten 56 0 52 0 578 485 710 485;
> #P connect 49 0 52 0;
> #P connect 53 3 50 0;
> #P fasten 51 0 50 0 753 430 730 430;
> #P connect 52 1 58 0;
> #P connect 58 0 59 0;
> #P pop;
>
>
> thank you thank you thank you
>


bartwoodstrup.com
vodstrup.com


December 8, 2006 | 5:15 am

If you’re using Jitter 1.6, there’s a new nify attribute that’s useful
for displaying videoplanes at full render window size. It’s
@transform_reset 2, which is very similar to @ortho 2.

wes

On 12/7/06, bart woodstrup wrote:
> I figgured it out. The problem can be solved by adding @ortho 2 to
> the jit.gl.render. I can post the solution if anyone is curious…
> works great now.
>
> bbw
>
>
>
>
>
>
> On 12/7/06, bart woodstrup
wrote:
> > Hi List,
> >
> > Anybody know why my images are being resized when imported to jit.qt.movie?
> >
> > I adapted Wesley Smith’s uvuy blend patch (thanks Wesley) from a few
> > weeks ago – using a camera input as the "blend." With jit.3m, I
> > trigger a matrix to grab a frame from the image being rendered to the
> > GPU. I then want that frame to be loaded into the
> > jit.qt.movie/videoplane that is the foreground image of the "blend."
> > It works, but each time a new image loads in it gets progressively
> > bigger.
> >
> > I guess you’ll have to look at the patch for it to make sense. I
> > tried to annotate it thouroughly.
> >
> > The images I was using are here:
> >
> > http://bartwoodstrup.com/mount.tif
> > http://bartwoodstrup.com/mount_back.tif
> >
> > Max 462 Jitter 162 Mac ppc 1.87ghz 1gb ram 128 vram OSX Tiger
> >
> > I have to install this in a few days and this is the only thing
> > holding me back – any help is very much appreciated! Maybe you’ll get
> > an idea for what I am trying to do – there might be an easier way with
> > jit.op? I’m open to suggestions.
> >
> >
> > max v2;
> > #N vpatcher 68 56 1326 890;
> > #P window setfont "Sans Serif" 9.;
> > #P window linecount 2;
> > #P comment 311 71 204 196617 machine vision used to blend images – use
> > spacebar to set difference calculation point;
> > #P window linecount 1;
> > #P newex 465 617 68 196617 prepend read;
> > #P newex 998 535 51 196617 zl slice 1;
> > #P newex 998 514 93 196617 route exportimage;
> > #P newex 573 420 27 196617 int;
> > #P newex 573 460 104 196617 prepend exportimage;
> > #P newex 573 440 116 196617 sprintf scape_0%ld tiff;
> > #N counter;
> > #X flags 0 0;
> > #P newobj 590 367 66 196617 counter;
> > #P newex 683 376 53 196617 t b b b b;
> > #P newex 705 492 303 196617 jit.matrix @usesrcdim 1 @srcdimstart 0 599
> > @srcdimend 799 0;
> > #P message 748 411 125 196617 reset , glreadpixels vessel;
> > #P newex 725 434 154 196617 jit.gl.sketch blend @automatic 0;
> > #P newex 705 455 161 196617 jit.matrix vessel 4 char 800 600;
> > #P newex 590 318 47 196617 past 30.;
> > #P newex 564 291 88 196617 unpack 0. 0. 0. 0.;
> > #P newex 550 270 53 196617 jit.3m;
> > #P newex 137 244 202 196617 jit.slide @slide_up 350 @slide_down 1000;
> > #P comment 181 716 100 196617 background;
> > #P number 230 205 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
> > #P newex 137 223 103 196617 jit.op @op > @val 20;
> > #P newex 137 268 129 196617 jit.matrix 2 char 320 240;
> > #P newex 137 138 54 196617 jit.change;
> > #P newex 304 139 65 196617 sel 32;
> > #P newex 304 119 42 196617 key;
> > #P newex 304 163 162 196617 jit.matrix @thru 0;
> > #P newex 137 185 125 196617 jit.op @op absdiff;
> > #P message 137 94 53 196617 open;
> > #P newex 137 117 98 196617 jit.qt.grab 320 240;
> > #P user jit.fpsgui 10 195 60 196617 0;
> > #P newex 465 666 243 196617 jit.gl.texture blend @colormode uyvy @name mov2;
> > #P newex 538 712 47 196617 r draw2;
> > #P newex 465 738 249 196617 jit.gl.videoplane blend @blend_enable 1
> > @automatic 0;
> > #P newex 33 690 76 196617 append blender;
> > #P newex 33 667 243 196617 jit.gl.texture blend @colormode uyvy @name mov1;
> > #P newex 137 290 325 196617 jit.gl.texture blend @colormode lumalpha
> > @apply blend @name blender;
> > #P newex 130 714 47 196617 r draw1;
> > #N vpatcher 174 130 421 368;
> > #P window setfont "Sans Serif" 9.;
> > #P window linecount 0;
> > #P newex 49 124 30 196617 t b b;
> > #P newex 69 146 54 196617 s render2;
> > #P newex 49 168 54 196617 s render1;
> > #P newex 135 124 30 196617 t b b;
> > #P window linecount 1;
> > #P newex 155 146 47 196617 s draw2;
> > #P newex 135 168 47 196617 s draw1;
> > #P newex 24 54 66 196617 t b b b erase;
> > #P inlet 24 34 15 0;
> > #P outlet 24 85 15 0;
> > #P connect 1 0 2 0;
> > #P fasten 2 1 0 0 47 79 29 79;
> > #P fasten 2 3 0 0 83 79 29 79;
> > #P connect 2 0 8 0;
> > #P connect 8 0 6 0;
> > #P connect 8 1 7 0;
> > #P fasten 2 2 5 0 65 88 140 88;
> > #P connect 5 0 3 0;
> > #P connect 5 1 4 0;
> > #P pop;
> > #P newobj 10 120 41 196617 p draw;
> > #P newex 33 739 249 196617 jit.gl.videoplane blend @blend_enable 1 @automatic 0;
> > #P message 567 620 30 196617 read;
> > #P newex 465 643 188 196617 jit.qt.movie 800 600 @colormode uyvy;
> > #P message 93 618 30 196617 read;
> > #P toggle 33 597 15 0;
> > #P newex 33 617 57 196617 qmetro 20;
> > #P newex 33 644 188 196617 jit.qt.movie 800 600 @colormode uyvy;
> > #P toggle 30 464 15 0;
> > #P message 30 484 68 196617 fullscreen $1;
> > #P newex 30 502 84 196617 jit.window blend;
> > #P toggle 10 29 42 0;
> > #P newex 10 75 51 196617 qmetro 2;
> > #P newex 10 175 91 196617 jit.gl.render blend;
> > #P newex 30 444 35 196617 sel 27;
> > #P newex 30 423 40 196617 key;
> > #P comment 589 714 100 196617 foreground;
> > #P user panel 129 49 401 287;
> > #X brgb 191 191 191;
> > #X frgb 0 0 0;
> > #X border 1;
> > #X rounded 0;
> > #X shadow 0;
> > #X done;
> > #P user panel 541 235 128 128;
> > #X brgb 191 191 191;
> > #X frgb 0 0 0;
> > #X border 1;
> > #X rounded 0;
> > #X shadow 0;
> > #X done;
> > #P window linecount 4;
> > #P comment 671 242 100 196617 < << this triggers a frame grab from GL
> > when the camera sees something;
> > #P user panel 698 404 332 108;
> > #X brgb 191 191 191;
> > #X frgb 0 0 0;
> > #X border 1;
> > #X rounded 0;
> > #X shadow 0;
> > #X done;
> > #P window linecount 1;
> > #P comment 1031 405 114 196617 < < this grabs from GL;
> > #P user panel 564 404 128 101;
> > #X brgb 191 191 191;
> > #X frgb 0 0 0;
> > #X border 1;
> > #X rounded 0;
> > #X shadow 0;
> > #X done;
> > #P comment 435 443 123 196617 This saves file to disk>>>;
> > #P window linecount 2;
> > #P comment 300 694 158 196617 < << blend happens here>>> (thanks to
> > Wesley Smith);
> > #P window linecount 1;
> > #P comment 612 537 400 196617 This loads the composite blend from the
> > GL back into the foreground videoplane>>>>;
> > #P connect 14 0 13 0;
> > #P connect 13 0 25 0;
> > #P connect 25 0 12 0;
> > #P connect 12 0 33 0;
> > #P connect 10 0 11 0;
> > #P connect 11 0 17 0;
> > #P connect 17 0 16 0;
> > #P connect 16 0 15 0;
> > #P connect 20 0 19 0;
> > #P fasten 19 0 18 0 38 642 38 642;
> > #P fasten 21 0 18 0 98 640 38 640;
> > #P connect 18 0 28 0;
> > #P connect 28 0 29 0;
> > #P fasten 26 0 24 0 135 735 38 735;
> > #P connect 29 0 24 0;
> > #P fasten 13 0 34 0 15 113 142 113;
> > #P fasten 35 0 34 0 142 113 142 113;
> > #P connect 34 0 40 0;
> > #P connect 40 0 36 0;
> > #P connect 36 0 42 0;
> > #P connect 42 0 45 0;
> > #P connect 45 0 41 0;
> > #P connect 41 0 27 0;
> > #P connect 43 0 42 1;
> > #P fasten 37 0 36 1 309 182 257 182;
> > #P connect 38 0 39 0;
> > #P fasten 40 0 37 0 142 158 309 158;
> > #P connect 39 0 37 0;
> > #P fasten 59 0 60 0 1003 566 470 566;
> > #P fasten 23 0 22 0 572 638 470 638;
> > #P connect 60 0 22 0;
> > #P fasten 19 0 22 0 38 640 470 640;
> > #P connect 22 0 32 0;
> > #P fasten 31 0 30 0 543 734 470 734;
> > #P connect 32 0 30 0;
> > #P fasten 45 0 46 0 142 264 555 264;
> > #P connect 46 1 47 0;
> > #P connect 53 1 57 0;
> > #P connect 57 0 55 0;
> > #P connect 55 0 56 0;
> > #P connect 47 1 48 0;
> > #P connect 48 0 54 0;
> > #P connect 54 0 57 1;
> > #P fasten 48 0 53 0 595 348 688 348;
> > #P fasten 53 2 49 0 716 419 710 419;
> > #P fasten 56 0 52 0 578 485 710 485;
> > #P connect 49 0 52 0;
> > #P connect 53 3 50 0;
> > #P fasten 51 0 50 0 753 430 730 430;
> > #P connect 52 1 58 0;
> > #P connect 58 0 59 0;
> > #P pop;
> >
> >
> > thank you thank you thank you
> >
>
>
> –
> bartwoodstrup.com
> vodstrup.com
>


December 8, 2006 | 5:28 am

Thanks Wes – I’ll give it a shot. And thanks also for that sweet uyvy
blend patch, I’m getting a lot of mileage out of it.

bbw

On 12/8/06, Wesley Smith wrote:
> If you’re using Jitter 1.6, there’s a new nify attribute that’s useful
> for displaying videoplanes at full render window size. It’s
> @transform_reset 2, which is very similar to @ortho 2.
>
> wes
>
> On 12/7/06, bart woodstrup wrote:
> > I figgured it out. The problem can be solved by adding @ortho 2 to
> > the jit.gl.render. I can post the solution if anyone is curious…
> > works great now.
> >
> > bbw
> >
> >
> >
> >
> >
> >
> > On 12/7/06, bart woodstrup
wrote:
> > > Hi List,
> > >
> > > Anybody know why my images are being resized when imported to jit.qt.movie?
> > >
> > > I adapted Wesley Smith’s uvuy blend patch (thanks Wesley) from a few
> > > weeks ago – using a camera input as the "blend." With jit.3m, I
> > > trigger a matrix to grab a frame from the image being rendered to the
> > > GPU. I then want that frame to be loaded into the
> > > jit.qt.movie/videoplane that is the foreground image of the "blend."
> > > It works, but each time a new image loads in it gets progressively
> > > bigger.
> > >
> > > I guess you’ll have to look at the patch for it to make sense. I
> > > tried to annotate it thouroughly.
> > >
> > > The images I was using are here:
> > >
> > > http://bartwoodstrup.com/mount.tif
> > > http://bartwoodstrup.com/mount_back.tif
> > >
> > > Max 462 Jitter 162 Mac ppc 1.87ghz 1gb ram 128 vram OSX Tiger
> > >
> > > I have to install this in a few days and this is the only thing
> > > holding me back – any help is very much appreciated! Maybe you’ll get
> > > an idea for what I am trying to do – there might be an easier way with
> > > jit.op? I’m open to suggestions.
> > >
> > >
> > > max v2;
> > > #N vpatcher 68 56 1326 890;
> > > #P window setfont "Sans Serif" 9.;
> > > #P window linecount 2;
> > > #P comment 311 71 204 196617 machine vision used to blend images – use
> > > spacebar to set difference calculation point;
> > > #P window linecount 1;
> > > #P newex 465 617 68 196617 prepend read;
> > > #P newex 998 535 51 196617 zl slice 1;
> > > #P newex 998 514 93 196617 route exportimage;
> > > #P newex 573 420 27 196617 int;
> > > #P newex 573 460 104 196617 prepend exportimage;
> > > #P newex 573 440 116 196617 sprintf scape_0%ld tiff;
> > > #N counter;
> > > #X flags 0 0;
> > > #P newobj 590 367 66 196617 counter;
> > > #P newex 683 376 53 196617 t b b b b;
> > > #P newex 705 492 303 196617 jit.matrix @usesrcdim 1 @srcdimstart 0 599
> > > @srcdimend 799 0;
> > > #P message 748 411 125 196617 reset , glreadpixels vessel;
> > > #P newex 725 434 154 196617 jit.gl.sketch blend @automatic 0;
> > > #P newex 705 455 161 196617 jit.matrix vessel 4 char 800 600;
> > > #P newex 590 318 47 196617 past 30.;
> > > #P newex 564 291 88 196617 unpack 0. 0. 0. 0.;
> > > #P newex 550 270 53 196617 jit.3m;
> > > #P newex 137 244 202 196617 jit.slide @slide_up 350 @slide_down 1000;
> > > #P comment 181 716 100 196617 background;
> > > #P number 230 205 35 9 0 0 0 3 0 0 0 221 221 221 222 222 222 0 0 0;
> > > #P newex 137 223 103 196617 jit.op @op > @val 20;
> > > #P newex 137 268 129 196617 jit.matrix 2 char 320 240;
> > > #P newex 137 138 54 196617 jit.change;
> > > #P newex 304 139 65 196617 sel 32;
> > > #P newex 304 119 42 196617 key;
> > > #P newex 304 163 162 196617 jit.matrix @thru 0;
> > > #P newex 137 185 125 196617 jit.op @op absdiff;
> > > #P message 137 94 53 196617 open;
> > > #P newex 137 117 98 196617 jit.qt.grab 320 240;
> > > #P user jit.fpsgui 10 195 60 196617 0;
> > > #P newex 465 666 243 196617 jit.gl.texture blend @colormode uyvy @name mov2;
> > > #P newex 538 712 47 196617 r draw2;
> > > #P newex 465 738 249 196617 jit.gl.videoplane blend @blend_enable 1
> > > @automatic 0;
> > > #P newex 33 690 76 196617 append blender;
> > > #P newex 33 667 243 196617 jit.gl.texture blend @colormode uyvy @name mov1;
> > > #P newex 137 290 325 196617 jit.gl.texture blend @colormode lumalpha
> > > @apply blend @name blender;
> > > #P newex 130 714 47 196617 r draw1;
> > > #N vpatcher 174 130 421 368;
> > > #P window setfont "Sans Serif" 9.;
> > > #P window linecount 0;
> > > #P newex 49 124 30 196617 t b b;
> > > #P newex 69 146 54 196617 s render2;
> > > #P newex 49 168 54 196617 s render1;
> > > #P newex 135 124 30 196617 t b b;
> > > #P window linecount 1;
> > > #P newex 155 146 47 196617 s draw2;
> > > #P newex 135 168 47 196617 s draw1;
> > > #P newex 24 54 66 196617 t b b b erase;
> > > #P inlet 24 34 15 0;
> > > #P outlet 24 85 15 0;
> > > #P connect 1 0 2 0;
> > > #P fasten 2 1 0 0 47 79 29 79;
> > > #P fasten 2 3 0 0 83 79 29 79;
> > > #P connect 2 0 8 0;
> > > #P connect 8 0 6 0;
> > > #P connect 8 1 7 0;
> > > #P fasten 2 2 5 0 65 88 140 88;
> > > #P connect 5 0 3 0;
> > > #P connect 5 1 4 0;
> > > #P pop;
> > > #P newobj 10 120 41 196617 p draw;
> > > #P newex 33 739 249 196617 jit.gl.videoplane blend @blend_enable 1 @automatic 0;
> > > #P message 567 620 30 196617 read;
> > > #P newex 465 643 188 196617 jit.qt.movie 800 600 @colormode uyvy;
> > > #P message 93 618 30 196617 read;
> > > #P toggle 33 597 15 0;
> > > #P newex 33 617 57 196617 qmetro 20;
> > > #P newex 33 644 188 196617 jit.qt.movie 800 600 @colormode uyvy;
> > > #P toggle 30 464 15 0;
> > > #P message 30 484 68 196617 fullscreen $1;
> > > #P newex 30 502 84 196617 jit.window blend;
> > > #P toggle 10 29 42 0;
> > > #P newex 10 75 51 196617 qmetro 2;
> > > #P newex 10 175 91 196617 jit.gl.render blend;
> > > #P newex 30 444 35 196617 sel 27;
> > > #P newex 30 423 40 196617 key;
> > > #P comment 589 714 100 196617 foreground;
> > > #P user panel 129 49 401 287;
> > > #X brgb 191 191 191;
> > > #X frgb 0 0 0;
> > > #X border 1;
> > > #X rounded 0;
> > > #X shadow 0;
> > > #X done;
> > > #P user panel 541 235 128 128;
> > > #X brgb 191 191 191;
> > > #X frgb 0 0 0;
> > > #X border 1;
> > > #X rounded 0;
> > > #X shadow 0;
> > > #X done;
> > > #P window linecount 4;
> > > #P comment 671 242 100 196617 < << this triggers a frame grab from GL
> > > when the camera sees something;
> > > #P user panel 698 404 332 108;
> > > #X brgb 191 191 191;
> > > #X frgb 0 0 0;
> > > #X border 1;
> > > #X rounded 0;
> > > #X shadow 0;
> > > #X done;
> > > #P window linecount 1;
> > > #P comment 1031 405 114 196617 < < this grabs from GL;
> > > #P user panel 564 404 128 101;
> > > #X brgb 191 191 191;
> > > #X frgb 0 0 0;
> > > #X border 1;
> > > #X rounded 0;
> > > #X shadow 0;
> > > #X done;
> > > #P comment 435 443 123 196617 This saves file to disk>>>;
> > > #P window linecount 2;
> > > #P comment 300 694 158 196617 < << blend happens here>>> (thanks to
> > > Wesley Smith);
> > > #P window linecount 1;
> > > #P comment 612 537 400 196617 This loads the composite blend from the
> > > GL back into the foreground videoplane>>>>;
> > > #P connect 14 0 13 0;
> > > #P connect 13 0 25 0;
> > > #P connect 25 0 12 0;
> > > #P connect 12 0 33 0;
> > > #P connect 10 0 11 0;
> > > #P connect 11 0 17 0;
> > > #P connect 17 0 16 0;
> > > #P connect 16 0 15 0;
> > > #P connect 20 0 19 0;
> > > #P fasten 19 0 18 0 38 642 38 642;
> > > #P fasten 21 0 18 0 98 640 38 640;
> > > #P connect 18 0 28 0;
> > > #P connect 28 0 29 0;
> > > #P fasten 26 0 24 0 135 735 38 735;
> > > #P connect 29 0 24 0;
> > > #P fasten 13 0 34 0 15 113 142 113;
> > > #P fasten 35 0 34 0 142 113 142 113;
> > > #P connect 34 0 40 0;
> > > #P connect 40 0 36 0;
> > > #P connect 36 0 42 0;
> > > #P connect 42 0 45 0;
> > > #P connect 45 0 41 0;
> > > #P connect 41 0 27 0;
> > > #P connect 43 0 42 1;
> > > #P fasten 37 0 36 1 309 182 257 182;
> > > #P connect 38 0 39 0;
> > > #P fasten 40 0 37 0 142 158 309 158;
> > > #P connect 39 0 37 0;
> > > #P fasten 59 0 60 0 1003 566 470 566;
> > > #P fasten 23 0 22 0 572 638 470 638;
> > > #P connect 60 0 22 0;
> > > #P fasten 19 0 22 0 38 640 470 640;
> > > #P connect 22 0 32 0;
> > > #P fasten 31 0 30 0 543 734 470 734;
> > > #P connect 32 0 30 0;
> > > #P fasten 45 0 46 0 142 264 555 264;
> > > #P connect 46 1 47 0;
> > > #P connect 53 1 57 0;
> > > #P connect 57 0 55 0;
> > > #P connect 55 0 56 0;
> > > #P connect 47 1 48 0;
> > > #P connect 48 0 54 0;
> > > #P connect 54 0 57 1;
> > > #P fasten 48 0 53 0 595 348 688 348;
> > > #P fasten 53 2 49 0 716 419 710 419;
> > > #P fasten 56 0 52 0 578 485 710 485;
> > > #P connect 49 0 52 0;
> > > #P connect 53 3 50 0;
> > > #P fasten 51 0 50 0 753 430 730 430;
> > > #P connect 52 1 58 0;
> > > #P connect 58 0 59 0;
> > > #P pop;
> > >
> > >
> > > thank you thank you thank you
> > >
> >
> >
> > –
> > bartwoodstrup.com
> > vodstrup.com
> >
>


bartwoodstrup.com
vodstrup.com


Viewing 4 posts - 1 through 4 (of 4 total)