Hi Guys, Thanks for the responses, i can adjust the scale of the model, i do it at loadtime. using the following
spine2DComponent.json.setScale(0.08f);
when i resize the screen the screen, it looks to be working correctly at a particular resolution but when i manually adjust the size of the window it doesnt work correctly...so imn guessing i have a problem with the camera..also when i zoom in and out the spine model doesnt change size as you would expect it to do. The level and any sprites i have showing seem to scale correctly.
i got spine model moving at a particular resolution moving correctly by using camera.project
position = ModelManager.camera.project(new Vector3(bodyComp.body.getPosition().x,bodyComp.body.getPosition().y,0));
pBatch.begin();
spineComp.skeleton.setX((position.x));
spineComp.skeleton.setY((position.y));
skeletonMeshRenderer.draw(pBatch,spineComp.skeleton);
spineComp.animationState.apply(spineComp.skeleton);
spineComp.skeleton.updateWorldTransform();
pBatch.end();
i thought moving the camera would not scale all objects on screen at the same rate?
Maybe i dont understand the camera and extended viewport as well as i think. i will re-look at my code again to see if i havent made any silly mistakes there... i will relook at how the resize method works and how i have set up the camera and viewport...maybe i forgot to delete some of old testing code by accident.
edit - ok i just figured out it works correctly with whatever resolution i set in the config.width and config.height in the desktop launcher...but when i adjust the zoom on the camera it still doesnt zoom the spine model at all.