public void updateViewport(){
  setToOrtho(false,virtualViewport.getWidth(),virtualViewport.getHeight());
}

public void updateViewport ( ) { setToOrtho ( false , virtualViewport . getWidth ( ) , virtualViewport . getHeight ( ) ) ; }
this must be called in applicationlistener . resize ( ) in order to correctly update the camera viewport .
