Forums > Jitter

movie window warping

April 12, 2007 | 12:02 pm

hi,

im trying to create a digital mirror for a university project using jitter.

i would like to recreate the fun mirrors that we have all seen at funfairs, by that i mean that i want to be able to bend the input, from camera using jit.dx.grab, at different rates to create a warping image.

i have looked at a few possiblities but have not yet found the correct solution.

i have been looking at various freeframe plugz but agin nothing suitable found.

does anyone have any suggestions on this?

do you know of any good freeframe or the like plugz that may do the trick?

has anyone else done anything like this?

thanks in advance


April 12, 2007 | 2:01 pm

Have you tried jit.repos? It seems pretty well-suited for that.


April 12, 2007 | 3:08 pm

i did just find some info on that. im not sure that it will give me the control i need, but i am hopeful.

thanks.

ps, have just downloaded a bunch of freeframe plugz too which i think will help.


April 12, 2007 | 10:03 pm

I put together this little patch to show how jit.repos can make a "wobble map" with a sine wave to do a simple funhouse mirror effect.

#P window setfont "Sans Serif" 9.;
#P window linecount 1;
#P newex 95 28 45 9109513 loadbang;
#P window setfont "Sans Serif" 14.;
#P comment 626 32 137 9109518 WOBBLE POSITION;
#P comment 627 73 116 9109518 WOBBLE WIDTH;
#P comment 622 110 116 9109518 WOBBLE DEPTH;
#P window setfont "Sans Serif" 9.;
#P flonum 583 73 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P flonum 581 115 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 409 93 27 9109513 + 0.;
#P newex 288 36 19 9109513 t b;
#P flonum 583 35 35 9 0 0 0 139 0 0 0 221 221 221 222 222 222 0 0 0;
#P newex 505 65 27 9109513 + 0.;
#P newex 507 136 27 9109513 * 0.;
#P newex 507 110 20 9109513 sin;
#P newex 507 85 33 9109513 * 0.01;
#P newex 317 126 106 9109513 pack setcell 0 0 val 0 0;
#P newex 331 65 40 9109513 uzi 240;
#P newex 328 34 40 9109513 uzi 320;
#P newex 256 178 142 9109513 jit.matrix posmat 2 long 320 240;
#P toggle 112 51 15 0;
#P newex 180 60 50 9109513 qmetro 50;
#P user jit.pwindow 416 322 295 222 0 0 0 0 1 0;
#P user jit.pwindow 55 260 297 325 0 1 0 0 1 0;
#P newex 74 128 91 9109513 jit.qt.movie 320 240;
#P message 139 100 26 9109513 read;
#P newex 75 97 50 9109513 qmetro 50;
#P newex 55 203 164 9109513 jit.repos @in2_dim 320 240 @mode 0;
#P window setfont "Sans Serif" 14.;
#P comment 501 294 100 9109518 WOBBLE MAP;
#P connect 20 0 18 0;
#P connect 20 0 15 1;
#P connect 14 0 15 0;
#P connect 15 0 19 1;
#P connect 8 0 2 0;
#P connect 8 0 7 0;
#P connect 2 0 4 0;
#P connect 7 0 9 0;
#P connect 25 0 8 0;
#P connect 9 0 1 1;
#P connect 9 0 6 0;
#P connect 21 0 18 0;
#P connect 21 0 13 1;
#P connect 19 0 12 5;
#P connect 11 2 12 2;
#P connect 11 2 19 0;
#P connect 11 2 16 0;
#P connect 17 0 18 0;
#P connect 17 0 16 1;
#P connect 13 0 14 0;
#P connect 16 0 13 0;
#P connect 10 2 12 1;
#P connect 10 2 12 4;
#P connect 10 0 11 0;
#P connect 18 0 10 0;
#P connect 11 0 12 0;
#P connect 12 0 9 0;
#P connect 3 0 4 0;
#P connect 1 0 5 0;
#P connect 4 0 1 0;
#P window clipboard copycount 26;


April 14, 2007 | 4:51 pm

Nevermind that patcher I put together, the examples that come with Jitter have a much more elegant version of what I did, along with a lot of other ways of warping an image/video with jit.repos (just look in the Jitter examples folder instead of the tutorials). I’d be surprised if they don’t have almost exactly what you’re trying to do.



Dan
April 14, 2007 | 5:02 pm

If you’re on Mac OS 10.4, there are several distortion Image Units you
can use to get a funhouse mirror efect. Check out the help patch for
jit.gl.imageunit. :)

best,
dan


April 15, 2007 | 11:23 am

thanks for that.

i knew i saw a similar project somewhere – i have only been looking at the help files and tutorials – doh!

i spent the whole of yesterday sorting out some patches to allow me to change all the parameters on the freeframe plugz that i downloaded – i now have some really cool effects.

i just need to get my wobbly mirror working.

i looked at repos and resamp but didnt think that i could get the type of effects that i needed, ie, i could only get them to wobble a little where im after some relly extreme fxs.

i will give your patch a go and look at the exmples, and will let you know ho i got on tomorrow,

many thanks to you all,

steve


April 17, 2007 | 8:20 pm

Hi again,

the autorota 3rd party patch does offer some good results but it is still not quite what im looking for.

I want the image size to remain constant always with different amounts of compression/stretching at various points across the image.

eg, if i want to stretch the middle, pull it back, there would be different amounts of compression from the edge of the stretch region to the middle, with the middle being the most compressed and the outter the least.

The project has been hit really hard over the weekend and i now have nearly everything i want except the warping effect im after.

If anyone can help i would be very appreciative.


April 17, 2007 | 8:34 pm

did you also look at texture mapping to jit.gl.nurbs?
this is a great way to get plane warping

-deK

> Hi again,
>
> the autorota 3rd party patch does offer some good results but it is
> still not quite what im looking for.
>
> I want the image size to remain constant always with different
> amounts of compression/stretching at various points across the image.
>
> eg, if i want to stretch the middle, pull it back, there would be
> different amounts of compression from the edge of the stretch
> region to the middle, with the middle being the most compressed and
> the outter the least.
>
> The project has been hit really hard over the weekend and i now
> have nearly everything i want except the warping effect im after.
>
> If anyone can help i would be very appreciative.


April 17, 2007 | 8:39 pm

jit.repos @mode 1 (relative) and create a distortion map ?

On Apr 17, 2007, at 4:20 PM, steve kittner wrote:

>
> Hi again,
>
> the autorota 3rd party patch does offer some good results but it is
> still not quite what im looking for.
>
> I want the image size to remain constant always with different
> amounts of compression/stretching at various points across the image.
>
> eg, if i want to stretch the middle, pull it back, there would be
> different amounts of compression from the edge of the stretch
> region to the middle, with the middle being the most compressed and
> the outter the least.
>
> The project has been hit really hard over the weekend and i now
> have nearly everything i want except the warping effect im after.
>
> If anyone can help i would be very appreciative.

v a d e //

http://www.vade.info
abstrakt.vade.info


April 22, 2007 | 5:28 pm

cheers vade, it worked a treat.

i used the jit.expr to set a distortion map and then used the jit.rota object to move the warp around the screen.

Both of these objects were sent into the jit.repos object with the setting on 1,

and hey presto!

i have my warping mirror.

cheers all

especially Vade !!!!!


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