为什么要在ZXing中实现rotateCounterClockwise()?

发布于 2025-01-05 15:52:27 字数 122 浏览 1 评论 0原文

我正在创建 LuminanceSource 的子类。我是否有理由期望或必须实现rotateCounterClockwise()

对性能或可靠性(或两者)的影响?

I am creating a subclass to LuminanceSource. Is there a reason why I should expect to or have to implement rotateCounterClockwise()?

Implications to performance or reliability (or both)?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

无远思近则忧 2025-01-12 15:52:27

如果您不想实现它,您始终可以使用 isRotateSupported() 并让该方法抛出异常。

提供它是因为接口不知道您的内部结构是什么样的,所以否则旋转涉及将您的数据转换为通用格式,执行转换,然后将通用格式数据转换回您的格式。

You can always have isRotateSupported() and make that method throw an exception if you don't want to implement it.

It is provided because the interface does not know what your internal structure is like, so otherwise a rotation involves converting your data to a common format, performing the transform, then converting the common format data back into your format.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文