Attach Letters to

Apr 4, 2013 at 6:14am

Attach Letters to

Hey, I’m working on an Installation right now where I want to show Letters for Note-Names on that are attached to a jit.phys.body.

What would be a good way to attach a Letter (or symbols in general) to overlay and follow the gridshape?

Thank you!

Apr 4, 2013 at 9:15am

You want a 3D letter or a texture?

Apr 4, 2013 at 4:22pm

For this project I just need 2D Textures.

But if you mind I would also be interested how you could achieve 3D letters.

Apr 4, 2013 at 5:08pm

Check Jitter tutorials 30 and 34…

Apr 4, 2013 at 5:48pm

Alright thanks alot! I’ll work through them and see if I have any questions left afterwards.

Apr 4, 2013 at 6:05pm

i would recommend gl.text3d for this (even if you want 2d text).

simply create one combination of phys.body and gl.text3d for each letter. you can change the letters dynamically using the “text” message.
you will probably want to create a “pool” of these objects using something like poly~ or javascript, in order to update the text and manage the objects.

the patch below shows the basic steps. i’ve included a jit.anim.node object inserted between the phys.body and gl.text3d, to allow offsetting of relative position using the @anchor attribute (otherwise the text won’t be centered inside the body vertically.

additionally, you want to disable @send_scale of the phys.body, so you can scale it independently of the attached objects.
you may also want to change the shape to cube, rather than the default of sphere.

– Pasted Max Patch, click to expand. –
Apr 5, 2013 at 1:21am

Hey Rob, thank you so much for the great reply!

I want to connect the via the jit.anim.node to my existing jit.phys.body.

This works well and the text follows the body perfectly, but as soon as I connect the to the body the looses it’s connection and vice versa?

Is it possible to connect multiple objects to follow the body?

Apr 5, 2013 at 6:10pm

phys.body and anim.node can only attach to a single gl object.
however, anim.node can have multiple child anim.nodes, so you can do something like the following.

– Pasted Max Patch, click to expand. –
Apr 5, 2013 at 9:01pm

thanks so much Rob! That worked more than perfectly!


You must be logged in to reply to this topic.