[英]How to get image corner position after rotate in OpenSeadragon
Hi I have a problem with getting the x and y coordinates for the corner after rotation.嗨,我在旋转后获取角的 x 和 y 坐标时遇到问题。 When I transfer the image, it always gets the correct coordinates, but as soon as the image is rotated, it receives the coordinates from the corner of the viewport, not the image:/
当我传输图像时,它总是得到正确的坐标,但是一旦图像旋转,它就会从视口的角落接收坐标,而不是图像:/
Is this with the viewport rotated or the image rotated?这是旋转的视口还是旋转的图像? If it's the image rotated, I believe this should work:
如果是旋转的图像,我相信这应该可行:
viewer.world.getItemAt(0).getBounds().getTopLeft()
Actually, that might work properly with the viewport rotated as well.实际上,这可能也适用于旋转的视口。 The result is in viewport coordinates... I assume that's what you want?
结果在视口坐标中......我假设这就是你想要的? If not, you can convert to the other coordinate systems as needed.
如果没有,您可以根据需要转换为其他坐标系。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.