Hi Carlos,
Ok, I found the patch, I only tested in on OSX, but it should work fine on linux/windoze, maybe with a little tweaking here and there.
Anyhow I'm CCing the list again so everyone else who wants can get the URL from the thread.
www.goto10.org/~bbogart/gemwin-interaction.tgz
You can see I'm doing some strange things here with the scale, since the scale of the object changes, I need to know its changed bounds in terms of gemunits. This is why I had been asking for simple collision detection in Gem, so that you could just ask if the rectangle intersects with a single point on the XY plane, and not have to manually calculate the bounds based on the scale change...
I have not looked at that patch in years.
.b.
Carlos Caires wrote:
-----Original Message----- From: B. Bogart [mailto:ben@ekran.org] Sent: Thu 2/23/2006 9:52 PM To: Carlos Caires Cc: IOhannes m zmoelnig; pd-list@iem.at Subject: Re: RE : [PD] Gemmouse inlet?
Hi Carlos,
If I get what your doing you want to be able to use the gemhouse to drag around multiple squares on the screen right?
- Yes, this is exactly what I need.
I have done this, if you REALLY want it I can try and find the patch..
- Oh, ...I´ll really apreciated it.....Thanks.
Carlos Caires
basically each square is in its own abstraction, and the abstraction knows how bit the square is in gem units. [square 1] is 1 unit from the center to the edges, so its actually 2 units wide. Then you convert the gemmouse coords into gem coords (depends on the aspect ratio of the window), then pack the scaled version and send it to all the abstractions. inside each square you have moses or >= objects to check if the mouse is indeed in the square, then that controls a spigot so when the mouse is over the square the square will move with the mouse. Oh of course you should use that value and the mouse-press together with [&&] otherwise you'll collect all the squares as you pass over them...
Its simpler than it sounds...
.b.
Carlos Caires wrote:
Hi, Is there a way to use several GEMMOUSE objects on the same GemWin?
(For instance, I' d like to move separetly more than one [square] object, using the mouse).
Thanks, Carlos Caires
De: IOhannes m zmoelnig [mailto:zmoelnig@iem.at] Date: ven. 17/02/2006 20:04 À: Carlos Caires Cc: pd-list@iem.at Objet : Re: [PD] Gemmouse inlet?
som e imagem wrote:
Hello list,
What´s for the inlet of Gemmouse object?
for historical reasons :-)
the Gem-framework makes it a bit complicated to create objects without inlets.
mfg.ad.r IOhannes
Thanks.
Carlos Caires
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
Thanks, I´ll try it... C.
On 06/02/27 16:36, "B. Bogart" ben@ekran.org wrote:
Hi Carlos,
Ok, I found the patch, I only tested in on OSX, but it should work fine on linux/windoze, maybe with a little tweaking here and there.
Anyhow I'm CCing the list again so everyone else who wants can get the URL from the thread.
www.goto10.org/~bbogart/gemwin-interaction.tgz
You can see I'm doing some strange things here with the scale, since the scale of the object changes, I need to know its changed bounds in terms of gemunits. This is why I had been asking for simple collision detection in Gem, so that you could just ask if the rectangle intersects with a single point on the XY plane, and not have to manually calculate the bounds based on the scale change...
I have not looked at that patch in years.
.b.
Carlos Caires wrote:
-----Original Message----- From: B. Bogart [mailto:ben@ekran.org] Sent: Thu 2/23/2006 9:52 PM To: Carlos Caires Cc: IOhannes m zmoelnig; pd-list@iem.at Subject: Re: RE : [PD] Gemmouse inlet?
Hi Carlos,
If I get what your doing you want to be able to use the gemhouse to drag around multiple squares on the screen right?
- Yes, this is exactly what I need.
I have done this, if you REALLY want it I can try and find the patch..
- Oh, ...I´ll really apreciated it.....Thanks.
Carlos Caires
basically each square is in its own abstraction, and the abstraction knows how bit the square is in gem units. [square 1] is 1 unit from the center to the edges, so its actually 2 units wide. Then you convert the gemmouse coords into gem coords (depends on the aspect ratio of the window), then pack the scaled version and send it to all the abstractions. inside each square you have moses or >= objects to check if the mouse is indeed in the square, then that controls a spigot so when the mouse is over the square the square will move with the mouse. Oh of course you should use that value and the mouse-press together with [&&] otherwise you'll collect all the squares as you pass over them...
Its simpler than it sounds...
.b.
Carlos Caires wrote:
Hi, Is there a way to use several GEMMOUSE objects on the same GemWin?
(For instance, I' d like to move separetly more than one [square] object, using the mouse).
Thanks, Carlos Caires
De: IOhannes m zmoelnig [mailto:zmoelnig@iem.at] Date: ven. 17/02/2006 20:04 À: Carlos Caires Cc: pd-list@iem.at Objet : Re: [PD] Gemmouse inlet?
som e imagem wrote:
Hello list,
What´s for the inlet of Gemmouse object?
for historical reasons :-)
the Gem-framework makes it a bit complicated to create objects without inlets.
mfg.ad.r IOhannes
Thanks.
Carlos Caires
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
PD-list@iem.at mailing list UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list