ExportImage with fixed width and variable DPI

the_math-hobbyist shared this question 5 months ago

Could I get a fixed width when the image is exported as .png file with the ExportImage command, controlling the DPI? (I want outputs with less kB).

ExportImage("type", "png", "filename", "geogebra.png", "width", pxWidth, "dpi", DPI)

If I fix the width and change the DPI, the filesize doesn't change. And if I remove the width parameter, the kB decreases, but the width too.

Comments (2)


DPI is just a flag in the PNG - it doesn't change the filesize

To get a smaller size you need to decrease the pixels


Thanks a lot, Michael.

I am a full newbie with this topic. I have been studying to understand it and to propose a solution.

© 2020 International GeoGebra Institute