monsoon-default-renderers
Default screen renderer implementations for the Monsoon NES emulator.
This crate provides LookupPaletteRenderer, a fast O(1) lookup table-based renderer that converts the NES PPU's 9-bit palette indices into RGB colors. It is the default renderer used by both the frontend and CLI applications. It is part of the Monsoon Emulator project.
Usage
Add monsoon-default-renderers alongside monsoon-core:
[]
= { = "0.1.0" }
= { = "0.1.0" }
use ScreenRenderer;
use LookupPaletteRenderer;
let mut renderer = new;
// pixel_buffer is a &[u16] from Nes::get_pixel_buffer()
# let pixel_buffer: & = &;
let rgb_pixels = renderer.buffer_to_image;
// rgb_pixels is a &[RgbColor] — each with .r, .g, .b fields (u8)
License
This project is licensed under the Apache-2.0 License.