How to get position of module relative to parent ?

If you require help or assistance with anything then please post here

Moderators: electrogear, exonerate

How to get position of module relative to parent ?

Postby mrlucmorin on Mon Jun 15, 2009 6:36 pm

Hi,

Is it possible to determine the position of a component within its Parent module ?

For example, if I manually move a Knob within a module's front panel (by removing the padlock), how can I obtain the x,y coordinates of its position within the module's front panel ?

Thank you.
Luc Morin, T.P.
http://www.stlm.ca
User avatar
mrlucmorin
essemer
 
Posts: 27
Joined: Thu Jun 11, 2009 9:27 pm

Re: How to get position of module relative to parent ?

Postby oddson on Tue Jun 16, 2009 1:11 am

The same View Area primitive that was the answer in your last question is what you need here too.

If you attach a View Area primitive to the V input in the child module, then an Area to Float module will allow you to extract the x and y offsets.

I'm not at my SythMaker machine so I can't verify or produce an example. It may be a little trickier if the child module uses a "G" panel instead of an MGUI...
oddson
wiki guru
 
Posts: 3883
Joined: Sun Jul 03, 2005 6:44 pm

Re: How to get position of module relative to parent ?

Postby mrlucmorin on Tue Jun 16, 2009 2:36 am

Actually, I had tried the View Area primitive, but the offset is always (0,0).

In my child module, I place one such View Area directly at the wireless input, and another one at the MGUI output, like this:

ViewArea.png
ViewArea.png (65.75 KiB) Viewed 648 times


No matter how I resize/position the child module inside the parent, the x, y position coordinates are always (0,0).

I'm sure I'm missing something simple :blush:

Thanks
Luc Morin, T.P.
http://www.stlm.ca
User avatar
mrlucmorin
essemer
 
Posts: 27
Joined: Thu Jun 11, 2009 9:27 pm

Re: How to get position of module relative to parent ?

Postby oddson on Tue Jun 16, 2009 3:03 am

:blush: That's what I meant... I could have sworn that works.

Now I'm thinking I remember someone requesting the ability to read the placement of MGUI elements.
oddson
wiki guru
 
Posts: 3883
Joined: Sun Jul 03, 2005 6:44 pm

Re: How to get position of module relative to parent ?

Postby oddson on Tue Jun 16, 2009 3:50 am

oddson wrote:Now I'm thinking I remember someone requesting the ability to read the placement of MGUI elements.

:blush:

er... it was me!
viewtopic.php?f=12&t=4241

Hey Luc! were both in Canada... let's go for coffee.

We can meet in Winnipeg (half way at 1900 km). ;)
oddson
wiki guru
 
Posts: 3883
Joined: Sun Jul 03, 2005 6:44 pm

Re: How to get position of module relative to parent ?

Postby mrlucmorin on Tue Jun 16, 2009 11:13 am

oddson wrote:er... it was me!
viewtopic.php?f=12&t=4241


Hahaha that's funny... old age creeping in ;)

Hey Luc! were both in Canada... let's go for coffee.

We can meet in Winnipeg (half way at 1900 km). ;)


uhuh, only if you pay for the plane tickets ;)


About the position thing, I found a way to work around it, but still it would be nice. I'll repost to the Ideas and Requests forum.

Thanks
Luc Morin, T.P.
http://www.stlm.ca
User avatar
mrlucmorin
essemer
 
Posts: 27
Joined: Thu Jun 11, 2009 9:27 pm

Re: How to get position of module relative to parent ?

Postby oddson on Tue Jun 16, 2009 7:32 pm

The only way to work around it is to use explict positioning instead of G panel dragging... it would be nice to have the missing feature.
oddson
wiki guru
 
Posts: 3883
Joined: Sun Jul 03, 2005 6:44 pm

Re: How to get position of module relative to parent ?

Postby mrlucmorin on Tue Jun 16, 2009 8:28 pm

Yeah, and not having explicit positioning was the whole idea 3:)

So oddson, ever been to Quebec ? The farthest west that I've gone is Calgary. That country is too big, we should break it up ;)
Luc Morin, T.P.
http://www.stlm.ca
User avatar
mrlucmorin
essemer
 
Posts: 27
Joined: Thu Jun 11, 2009 9:27 pm

Re: How to get position of module relative to parent ?

Postby oddson on Tue Jun 16, 2009 10:13 pm

mrlucmorin wrote:...So oddson, ever been to Quebec ? The farthest west that I've gone is Calgary. [this] country is too big, we should break it up ;)
You guys keep trying but who'd pay for your social programs without transfer payments. ;)
oddson
wiki guru
 
Posts: 3883
Joined: Sun Jul 03, 2005 6:44 pm

Re: How to get position of module relative to parent ?

Postby McBarGig on Sun Jul 26, 2009 8:49 pm

HaHa LOL...

I've Been from Quebec att the way to Van Oddson...Both great provinces..
McBarGig
essemilian
 
Posts: 379
Joined: Sat Feb 14, 2009 5:00 am


Return to Help

Who is online

Users browsing this forum: Google [Bot] and 0 guests