diff options
| author | Hannes Schulze <haschu0103@outlook.de> | 2025-02-04 19:59:47 +0100 |
|---|---|---|
| committer | Hannes Schulze <haschu0103@outlook.de> | 2025-02-04 19:59:47 +0100 |
| commit | 9c45e9c7df1efa5bc1c8e73b6eaef4726b828d3e (patch) | |
| tree | 4be985efa8e697fd6ef5838eec69c32c40c5d4a5 /lib/nes/sys/ppu.cc | |
| parent | e791ac9a46095e0241181da89c35a7c702982c21 (diff) | |
add span type
Diffstat (limited to 'lib/nes/sys/ppu.cc')
| -rw-r--r-- | lib/nes/sys/ppu.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/nes/sys/ppu.cc b/lib/nes/sys/ppu.cc index c9e6f11..2419030 100644 --- a/lib/nes/sys/ppu.cc +++ b/lib/nes/sys/ppu.cc @@ -239,7 +239,7 @@ namespace nes::sys sprite_count_ = 0; for (auto i = u32{ 0 }; i < sprite_max_count; ++i) { - auto const s = sprite{ &oam_[i * 4] }; + auto const s = sprite{ span{ oam_ }.subspan<4>(i * 4) }; auto const row = static_cast<int>(scanline_) - static_cast<int>(s.get_y()); if (row < 0 || static_cast<u32>(row) >= height) { continue; } |
