Skip to content

Uniforms are not set on the first frame when using filter(shader) #6430

@aferriss

Description

@aferriss

Most appropriate sub-area of p5.js?

  • Accessibility
  • Color
  • Core/Environment/Rendering
  • Data
  • DOM
  • Events
  • Image
  • IO
  • Math
  • Typography
  • Utilities
  • WebGL
  • Build Process
  • Unit Testing
  • Internalization
  • Friendly Errors
  • Other (specify if possible)

p5.js version

Main

Web browser and version

Chrome 117.0.5938.88

Operating System

Mac OSX 13.5.2

Steps to reproduce this

Uniforms are not being set before the shader is run when using shaders with the filter() function. I've attached an example here showing the issue.

Steps:

  1. Create a shader
  2. try to set a uniform on the first frame
  3. observe uniform isn't set until 2nd frame and beyond.

Snippet:

https://editor.p5js.org/aferriss/sketches/KZVVxiTC9

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    DONE! 🎉

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions