This content has been marked as final. Show 3 replies
The problem is, this always results in a PNG file with dpi set to 96 (the Windows screen setting, in other words), although the actual pixel resolution stays the same as the original image. Is there any way of controlling the dpi of the output image in JavaFX so that we can ensure that it stays the same as the original image?
var bi: BufferedImage = Main.stage.scene.renderToImage(null) as BufferedImage; ImageIO.write(bi,”png”, f))