-
-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
createGraphics() undefined #1237
Comments
As I remember, createGraphics() should work in other p5 methods such as draw() and mousePressed() as well. The problem you have might be you are trying to access p5 methods before p5 is initialized (in setup() usually). You can try ensuring the p5 object is initialized either with instance mode or by making sure setup is called before making other calls to createGraphics() in other objects etc. You can look at #903 about this. And this. Let me know if that's not the case. |
Hmm, it sounds like we should add |
great. it sounds like the issue here is now covered in #1247, so i'm going to close this one. |
createGraphics() will be undefined unless used in setup() making it unusable in objects and other things
The text was updated successfully, but these errors were encountered: