0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

P5.js 日本語リファレンス(strokeJoin)

Last updated at Posted at 2020-05-01

このページでは[「P5.js 日本語リファレンス」] (https://qiita.com/bit0101/items/91818244dc26c767a0fe) の strokeJoin関数を説明します。

strokeJoin()

説明文

LINE を接続するジョイントのスタイルを設定します。これらのジョイントは、留め継ぎ、面取り、丸めに対応するパラメータ MITER、BEVEL、ROUNDで指定します。デフォルトのジョイントは MITER です。

構文

strokeJoin(join)

パラメタ

  • join
    定数:MITER、BEVEL、ROUND のいずれか

例1

function draw() {
  noFill();
  strokeWeight(10.0);

  strokeJoin(MITER);
  
  beginShape();
  vertex(35, 20);
  vertex(65, 50);
  vertex(35, 80);
  endShape();
}

実行結果

strokeJoin-1.png

例2

noFill();
strokeWeight(10.0);
strokeJoin(BEVEL);
beginShape();
vertex(35, 20);
vertex(65, 50);
vertex(35, 80);
endShape();

実行結果

strokeJoin-2.png

例3

function draw() {
  noFill();
  strokeWeight(10.0);

  strokeJoin(ROUND);
  
  beginShape();
  vertex(35, 20);
  vertex(65, 50);
  vertex(35, 80);
  endShape();
}

実行結果

strokeJoin-3.png

著作権

p5.js was created by Lauren McCarthy and is developed by a community of collaborators, with support from the Processing Foundation and NYU ITP. Identity and graphic design by Jerel Johnson.

ライセンス

Creative Commons(CC BY-NC-SA 4.0) に従います。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?