open class ScreenGrab
open class ScreenGrab
Grabs the pixels from the buffer and saves it to a file on the SD card. Usage example (saves every frame to a separate .png file):
public void onDrawFrame(GL10 glUnused) {
super.onDrawFrame(glUnused);
Screengrab.saveAsImage(0, 0, mDefaultViewportWidth, mDefaultViewportHeight, "/frame_" + mFrameCount + ".png", CompressFormat.PNG);
}
Author
dennis.ippel