<div dir="ltr">Didn't really notice what [curve]'s argument is for. Thanks guys, I guess that solves it.<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Dec 18, 2012 at 2:23 PM, Olivier Baudu <span dir="ltr"><<a href="mailto:olivier@labomedia.net" target="_blank">olivier@labomedia.net</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi...<br>
<br>
A [curve 2] will give you a perfect line.<br>
With [cos ] and [sin ] you could "easyly" convert the angle in x, y for the second point...<br>
<br>
But, I'm not sure that using a rectangle, in your case, is neither so difficult...<br>
Before the rotation, you just have to translate the rectangle of the half of the lenght it grows.<br>
It's not a "trick" and works very precisely.<br>
<br>
Cheers.<br>
<br>
01ivier<br>
<br>
Le 18.12.2012 12:46, Alexandros Drymonitis a écrit :<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div class="h5">
Hi all,<br>
I've been trying to render a line in Gem, so I'm wondering if it's<br>
best to use [curve] (which is actually a curve as it indicates), or<br>
[rectangle] with a very small x value, so that it looks like a line.<br>
My problem is that I want to give this line an angle, so I've been<br>
using [shearXY] for now. I also want to make the line grow from<br>
nothing to the full desired length, but with [rectangle] it will grow<br>
from the middle, so in order to make it grow from the starting point<br>
to the ending point, you have to give [rectangle] a continuous x,y<br>
offset.<br>
This way it's really hard to determine the starting and ending point<br>
of the line. So, If for example the x,y coordinates of the starting<br>
and ending point are random, then the angle and length will also be<br>
random and you'll have to manipulate three different objects<br>
simultaneously ([rectangle], [translate] and [shearXY]), and I'm not<br>
sure if I can find the formula for all these calculations.<br>
Is there an easier technique for this?<br>
<br></div></div><div class="im">
______________________________<u></u>_________________<br>
<a href="mailto:Pd-list@iem.at" target="_blank">Pd-list@iem.at</a> mailing list<br>
UNSUBSCRIBE and account-management -><br>
<a href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/<u></u>listinfo/pd-list</a><br>
</div></blockquote><span class="HOEnZb"><font color="#888888">
<br>
-- <br>
"On ne peut pas vivre dans un monde où l'on croit que l'élégance exquise du plumage de la pintade est inutile. Ceci est tout à fait à part. J'ai eu envie de le dire, je l'ai dit." Jean Giono, Un roi sans divertissement.</font></span><div class="HOEnZb">
<div class="h5"><br>
<br>
______________________________<u></u>_________________<br>
<a href="mailto:Pd-list@iem.at" target="_blank">Pd-list@iem.at</a> mailing list<br>
UNSUBSCRIBE and account-management -> <a href="http://lists.puredata.info/listinfo/pd-list" target="_blank">http://lists.puredata.info/<u></u>listinfo/pd-list</a><br>
</div></div></blockquote></div><br></div>