p5.js-web-editor icon indicating copy to clipboard operation
p5.js-web-editor copied to clipboard

Arc doesn't work with clip function on the editor

Open andrade-g opened this issue 1 month ago • 0 comments

p5.js version

2.1.1

What is your operating system?

Windows

Web browser and version

Edge 143.0.3650.75

Actual Behavior

When I add an arc to the clip function it doesn't show anything drawn afterwards. It works normally with circle for example. Seems to work fine on version 1.11.11

Expected Behavior

show the drawn vectors inside the arc defined in the beginClip(); endClip(); or using the mask function.

Steps to reproduce

function setup() { createCanvas(100, 100);

background(200);

// Create a mask. beginClip(); arc(width/2, height/2, 50, 50,PI-radians(30),PI+radians(30)) endClip();

// Draw a backing shape. rect(0,0,width, height)

describe('A white triangle and circle on a gray background.'); }

andrade-g avatar Dec 15 '25 14:12 andrade-g