-
Notifications
You must be signed in to change notification settings - Fork 25
Take a Screenshot
Arnaud Guyon edited this page Apr 18, 2017
·
1 revision
It is possible to take a "screenshot" (Bitmap) of the smartGLView. Just call takeScreenshot on the smartGLRenderer and get the result in a callback.
SmartGLRenderer renderer = smartGLView.getSmartGLRenderer();
renderer.takeScreenshot(new OpenGLRenderer.OnTakeScreenshot() {
@Override
public void screenshotTaken(Bitmap bitmap) {
// use the bitmap here, for example to put it in a ImageView
ImageView screenshotView = (ImageView) findViewById(R.id.screenshotView);
screenshotView.setImageBitmap(bitmap);
}
});