mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-15 08:30:02 +00:00
fix some rendering artifacts and add todo's on the QR code rendering
This commit is contained in:
parent
ac20b43aaa
commit
f7c00eb985
1 changed files with 3 additions and 1 deletions
|
|
@ -441,9 +441,11 @@ pub fn render_qr<T: FrameBuffer>(
|
|||
op::rectangle(display, r, screen_clip.into(), false);
|
||||
|
||||
// now raster in the modules
|
||||
// TODO: on dense codes, the dark colors are over-sized by a pixel. Figure this out.
|
||||
// TODO: on smaller than optimal codes, align the QR code into the center of the screen.
|
||||
let mut line_top_left =
|
||||
Point::new(left_edge + module_width * QUIET_MODULES, tl.y + module_width * QUIET_MODULES);
|
||||
let dark = DrawStyle::new(PixelColor::Dark, PixelColor::Dark, 1);
|
||||
let dark = DrawStyle::new(PixelColor::Dark, PixelColor::Dark, 0);
|
||||
for line in qr_render.modules.chunks(qr_render.width) {
|
||||
for (i, &module) in line.iter().enumerate() {
|
||||
if module {
|
||||
|
|
|
|||
Loading…
Reference in a new issue