Kernel: Respect actual framebuffer pitch

Instead of winging it with "width * 4", use the actual pitch since it
may be different.

This makes the kernel text console show up in native 1368x768 on my
ThinkPad X250. :^)
This commit is contained in:
Andreas Kling 2022-03-01 17:15:47 +01:00
parent e65ff4b8d1
commit 884ebc42b1
Notes: sideshowbarker 2024-07-17 18:05:41 +09:00
2 changed files with 11 additions and 10 deletions

View file

@ -45,6 +45,7 @@ protected:
{
}
virtual u8* framebuffer_data() = 0;
size_t framebuffer_pitch() const { return m_pitch; }
virtual void clear_glyph(size_t x, size_t y);
size_t m_pitch;
};