Skip to content

[p5.js 2.0+ Bug Report]: point(x,y) fails for x >= 256 #9380

Closed

Description

@goldwasser

Most appropriate sub-area of p5.js?

  • Accessibility
  • Color
  • Core/Environment/Rendering
  • Data
  • DOM
  • Events
  • Image
  • IO
  • Math
  • Typography
  • Utilities
  • WebGL
  • WebGPU
  • p5.strands
  • Build process
  • Unit testing
  • Internationalization
  • Friendly errors
  • Other (specify if possible)

p5.js version

2.3.4

Web browser and version

Bug for both Safari 27.0 and Chrome 157.0.8103.39. Interestingly, but is not occurring for Firefox 159.0.1 on same system.

Operating system

MacOSX Tahoe 26.7.1

Steps to reproduce this

Issue:

The point command is failing to render properly when x >= 256. This bug does not seem to exist in p5.js 2.3.0 but seems to exist in 2.3.1 through 2.3.4.

Steps:

  1. Run the following code

Snippet:

function setup() {
  createCanvas(400, 100);
  strokeWeight(4);   // not necessary to reproduce; just helps visibility
  point(255,50);     // x=255 renders properly
  point(256,75);     // x=256 (or bigger) does not render
}

Activity

  1. ksen0 commented on Nov 8, 2026

    @ksen0
    Member

    Thank you for reporting! This appears to be fixed with the upcoming release https://cdn.jsdelivr.net/npm/p5@2.4.0-rc.6/lib/p5.js (https://editor.p5js.org/ksen0/sketches/t1uXcjkIs) so I will close this one! But great catch, thank you, and if you find any other edge cases of this bug please report!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions