Forums > Jitter

how to mirror the live video from the camera, help!

October 17, 2006 | 6:17 pm

As the question goes, I want to build a mirror-camera effect in Jitter, in which anything moves from right to left, will display as the opposite: left to right.

Could any one know "cv.jit" can do that? and how?

Thanks!


October 17, 2006 | 7:06 pm

just flip the matrix then

no need for cv.jit?

v a d e //

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


October 18, 2006 | 12:22 am


October 18, 2006 | 9:52 am

how to flip it?
What is the commend name?

HELP!


October 18, 2006 | 10:22 am

if you’re using the jit.dx.grab or jit.qt.grab objects (importing images
from a camera) u can send the message ‘settings’ to it, which opens the
configuration dialog for the camera in question. Most of those dialogs have
‘flip horz’ an ‘flip vert’ checkboxes.

On 10/18/06, luckyforest wrote:
>
>
> how to flip it?
> What is the commend name?
>
> HELP!
>


October 18, 2006 | 10:23 am

jit.dimmap, jit.matrix with srcdim/dstdim, …. many other ways.

wes

On 10/18/06, luckyforest wrote:
>
> how to flip it?
> What is the commend name?
>
> HELP!
>


October 18, 2006 | 4:23 pm

I think the command name is

‘do the tutorials’

v a d e //

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

On Oct 18, 2006, at 5:52 AM, luckyforest wrote:

>
> how to flip it?
> What is the commend name?
>
> HELP!


October 19, 2006 | 6:57 am

Thanks every one here, I have done it with "jit.rota"


October 19, 2006 | 7:02 am

On 10/18/06, luckyforest wrote:
>
> Thanks every one here, I have done it with "jit.rota"

Nooooooooooooooooooooooo! Unless you need arbitrary rotations, don’t
use rota. It’s expensive. Use jit.matrix src/dst dim or jit.dimmap
or jit.resamp or …

wes


October 19, 2006 | 7:11 am

speaking of expensive, is there a list , official or not, of optimum
methods for doing typical/useful things in jitter?

ie, is mxform2D or repos going to be faster than srcdim for this
particular function?

is there a coherent thought process behind choosing optimal methods,
or is it just trial and error with the objects?

v a d e //

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

On Oct 19, 2006, at 3:02 AM, Wesley Smith wrote:

> On 10/18/06, luckyforest wrote:
>>
>> Thanks every one here, I have done it with "jit.rota"
>
>
> Nooooooooooooooooooooooo! Unless you need arbitrary rotations, don’t
> use rota. It’s expensive. Use jit.matrix src/dst dim or jit.dimmap
> or jit.resamp or …
>
> wes


October 19, 2006 | 9:09 am

i guess the coherent thought process behind it is trying to guess how
the object actually works internally

flipping consists of moving pixels around without much calculation,
rotation is much more complicated than that doing calculations per
pixel, so jit.rota makes less sense in this case than jit.dimmap.

I suppose it helps if you have some programming experience other than
jitter so that you can make better guesses as to what’s under the
hood, and I’m certainly not claiming to really know what is best.

and I guess it’s always good not to start optimizing before speed has
actually started being an issue (what’s the guys name, Knuth ?).
Good thing about using jit.rota is that it might lead you to trying
other things.

ciao,

Joost.

On Oct 19, 2006, at 9:11 , vade wrote:

> speaking of expensive, is there a list , official or not, of
> optimum methods for doing typical/useful things in jitter?
>
> ie, is mxform2D or repos going to be faster than srcdim for this
> particular function?
>
> is there a coherent thought process behind choosing optimal
> methods, or is it just trial and error with the objects?
>
>
> v a d e //
>
> http://www.vade.info
> abstrakt.vade.info
>
>
> On Oct 19, 2006, at 3:02 AM, Wesley Smith wrote:
>
>> On 10/18/06, luckyforest wrote:
>>>
>>> Thanks every one here, I have done it with "jit.rota"
>>
>>
>> Nooooooooooooooooooooooo! Unless you need arbitrary rotations, don’t
>> use rota. It’s expensive. Use jit.matrix src/dst dim or jit.dimmap
>> or jit.resamp or …
>>
>> wes
>


October 19, 2006 | 4:50 pm

>speaking of expensive, is there a list , official or not, of optimum
>methods for doing typical/useful things in jitter?

Official? Naah.

But when you think of compositing, I encourage workshoppers
to consider the following, and to make the assumption that if
they only WANT one thing, to use the tool that best fits that
one need. Otherwise you’re wasting perfectly good Oils when
a Magic Marker will do.

max v2;
#N vpatcher 78 53 834 677;
#P window setfont "Sans Serif" 18.;
#P comment 441 247 31 196626 no;
#P user panel 424 230 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 599 248 31 196626 no;
#P user panel 582 231 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 283 247 42 196626 yes;
#P user panel 266 230 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 520 247 31 196626 no;
#P user panel 503 230 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 359 247 31 196626 no;
#P user panel 345 230 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P window linecount 2;
#P comment 113 235 152 196626 jit.scalebias/jit.brcosa/jit.hue;
#P window linecount 1;
#P comment 441 325 31 196626 no;
#P user panel 424 308 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 441 167 31 196626 no;
#P user panel 424 150 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P window setfont "Sans Serif" 14.;
#P comment 424 123 65 196622 rotation;
#P window setfont "Sans Serif" 18.;
#P comment 435 405 42 196626 yes;
#P user panel 424 387 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 435 484 42 196626 yes;
#P user panel 424 466 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 599 405 31 196626 no;
#P user panel 582 388 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 599 325 31 196626 no;
#P user panel 582 309 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 599 167 31 196626 no;
#P user panel 582 151 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P window setfont "Sans Serif" 14.;
#P window linecount 2;
#P comment 581 105 91 196622 hardware accelerated;
#P window setfont "Sans Serif" 18.;
#P window linecount 1;
#P comment 593 484 42 196626 yes;
#P user panel 582 467 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 283 405 31 196626 no;
#P user panel 266 387 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 520 405 31 196626 no;
#P user panel 503 387 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 283 325 42 196626 yes;
#P user panel 266 308 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 359 325 31 196626 no;
#P user panel 345 308 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 283 167 31 196626 no;
#P user panel 266 150 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 520 167 31 196626 no;
#P user panel 503 150 64 64;
#X brgb 129 59 255;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 359 167 42 196626 yes;
#P user panel 345 150 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P window setfont "Sans Serif" 14.;
#P comment 266 122 53 196622 tinting;
#P comment 503 123 68 196622 blending;
#P window linecount 2;
#P comment 345 105 72 196622 cropping/zooming;
#P window setfont "Sans Serif" 18.;
#P window linecount 1;
#P comment 209 56 490 196626 Here’s a quick summary of your
compositing choices:;
#P comment 113 484 146 196626 jit.gl.videoplane;
#P comment 69 405 193 196626 jit.rota/jit.mxform2d;
#P comment 27 325 233 196626 jit.lcd/jit.op/jit.alphablend;
#P comment 171 167 94 196626 jit.matrix;
#P comment 514 325 42 196626 yes;
#P user panel 503 308 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 359 405 42 196626 yes;
#P user panel 345 387 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 277 484 42 196626 yes;
#P user panel 266 466 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 514 484 42 196626 yes;
#P user panel 503 466 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P comment 359 484 42 196626 yes;
#P user panel 345 466 64 64;
#X brgb 250 255 75;
#X frgb 0 0 0;
#X border 1;
#X rounded 0;
#X shadow 0;
#X done;
#P pop;


October 19, 2006 | 5:01 pm

well, yes, but in this case, there is no obvious reason that repos,
or resamp, with a matrix normal map would be slower than a bunch of
pak srcdimstart/dim end messages, esp if you want to stay in matrix
land.

v a d e //

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



f
October 19, 2006 | 7:12 pm

couldn’t we start collecting max/jitter cpu test patches? i have a
bunch of benchmark examples that does the same thing repeatedly in a
few different ways. i bet there are a lot of these laying around.
it’d be interesting to see some and we could all learn useful tricks i
think. say we just mailed them here with a [cputest] in the subject?
(or maybe i just have a hook up on optimising my videopatches – not
being spoiled with new computers)
_f0

On 19.10.2006, at 09:11, vade wrote:

> speaking of expensive, is there a list , official or not, of optimum
> methods for doing typical/useful things in jitter?
>
> ie, is mxform2D or repos going to be faster than srcdim for this
> particular function?
>
> is there a coherent thought process behind choosing optimal methods,
> or is it just trial and error with the objects?

#|
fredrikolofsson.com klippav.org musicalfieldsforever.com
|#



Joe
July 14, 2013 | 4:26 am

Hey

I tried your method of jit.dimmap, but that doesn’t produce a mirror image. Isn’t used to rotate the matrix, not invert it?

All the best

J


November 3, 2013 | 4:30 pm

jit.dimmap @invert 1 0


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