Comment

Comment by _8rlb

I measured and split the latency between the main tasks of a single frame draw.

The main culprit was network delay as I am transmitting raw pixels (one u8 per pixel) compressed with zlib. That's a hit of ~140ms for half a screen.

Next in line is the screen refresh (unmeasured, perceived).

Then the optional post processing (~20ms for half a screen), and housekeeping, like keeping track of dirty regions (about as long).

Lastly writing to the framebuffer (less than 20ms, I don't remember exactly how long).

I took great care to optimise the process, and my next step was to transmit multiple pixels as a single u8 int, the physical display cannot render 255 distinct shades of gray.

parent _8rlb 4 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton