Changed the swapbuffer to swapBuffer.