You could use TiledMapPacker as suggested by the Maps section in the libGDX introduction. But if that only happens when you move the camera, the reason behind may also be a rounding problem of the coordinates. All coordinates once converted to screen coordinates should give integers.
try gdx-texturepacker with Duplicate Padding
and than load to Tiled Map Editor
the problem did not disappear
Could there be a reason, i use:
B4X:
Dim Batch As lgSpriteBatch
. . and . .
Dim Renderer As lgMapOrthogonalTiledMapRenderer
in LG_RENDER()
Batch.Begin
... render background
Batch.End
Renderer.Begin
.... render layers
Renderer.End
Batch.Begin
... render more
Batch.End
Dim Batch As lgSpriteBatch
. . and . .
Dim Renderer As lgMapOrthogonalTiledMapRenderer
in LG_RENDER()
Batch.Begin
... render background
Batch.End
Renderer.Begin
.... render layers
Renderer.End
Batch.Begin
... render more
Batch.End
about TiledMapPacker
is it work now ?
in extensions no gdx-tiled-preprocessor
i use script:
java -cp gdx.jar; gdx-natives.jar; gdx-backend-lwjgl.jar; gdx-backend-lwjgl-natives.jar; extensions \ gdx-tools \ gdx-tools. jar; extensions \ gdx-tiled-preprocessor \ gdx-tiled-preprocessor.jar com.badlogic.gdx.tiledmappacker.TiledMapPacker
A common case is a Spritebatch for Box2D objects (with a metric coordinate system) and a Spritebatch for background and HUD, so your current use is perfectly OK from my point of view.
For performance, it's better to avoid abusing of Spritebatch instances but 2 is not a problem at all.
about TiledMapPacker
is it work now ?
in extensions no gdx-tiled-preprocessor
i use script:
java -cp gdx.jar; gdx-natives.jar; gdx-backend-lwjgl.jar; gdx-backend-lwjgl-natives.jar; extensions \ gdx-tools \ gdx-tools. jar; extensions \ gdx-tiled-preprocessor \ gdx-tiled-preprocessor.jar com.badlogic.gdx.tiledmappacker.TiledMapPacker