Checkpoint: Glyphs rendering how I'd like

This commit is contained in:
Nathan Sobo 2023-10-03 17:29:36 -06:00
parent 550d9a9f71
commit c57e19c8fa
6 changed files with 8 additions and 14 deletions

View file

@ -147,10 +147,10 @@ impl Atlas {
bounds.size().y() as u64,
);
self.texture.replace_region(
dbg!(region),
region,
0,
bytes.as_ptr() as *const _,
dbg!((bounds.size().x() * self.bytes_per_pixel() as i32) as u64),
(bounds.size().x() * self.bytes_per_pixel() as i32) as u64,
);
}

View file

@ -633,7 +633,6 @@ impl Renderer {
// Snap sprite to pixel grid.
let origin = (glyph.origin * scale_factor).floor() + sprite.offset.to_f32();
dbg!(origin);
sprites_by_atlas
.entry(sprite.atlas_id)
.or_insert_with(Vec::new)