[Solved] Reduce PNG file size while retaining pixel size

Discuss the drawing application
Post Reply
SpeedCameraReport
Posts: 7
Joined: Thu Apr 07, 2022 5:55 pm

[Solved] Reduce PNG file size while retaining pixel size

Post by SpeedCameraReport »

When saving a drawing as .png, what is the best way to obtain a smaller file size (from say 42Kb) while retaining the same pixel size (say 600x600)?

Obviously there may be some loss of resolution,
Thanks,
Dave.
Last edited by SpeedCameraReport on Fri Apr 15, 2022 5:47 pm, edited 1 time in total.
OpenOffice v4.1.11 on Windows
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: How to reduce file size while retaining pixel size (.png

Post by John_Ha »

If you want to keep the same pixel count the only way is to reduce the colours from 24 bit to 8 bit, or even 4 bit or 2 bit. See the tutorial on images or save the PNG as a GIF which reduces it to 8 bit colours.

Why do want to do it? A 42kB image is tiny.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
SpeedCameraReport
Posts: 7
Joined: Thu Apr 07, 2022 5:55 pm

Re: How to reduce file size while retaining pixel size (.png

Post by SpeedCameraReport »

Hi John Ha.
Reducing the colours seems worth trying, how do you "reduce the colours from 24 bit to 8 bit"? Can't seem to find the settings for that.
Thanks,
Dave.
OpenOffice v4.1.11 on Windows
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: How to reduce file size while retaining pixel size (.png

Post by John_Ha »

It's all in the Tutorial. See [Tutorial] Some useful hints on using images.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
SpeedCameraReport
Posts: 7
Joined: Thu Apr 07, 2022 5:55 pm

Re: How to reduce file size while retaining pixel size (.png

Post by SpeedCameraReport »

Yes, I have read through it but couldn't find how to reduce the colours.
I'll look again ...
OpenOffice v4.1.11 on Windows
John_Ha
Volunteer
Posts: 9584
Joined: Fri Sep 18, 2009 5:51 pm
Location: UK

Re: How to reduce file size while retaining pixel size (.png

Post by John_Ha »

7. Use 256 colour (8 bit) images instead of 16 million colour (24 bit) images if possible

In IrfanView go Image > Decrease colour depth.

If you have scanned an image of a page, the white background will be many different shades, all close to, but not exactly [255,255,255] or [128,128,128]. Use Replace colour and set a tolerance of 20 or more - this makes all the "almost white" exactly white. As the values are now all identical they will compress much more.
LO 6.4.4.2, Windows 10 Home 64 bit

See the Writer Guide, the Writer FAQ, the Writer Tutorials and Writer for students.

Remember: Always save your Writer files as .odt files. - see here for the many reasons why.
SpeedCameraReport
Posts: 7
Joined: Thu Apr 07, 2022 5:55 pm

Re: How to reduce file size while retaining pixel size (.png

Post by SpeedCameraReport »

I cannot find anywhere in Open office "Draw" to reduce colours and the tutorial recommends IrfanView as well.
Found that setting "Interlaced" off reduces file size. Doesn't seem to affect the image though.
Thanks.
OpenOffice v4.1.11 on Windows
User avatar
Zizi64
Volunteer
Posts: 11418
Joined: Wed May 26, 2010 7:55 am
Location: Budapest, Hungary

Re: How to reduce file size while retaining pixel size (.png

Post by Zizi64 »

Reducing the colours seems worth trying, how do you "reduce the colours from 24 bit to 8 bit"? Can't seem to find the settings for that.
It is NOT an Apache Openoffice feature. You must use a third party pixelgraphic editor or manager software for this task - before you embed the image into an OpenOffice document.
Tibor Kovacs, Hungary; LO7.5.8 /Win7-10 x64Prof.
PortableApps/winPenPack: LO3.3.0-7.6.2;AOO4.1.14
Please, edit the initial post in the topic: add the word [Solved] at the beginning of the subject line - if your problem has been solved.
SpeedCameraReport
Posts: 7
Joined: Thu Apr 07, 2022 5:55 pm

Re: How to reduce file size while retaining pixel size (.png

Post by SpeedCameraReport »

Thanks Zizi64, that'll explain why I couldn't find it ! ;-)
OpenOffice v4.1.11 on Windows
Post Reply