An OutOfMemoryError means that your code is either using up too much memory
because of a bug (e.g. creating an array that's too large, or unintentionally
loading thousands of images), or that your sketch may need more memory to run.
If your sketch uses a lot of memory (for instance if it loads a lot of data files)
you can increase the memory available to your sketch using the Preferences window.
Exception in thread "Animation Thread" java.lang.OutOfMemoryError
at sun.misc.Unsafe.allocateMemory(Native Method)
at java.nio.DirectByteBuffer.<init>(DirectByteBuffer.java:99)
at java.nio.ByteBuffer.allocateDirect(ByteBuffer.java:288)
at com.sun.opengl.util.BufferUtil.newByteBuffer(BufferUtil.java:65)
at com.sun.opengl.util.BufferUtil.copyIntBufferAsByteBuffer(BufferUtil.java:229)
at javax.media.opengl.glu.GLU.copyToByteBuffer(GLU.java:1450)
at javax.media.opengl.glu.GLU.gluBuild2DMipmapsJava(GLU.java:1524)
at javax.media.opengl.glu.GLU.gluBuild2DMipmaps(GLU.java:1581)
at processing.opengl.PGraphicsOpenGL$ImageCache.rebind(PGraphicsOpenGL.java:962)
at processing.opengl.PGraphicsOpenGL.bindTexture(PGraphicsOpenGL.java:770)
at processing.opengl.PGraphicsOpenGL.renderTriangles(PGraphicsOpenGL.java:693)
at processing.core.PGraphics3D.endShape(PGraphics3D.java:627)
at processing.core.PGraphics.endShape(PGraphics.java:1153)
at processing.core.PGraphics.imageImpl(PGraphics.java:2293)
at processing.core.PGraphics.image(PGraphics.java:2221)
at processing.core.PGraphics.image(PGraphics.java:2197)
at processing.core.PApplet.image(PApplet.java:7214)
at sketch_sep02b.draw(sketch_sep02b.java:244)
at processing.core.PApplet.handleDraw(PApplet.java:1426)
at processing.core.PApplet.run(PApplet.java:1328)
at java.lang.Thread.run(Thread.java:619)
java.lang.OutOfMemoryError
I made the program.
However, the error occurred and has been suffering.
If you've ever worked with experienced people like me to ask for advice
Program memory and 800MBto 200MB from the beginning to increase. And will be down.
Errors are due to depression. ㅠㅠ