LibGDX is still actually Java, just use standard methods to get the time. At the beginning of using the application, use
startTime = System.currentTimeMillis();
then in the render you can do
System.out.println("Time elapsed in seconds = " + ((System.currentTimeMillis() - startTime) / 1000));
Make sure startTime is declared as long.
As for why it doesn't work with the method you posted, I'm not sure.
EDIT: If your LibGDX project is not configured to operate at a fixed speed, changing the frame rate will result in a change in Gdx.graphics.getDeltaTime (), because the delta time is returned for the last frame updated,
source
share