Combining cv.jit with spat5

Quentin Guo's icon

Hello, I'm more than a beginner on Max MSP and I require some helps on Libraries such as "Spat5".
Allow me to explain the context, I created a patcher in which there is a "color detector", using cv.jit I can get x,y coordinates.
Here's the problem, after converting(real time) x coordinates in a -180° to +180° integer, I can't modify the parameter inside the spatialization function "spat5.oper", there's not a lot of example about it so I'm kinda stuck for a while.
Right below is my patcher :

Spat5_jitcv.maxpat
text/plain 33.25 KB
My_program

nadir B.'s icon

Hi,

The source coordinates syntax accepted by spat5.oper : "/source/n/Az $1" (n = 1 considering your patch )
Send a "/status" message to spat5.oper to see a list of possible control/query syntax

Check spat5 tutorials ;-)

bye,

N.

Quentin Guo's icon

Hi Nadir, thanks for your help ^^
The status message helped me a lot and I used it on "spat5.oper".
The thing I discovered is that "/source/1/Az" doesn't exist and instead I tried to modify the "Azimuth" parameter through the "spat oper" interface.
Instead of it, I found that "Az" is replaced with "aed"(?).
Note : All I needed to do is modify its value and search in status

When I was about to be delighted, a new problem appeared : The object was not recognized :(

Rest in chocolate

nadir B.'s icon

spat5.oper accepts many formats, you just have to use message boxes instead of instantiating objects that do not exist ;-)

Quentin Guo's icon

Thanks a lot now it works.
Message boxes aside, a bangbang object is needed as well
I will post the actual solution to my problem right below
Sincerely grateful for the help you've given to me ^^

nadir B.'s icon

You are welcome.

Take care

N.

tcarpent's icon

In addition to that, have a look at "spat5.positions.maxhelp" for documentation about the syntax of position messages.

T.