Page 1 of 2

Logic Surround Pan?

Posted: 07 Jan 2013 07:44
by Pjotrizzima
Hello,

I've been struggling with Lemur's Logic Surround Pan module, as I've gotten some hard time trying to make the parameters and values meet in a correct way: So far everything's okay, but there's a 180° difference between my finger position and Logic's surround position.

Both the distance and the final angle seem to be working, but putting my finger onto (iPad) Lemur's upper right corner puts Logic's pan position into lower left corner. Moving my finger clockwise moves the Logic's position clockwise, too, but with a constant 180° difference.

I'm afraid this is a bit too much for my mathematics. :-D

Distance in Lemur is now connected to Logic's Surround Pan's Diversity parameter: 2*clamp(norm(x-0.5, y-0.5), 0, 0.5), and Lemur's final_angle is naturally connected to Logic's Angle: (a+(a<=0)*pi+(a>0)*2*(pi-a))/(2*pi) - - - Note: "a" being angle(x-0.5, y-0.5)

Since we've gone into RAD world instead of DEG with a=angle stuff, there's a difference worth of a PI somewhere, methinks. Easy peasy for some more cunning math linquist.

The easiest way to fix this would be to turn my iPad 180 degrees, but physically it becomes a bit difficult due to power plug and my desk space... and the problem escalates from there. I'm putting my faith on the community now - if people managed to get three astronauts back alive in Apollo 13 and they managed to send a tweeting robot to Mars, this should be a piece of a ca- sorry, PI.

Re: Logic Surround Pan?

Posted: 07 Jan 2013 09:44
by Macciza
Hi
I am guessing that you have stuff MIDI mapped somewhere

Simply invert one or the other - ie get Lemur to send 12-0 instead of 0-127
Or get Logic to respond to it that way . .

Hope that makes sense

MM

Re: Logic Surround Pan?

Posted: 07 Jan 2013 10:40
by Pjotrizzima
Unfortunately, there are no mappings anywhere, and inverting the parameter strings didn't do the trick.

Tried both Lemur end and in the assigned parameters (in Logic).

Re: Logic Surround Pan?

Posted: 11 Jun 2013 07:40
by Helios23
Working on a Logic Surround Panner as well.. would like to use ring area.


Are you using scripts with those values to set the value of angle and distance (amount)


if so could you give a module example?


i could help with the math but would need to see it in the actual module

Re: Logic Surround Pan?

Posted: 11 Jun 2013 09:02
by Helios23
Found the Template you were using, heres what you need:

a=angle(x-0.5, y-0.5) (These were reversed in the template.. FIXED)

Re: Logic Surround Pan?

Posted: 11 Jun 2013 09:05
by Helios23
ALSO THE SCALE of final_angle needs to be switched from 0-127 to 127-0

Re: Logic Surround Pan?

Posted: 05 Aug 2013 12:54
by Pjotrizzima
Helios23 wrote:ALSO THE SCALE of final_angle needs to be switched from 0-127 to 127-0
I think you managed to conquer something that has been kicking my ass a lot lately. I'll try this - and THANKS A LOT!

Re: Logic Surround Pan?

Posted: 06 Sep 2013 07:53
by Pjotrizzima
Unfortunately it seems that I had already tried what you suggested. Distance works fine, no problem with that, but Angle parameter is behaving erroneously. No matter what I do either in Logic's end or Lemur, it's either halfway there (the left side of the surround pan works ok) or way off (90° off and half of the spherical pan field isn't recognized at all).

Result: I downloaded Neyrinck's i-App and use it in V-window more. No hassle, just a bit slow - but it would be really good to be able to run my surround hell in Lemur.

Re: Logic Surround Pan?

Posted: 26 Jan 2017 04:03
by Helios23
Hoping to resurrect this thread in hopes someone has an updated answer for Logic X

After a bit of tooling arround ive got this code almost working with Lemur again i had it working perfect under under Logic 9 but now in logic X its only half working. For Negative Angles (Left side of panner) the numbers are working properly, but for Positive Angle (Right side of panner) values The panner position is 180 reversed

I'm using the following values:

a=angle(y-0.5, x-0.5)
scaled 0-127

final_angle=(a+(a<=0)*pi+(a>=0)*2*(pi-a))/(2*pi)
scaled 0-127

Diversity (Distance) is calculating properly
distance=2*clamp(norm(x-0.5, y-0.5), 0, 0.5)

Any help would be appreciated

Re: Logic Surround Pan?

Posted: 27 Jan 2017 09:53
by Helios23
Well, nothing like solving your own problems..

The missing keys are as follows


as pre the previous posts:
final_angle=(a+(a<=0)*pi+(a>=0)*2*(pi-a))/(2*pi)
scaled 127-0


After assigning the Surr. Angle for the Panner, the format of the Surr. Angle controller assignment must be switched to : Sign Magnitude, then suddenly it all works.