[PD] setX in [mass]

Cyrille Henry ch at chnry.net
Wed Jan 2 14:14:49 CET 2013


when you set a mass position, the link see the mass quick movement.
since D2 is quite high, and D2 is a damping that is opposed to the mass displacement, it will generate a force that send back the mass you displaced.

did the attachment is what you want to do?

c
c



Le 02/01/2013 13:43, Alexandros Drymonitis a écrit :
> What I actually wanna do is create a rectangle with coordinates (0, 0), which grows in width. For example, it starts with dimensions (1, 0.5) and grows to (1.5, 0.5). In order to make it look like it grows only towards one direction (to the right), I give it an offset on the x axis, so new coordinates are something like (0.15, 0). I then give random coordinates (x, y) with physical modeling, but what happens is that the rectangle goes first back to (0, 0) and then to (x, y), which looks a bit clumsy. I actually want it to start from the last coordinates (0.15, 0) and go straight to (x, y), without deviating through (0, 0).
> Hope this is clear enough, it's a bit difficult to isolate this specific part of the patch to attach it to this email. I tried your example, but still can't really make it work..
> FYI, I'm setting the following parameters to [link]: [setK 9, setD 0, setD2 500(
> and to [mass]: [setM 10000(
>
> Thanks anyway
>
>
> On Wed, Jan 2, 2013 at 1:59 PM, Cyrille Henry <ch at chnry.net <mailto:ch at chnry.net>> wrote:
>
>
>
>     Le 02/01/2013 12:34, Alexandros Drymonitis a écrit :
>
>         But if I reset them, aren't they going to set their positions to zero?
>
>     the initial position (so the reset position) is a parametter that you can set at masses creation : [mass foo 1 1] will be reset at position X
>
>
>
>     Also, only the second mass is moving, left inlet of [link] is attached to a fixed point, so how can I send force to the second [mass] via [link]?
>
>     send a force message to the mass inlet : you can have many things connected to a mass inlet...
>
>
>
>         Right inlet won't give any results. What do you mean exactly by 'mass parameter'? Is it for [mass] or [link]? Could you give an example?
>
>
>     i don"'t really know what you want to do, but here is an example.
>
>     cheers
>     c
>
>
>         Thanks
>
>
>
>         On Wed, Jan 2, 2013 at 1:16 PM, Cyrille Henry <ch at chnry.net <mailto:ch at chnry.net> <mailto:ch at chnry.net <mailto:ch at chnry.net>>> wrote:
>
>              hello,
>
>              after setting a mass position (in a not-physical way), you have to reset forces (in both link and masses).
>
>              If you want to set initial position, you better have to use the mass parameter.
>              otherwise, sending force is the "correct" way move masses.
>
>              cheers
>              Cyrille
>
>
>
>              Le 02/01/2013 11:48, Alexandros Drymonitis a écrit :
>
>                  I'm applying physical modeling to some visuals with pmpd's objects. I'm facing a problem with setting the position of [mass] sending it [setX $1(. [mass] will go to that position indeed, but as soon as I turn [metro] on it tends to go back to the previous position and then return to the position currently set. Even if I send the same position number to [link], it shows the same behavior. The patch is as follows (connections from [metro] and [setX $1( actually go to left inlets):
>
>                  [line 0 5]  [metro 5] [setX $1(
>                  |              /|              /
>                  |            /  |            /
>                  |          /    |          /
>                  |        /      |        /
>                  |      /        |      /
>                  [link]x[mass]
>
>                  Any ideas on how to overcome this?
>
>                  p.s. happy new year!
>
>
>                  ___________________________________________________
>         Pd-list at iem.at <mailto:Pd-list at iem.at> <mailto:Pd-list at iem.at <mailto:Pd-list at iem.at>> mailing list
>                  UNSUBSCRIBE and account-management -> http://lists.puredata.info/____listinfo/pd-list <http://lists.puredata.info/__listinfo/pd-list> <http://lists.puredata.info/__listinfo/pd-list <http://lists.puredata.info/listinfo/pd-list>>
>
>
>
>
>
>         _________________________________________________
>         Pd-list at iem.at <mailto:Pd-list at iem.at> mailing list
>         UNSUBSCRIBE and account-management -> http://lists.puredata.info/__listinfo/pd-list <http://lists.puredata.info/listinfo/pd-list>
>
>
>
>
> _______________________________________________
> Pd-list at iem.at mailing list
> UNSUBSCRIBE and account-management -> http://lists.puredata.info/listinfo/pd-list
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pm_rectangle_size.pd
Type: application/puredata
Size: 986 bytes
Desc: not available
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20130102/e1a7e5f0/attachment-0001.bin>


More information about the Pd-list mailing list