My frame rate is currently set at 30 frames per second and works awesomely when I don't use saveFrame(); but when I apply saveFrame(); , it only saves approximately 3 frames per second...which is not ideal. Is there any way to change this?
So I'm quite sure I went about writing this code in entirely the wrong way, but, my code creates one pixelated image and then shifts to another pixelated image as mouseX moves from 0 to width. After a lot of tedious work, I finished the program. It's super long and far from concise...but I'm happy with the way it moves and the way it looks.
(A snippet of the code is posted below - I can't post it all..it's too long (8000 lines...))
However, ideally, I'd like for the movement to correspond to sound, so I plugged it in to a program that I used in one of my classes (Posted at the end of the post). However, when I try to run it within that program, I get the error "method exceeds 65536 byte limit". (Likely because I wrote the code in such a tedious, clunky way...)
When I divided my code in half (reducing the number of lines that make the image to 60, the program works just fine)
How can I divide my initial program or modify it so that I can use sound as the effector and not worry about this limit?
Many, many thanks to anyone that can figure this one out..
I'm trying to create a series of rectangles that move from one xpos to another xpos as mouseX goes from 0 to width.
Each rectangle has a unique starting xpos and a unique final xpos so my initial attempt involved creating a separate float for each rectangle that mapped to mouseX: map(mouseX,0,width,initial,final). That works just fine, but as I get more and more complex and add more rectangles, it gets too complicated.
So for the next attempt I created a rectangle class (the rectangles are all the same size, they only move xpos) and then drew those to the screen. But I can't figure out how/where to incorporate the mapping of mouseX that I used in the initial attempt.
How can I feed data into a mapped function that can be reflected when I draw the class inside the display function?