private void loop() throws Exception {
		buffer = new FrameBuffer(800, 600, FrameBuffer.SAMPLINGMODE_HARDWARE_ONLY);
		buffer.disableRenderer(IRenderer.RENDERER_SOFTWARE);
		buffer.enableRenderer(IRenderer.RENDERER_OPENGL);

		long time = System.nanoTime() / 1000000L;
		int fps = 0;

		while (!org.lwjgl.opengl.Display.isCloseRequested()) {

			shader.setUniform("heightScale", scale);

			buffer.clear(java.awt.Color.BLACK);
			world.renderScene(buffer);
			world.draw(buffer);
			buffer.update();
			buffer.displayGLOnly();

			move();

			fps++;
			long now = System.nanoTime() / 1000000L;
			if (now - time >= 1000) {
				time = now;
				System.out.println(fps + " fps");
				fps = 0;
			}
		}
		buffer.disableRenderer(IRenderer.RENDERER_OPENGL);
		buffer.dispose();
		System.exit(0);
	}