def setup
background(220)
rect(30, 20, 55, 55)
end
def setup
background(220)
rect(30, 20, 55, 55, 20)
end
def setup
background(220)
rect(30, 20, 55, 55, 20, 15, 10, 5)
end
矩形を描画します。
| 引数名 | 内容 | 備考 | オプション | デフォルト値 |
|---|---|---|---|---|
| x | 基点の x座標 | rectModeの設定に依存 | ||
| y | 基点の y座標 | rectModeの設定に依存 | ||
| w | 幅 | rectModeの設定に依存 | ||
| h | 高さ | rectModeの設定に依存 | ○ | wと同値 |
| tl | 左上隅の角の丸み | ○ | 0 | |
| tr | 右上隅の角の丸み | ○ | tlと同値 | |
| br | 右下隅の角の丸み | ○ | trと同値 | |
| bl | 左下隅の角の丸み | ○ | brと同値 | |
| detailX | x方向のセグメント数 | WEBGLモードのキャンバスでのみ有効 | ○ | |
| detailY | x方向のセグメント数 | WEBGLモードのキャンバスでのみ有効 | ○ |
なし