Skip to content

%%py5draw magic has 2X scaling problem on OSX #711

@hx2A

Description

@hx2A

As reported by #710 (comment), the %%py5draw doesn't work correctly on OSX. The following code renders the coordinates correctly on Linux but not OSX:

%%py5draw 300 200

py5.fill("red")
py5.rect_mode(py5.CENTER)
py5.rect(170, 80, 100, 100)

py5.stroke("green")
py5.stroke_weight(15)
py5.line(40, 30, 220, 180)

I suspect this has something to do with https://py5coding.org/reference/sketch_display_density.html and https://py5coding.org/reference/sketch_pixel_density.html.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions