Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何裁剪 BufferedImage 的多边形部分并将其写入另一个 BufferedImage?
Graphics2D 有 clip(Shape) 和 draw(Shape) 方法。所以我猜你可以将 Shape 设置为你的多边形,然后从一个 BufferedImage 绘制到另一个。