Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > ePub

Notices

Reply
 
Thread Tools Search this Thread
Old 08-06-2024, 07:03 AM   #1
galax
Enthusiast
galax began at the beginning.
 
Posts: 36
Karma: 10
Join Date: Sep 2023
Device: none
Post png or base64 for speed rendering?

Greets,

There are too many options for image formats.

Recently I thought about base64 format to use for my images. My idea is for the ereader to reduce its decoding to the max in order to save battery.

The appeal of base64 is two-fold, first it's can be compressed in text format, secondly somehow text seems to take less cpu cycles to process.

The images are monochrome, not even in grey scale, so the content is ideal for good compression algorithm/format.

Has anyone experimented with base64 images on epubs?

Thanks.
galax is offline   Reply With Quote
Old 08-06-2024, 07:18 AM   #2
estral
Just trying to survive
estral doesn't litterestral doesn't litterestral doesn't litter
 
Posts: 66
Karma: 210
Join Date: Mar 2009
Device: Nexus 7 2013, Galaxy Note 10.1 2014
I've used base64 for embedding images in epubs before, and it worked pretty well for me. Since your images are monochrome, you should get decent compression. Just keep in mind that while base64 can save on decoding time, it might increase the overall file size compared to standard image formats. It’s worth experimenting to see if the battery savings balance out with the file size trade-off.
estral is offline   Reply With Quote
Old 08-07-2024, 03:23 AM   #3
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 677
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
I optimise for filesize, which should also decode faster.

You can greatly reduce image file size for linework by reducing the number of colours,
To 2 colours if it's lines or rectangles, to 4 if there are diagonals or curves, as greys make less jagged lines than 2. Irfanview on Windows is very good to do this, can even do a batch on a folder of images.

Also I look at the image size. Sometime it's thousands of pixels, when reducing it to a few hundred shows little degradation on a ebook player.

Use PNG for this, or if you are going to use on Kindle, GIF, as PNGs are converted to JPEG or GIF on conversion with lower quality and larger size.

Sometimes can reduce the image size from JPEG by 95%, and get a better result.

Last edited by AlanHK; 08-07-2024 at 04:27 AM.
AlanHK is offline   Reply With Quote
Old 08-07-2024, 03:31 AM   #4
pdurrant
The Grand Mouse 高貴的老鼠
pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.pdurrant ought to be getting tired of karma fortunes by now.
 
pdurrant's Avatar
 
Posts: 72,500
Karma: 309060442
Join Date: Jul 2007
Location: Norfolk, England
Device: Kindle Voyage
Base64 isn't an image format. It's a data representation format. It seems unlikely that it'll require fewer cpu cycles to process, since whatever it represents needs to be reconstituted into binary before it can be interpreted. That's an extra step.
pdurrant is online now   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
txt.png not rendering ownedbycats Library Management 3 07-23-2022 05:46 AM
calibre_bookmarks encoding=json/base64 leopoldotosi Editor 1 08-18-2020 08:22 AM
Sony Reader for PC -- not rendering 16-color png GrannyGrump Workshop 27 10-16-2013 04:25 PM
Quality/speed of scanned PDF/DjVu rendering? mSSM PocketBook 2 08-21-2010 01:44 PM
where to get autorun.xml, icon.png, key.png, lut.bin for PRS-505 obender Sony Reader Dev Corner 2 01-25-2009 04:20 PM


All times are GMT -4. The time now is 05:20 AM.


MobileRead.com is a privately owned, operated and funded community.