Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
2 本の平行線を引くための点を計算するにはどうすればよいですか。
平行線の中心の始点と終点がわかります。物事を少し難しくするために、直線とベジエ曲線をサポートする必要があります。
質問は漠然としていますが、ここに可能性があります。それが役立つことを願っています。
セグメント (x1,y1)-(x2,y2) の場合、この方法で角度 a で表される方向に n ピクセル離れた別のセグメントを計算できます。
x1b = x1 + n cos a y1b = y1 - n sin a x2b = x2 + n cos a y2b = y2 - n sin a