1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
//! Object Attribute Memory (OAM) handling for sprite data.
//!
//! This module provides types and implementations for managing the NES PPU's
//! Object Attribute Memory (OAM), which stores up to 64 sprite entries.
//!
//! Two implementations are provided behind a feature flag:
//! * `OamArray`: a typed, in-memory array of Entry values.
//! * `OamArrayRaw`: a raw byte-backed representation that mirrors the
//! hardware layout (selected with the `oam_array_raw` feature).
pub use Entry;
pub use OamArray;
pub use OamArrayRaw as OamArray;
/// Number of sprite entries in OAM (hardware constant).
const OAM_ARRAY_ENTRIES_COUNT: usize = 64;
/// Iterator over all entries in an OAM array.
///
/// Produces a copy of each `Entry` in sequence from index 0..63.