Quantcast
Channel: Question and Answer » libgdx
Viewing all articles
Browse latest Browse all 434

How to run a method after a scene2d being rendered in libGDX

$
0
0

I want to make a screenshot with

ScreenUtils.getFrameBufferPixmap(x, y, w, h);

I call this function in Actions.run(new Runnable{…}) in scene2d.ui, and the problem is that actions are called at very beginning of a new frame, so nothing is rendered yet.

How to call this method properly, e.g.

Scene.inTheEnd(run(ScreenUtils.getFrameBufferPixmap(x, y, w, h);));

?


Viewing all articles
Browse latest Browse all 434

Trending Articles