- Modifié
Viewbox / Clipping area / visible area
I am using the spine web player and want to have character walking on the stage from offsreen - this currently breaks the whole thing visually bc although (or thats why) I gave the Spineplayer a fixed viewport width and height, the animation gets scaled depending on where the character currently is. So if he is off screen it shows him "in screen" and everything is smaller.
It kind of makes sense, that the animation scales within the viewport, but I need it to show eg only the part where the background is and nothing else around it.
What can I do to get a kind of Camera with bounds within the rendering happens?
You just need to set the viewport yourself, rather than using the default viewport (which makes sure your animation is within the player):
Spine Web Player: Viewports
Thx, I thought I did that, but I did it the wrong way round:
I had the div width and height fixed and the viewport width as window.innerWIdth etc
now with fixed viewport values (the size of the background image), it works as intended and I can scale the div however I want as long as it is the same aspect ratio like the viewport
nice and thx again