We are about to switch to a new forum software. Until then we have removed the registration on this forum.
Is there a way where I can pause my draw function so I can have new backgrounds also those backgrounds should be behind the buttons from ControlP5 library. Because I am creating a GUI that needs to show the rPi Camera but needs to have a clicked button first. Any help can be considered! Thanks and more powers.
Could you show what code do you have?
I will think using loop/noLoop will answer your question:
However, to change background you don't need to stop the draw() function. Instead you could do this::
Regarding your GUI using controlP5, you set them up in your setup function and then you do not have to worry for the background function drawing over them. ControlP5 objects are always redrawn over whichever background you have set so far in your draw function. If you are running into some other issues, you could provide more details or a small running code showing your problem.
Following up on @kfrajer 's suggestion, here is a recent thread on several different ways to toggle the draw looping status off and on.
You can't draw backgrounds "behind" anything -- only "before" things that come after (and therefor on top of).
Here's my code. I can say that the code in Camera() subroutine should be put on the draw for continuous Rpi Camera display. Hope you can help me. Also the Level function does not update very well due to my plan of changing background. Hope you understand my bad english