everybody, I'm making an android game using java and libgdx. I'm also using Tiled to render my tiles on the screen. I hava the camera set up already, all I need is to figure out how to not render tiles that are not shown on the screen. Here is the code
testRenderer.setView(main.getOrthographicCamera());
testRenderer.render();
main.getOrthographicCamera().position.set(main.getPlayer().getX() + (Main.PLAYER_WIDTH / 2), main.getPlayer().getY() + (Main.PLAYER_HEIGHT / 2), 0);
main.getSpriteBatch().setProjectionMatrix(main.getOrthographicCamera().combined);
setBoundsToCamera();
main.getOrthographicCamera().update();