yaze 0.2.0
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
yaze::app::emu::video::Ppu Class Reference

#include <ppu.h>

Inheritance diagram for yaze::app::emu::video::Ppu:
Collaboration diagram for yaze::app::emu::video::Ppu:

Public Member Functions

 Ppu (memory::Memory &memory, Clock &clock)
 
void Init ()
 
void Reset ()
 
void Update ()
 
void UpdateClock (double delta_time)
 
void HandleFrameStart ()
 
void RunLine (int line)
 
void HandlePixel (int x, int y)
 
void LatchHV ()
 
int GetPixel (int x, int y, bool sub, int *r, int *g, int *b)
 
void EvaluateSprites (int line)
 
void CalculateMode7Starts (int y)
 
bool GetWindowState (int layer, int x)
 
bool CheckOverscan ()
 
void HandleVblank ()
 
void HandleOPT (int layer, int *lx, int *ly)
 
uint16_t GetOffsetValue (int col, int row)
 
int GetPixelForBgLayer (int x, int y, int layer, bool priority)
 
uint8_t Read (uint8_t adr, bool latch)
 
void Write (uint8_t adr, uint8_t val)
 
uint16_t GetVramRemap ()
 
void PutPixels (uint8_t *pixel_data)
 
const std::vector< uint8_t > & GetFrameBuffer () const
 
- Public Member Functions inherited from yaze::app::SharedRom
 SharedRom ()=default
 
virtual ~SharedRom ()=default
 
std::shared_ptr< Romshared_rom ()
 
auto rom ()
 

Public Attributes

bool frame_overscan_ = false
 
bool overscan_ = false
 
bool forced_blank_
 
uint8_t brightness
 
uint8_t mode
 
bool bg3priority
 
bool even_frame
 
bool pseudo_hires_
 
bool interlace
 
bool frame_interlace
 
bool direct_color_
 

Private Member Functions

int GetPixelForMode7 (int x, int layer, bool priority)
 

Private Attributes

const int cyclesPerScanline = 341
 
const int totalScanlines = 262
 
const int visibleScanlines = 224
 
bool enable_forced_blanking_ = false
 
int cycle_count_ = 0
 
int current_scanline_ = 0
 
uint16_t vram [0x8000]
 
uint16_t vram_pointer
 
bool vram_increment_on_high_
 
uint16_t vram_increment_
 
uint8_t vram_remap_mode_
 
uint16_t vram_read_buffer_
 
uint16_t cgram [0x100]
 
uint8_t cgram_pointer_
 
bool cgram_second_write_
 
uint8_t cgram_buffer_
 
uint16_t oam [0x100]
 
uint8_t high_oam_ [0x20]
 
uint8_t oam_adr_
 
uint8_t oam_adr_written_
 
bool oam_in_high_
 
bool oam_in_high_written_
 
bool oam_second_write_
 
uint8_t oam_buffer_
 
bool time_over_ = false
 
bool range_over_ = false
 
bool obj_interlace_
 
bool obj_priority_
 
uint16_t obj_tile_adr1_
 
uint16_t obj_tile_adr2_
 
uint8_t obj_size_
 
std::array< uint8_t, 256 > obj_pixel_buffer_
 
std::array< uint8_t, 256 > obj_priority_buffer_
 
uint8_t clip_mode_ = 0
 
uint8_t prevent_math_mode_ = 0
 
bool math_enabled_array_ [6] = {false, false, false, false, false, false}
 
bool add_subscreen_ = false
 
bool subtract_color_
 
bool half_color_
 
uint8_t fixed_color_r_
 
uint8_t fixed_color_g_
 
uint8_t fixed_color_b_
 
Layer layer_ [5]
 
int16_t m7matrix [8]
 
uint8_t m7prev
 
bool m7largeField
 
bool m7charFill
 
bool m7xFlip
 
bool m7yFlip
 
bool m7extBg
 
int32_t m7startX
 
int32_t m7startY
 
WindowLayer windowLayer [6]
 
uint8_t window1left
 
uint8_t window1right
 
uint8_t window2left
 
uint8_t window2right
 
std::array< BackgroundLayer, 4 > bg_layers_
 
uint8_t mosaic_startline_ = 1
 
BgLayer bg_layer_ [4]
 
uint8_t scroll_prev_
 
uint8_t scroll_prev2_
 
uint8_t mosaic_size_
 
uint8_t pixelBuffer [512 *4 *239 *2]
 
uint8_t pixelOutputFormat = 0
 
uint16_t h_count_
 
uint16_t v_count_
 
bool h_count_second_
 
bool v_count_second_
 
bool counters_latched_
 
uint8_t ppu1_open_bus_
 
uint8_t ppu2_open_bus_
 
uint16_t tile_data_size_
 
uint16_t vram_base_address_
 
uint16_t tilemap_base_address_
 
uint16_t screen_brightness_ = 0x00
 
Memorymemory_
 
Clockclock_
 
Tilemap tilemap_
 
BackgroundMode bg_mode_
 
std::vector< SpriteAttributessprites_
 
std::vector< uint8_t > tile_data_
 
std::vector< uint8_t > frame_buffer_
 
OAMSize oam_size_
 
OAMAddress oam_address_
 
Mosaic mosaic_
 
std::array< BGSC, 4 > bgsc_
 
std::array< BGNBA, 4 > bgnba_
 
std::array< BGHOFS, 4 > bghofs_
 
std::array< BGVOFS, 4 > bgvofs_
 

Additional Inherited Members

- Static Public Attributes inherited from yaze::app::SharedRom
static std::shared_ptr< Romshared_rom_ = nullptr
 

Detailed Description

Definition at line 259 of file ppu.h.

Constructor & Destructor Documentation

◆ Ppu()

yaze::app::emu::video::Ppu::Ppu ( memory::Memory & memory,
Clock & clock )
inline

Definition at line 262 of file ppu.h.

Member Function Documentation

◆ Init()

void yaze::app::emu::video::Ppu::Init ( )
inline

Definition at line 265 of file ppu.h.

References frame_buffer_, and pixelOutputFormat.

Referenced by yaze::app::emu::SNES::Init().

◆ Reset()

void yaze::app::emu::video::Ppu::Reset ( )

Definition at line 45 of file ppu.cc.

References add_subscreen_, bg3priority, bg_layer_, yaze::app::emu::video::BgLayer::bigTiles, brightness, cgram, cgram_buffer_, cgram_pointer_, cgram_second_write_, clip_mode_, counters_latched_, direct_color_, even_frame, fixed_color_b_, fixed_color_g_, fixed_color_r_, forced_blank_, frame_interlace, frame_overscan_, h_count_, h_count_second_, half_color_, high_oam_, yaze::app::emu::video::BgLayer::hScroll, interlace, layer_, m7charFill, m7extBg, m7largeField, m7matrix, m7prev, m7startX, m7startY, m7xFlip, m7yFlip, yaze::app::emu::video::Layer::mainScreenEnabled, yaze::app::emu::video::Layer::mainScreenWindowed, yaze::app::emu::video::WindowLayer::maskLogic, math_enabled_array_, mode, mosaic_size_, mosaic_startline_, yaze::app::emu::video::BgLayer::mosaicEnabled, oam, oam_adr_, oam_adr_written_, oam_buffer_, oam_in_high_, oam_in_high_written_, oam_second_write_, obj_interlace_, obj_pixel_buffer_, obj_priority_, obj_priority_buffer_, obj_size_, obj_tile_adr1_, obj_tile_adr2_, overscan_, pixelBuffer, ppu1_open_bus_, ppu2_open_bus_, prevent_math_mode_, pseudo_hires_, range_over_, scroll_prev2_, scroll_prev_, yaze::app::emu::video::Layer::subScreenEnabled, yaze::app::emu::video::Layer::subScreenWindowed, subtract_color_, yaze::app::emu::video::BgLayer::tileAdr, yaze::app::emu::video::BgLayer::tilemapAdr, yaze::app::emu::video::BgLayer::tilemapHigher, yaze::app::emu::video::BgLayer::tilemapWider, time_over_, v_count_, v_count_second_, vram, vram_increment_, vram_increment_on_high_, vram_pointer, vram_read_buffer_, vram_remap_mode_, yaze::app::emu::video::BgLayer::vScroll, yaze::app::emu::video::WindowLayer::window1enabled, yaze::app::emu::video::WindowLayer::window1inversed, window1left, window1right, yaze::app::emu::video::WindowLayer::window2enabled, yaze::app::emu::video::WindowLayer::window2inversed, window2left, window2right, and windowLayer.

Referenced by yaze::app::emu::SNES::Reset().

◆ Update()

void yaze::app::emu::video::Ppu::Update ( )

Definition at line 43 of file ppu.cc.

◆ UpdateClock()

void yaze::app::emu::video::Ppu::UpdateClock ( double delta_time)
inline

Definition at line 275 of file ppu.h.

References clock_, and yaze::app::emu::Clock::UpdateClock().

Here is the call graph for this function:

◆ HandleFrameStart()

void yaze::app::emu::video::Ppu::HandleFrameStart ( )

Definition at line 143 of file ppu.cc.

References even_frame, mosaic_startline_, range_over_, and time_over_.

Referenced by yaze::app::emu::SNES::RunCycle().

◆ RunLine()

void yaze::app::emu::video::Ppu::RunLine ( int line)

Definition at line 151 of file ppu.cc.

References CalculateMode7Starts(), EvaluateSprites(), forced_blank_, HandlePixel(), mode, and obj_pixel_buffer_.

Referenced by yaze::app::emu::SNES::RunCycle().

Here is the call graph for this function:

◆ HandlePixel()

void yaze::app::emu::video::Ppu::HandlePixel ( int x,
int y )
Todo
subscreen pixels can be clipped to black as well
Todo
Todo
math for subscreen pixels (add/sub sub to main)

Definition at line 163 of file ppu.cc.

References add_subscreen_, brightness, clip_mode_, even_frame, fixed_color_b_, fixed_color_g_, fixed_color_r_, forced_blank_, GetPixel(), GetWindowState(), half_color_, math_enabled_array_, mode, pixelBuffer, pixelOutputFormat, prevent_math_mode_, pseudo_hires_, and subtract_color_.

Referenced by RunLine().

Here is the call graph for this function:

◆ LatchHV()

void yaze::app::emu::video::Ppu::LatchHV ( )
inline

Definition at line 281 of file ppu.h.

References counters_latched_, h_count_, yaze::app::emu::memory::Memory::h_pos(), memory_, v_count_, and yaze::app::emu::memory::Memory::v_pos().

Referenced by Read(), and yaze::app::emu::SNES::WriteReg().

Here is the call graph for this function:

◆ GetPixel()

◆ EvaluateSprites()

void yaze::app::emu::video::Ppu::EvaluateSprites ( int line)
Todo
rectangular sprites, wierdness with sprites at -256

Definition at line 472 of file ppu.cc.

References even_frame, high_oam_, oam, oam_adr_, obj_interlace_, obj_pixel_buffer_, obj_priority_, obj_priority_buffer_, obj_size_, obj_tile_adr1_, obj_tile_adr2_, range_over_, time_over_, and vram.

Referenced by RunLine().

◆ CalculateMode7Starts()

void yaze::app::emu::video::Ppu::CalculateMode7Starts ( int y)

Definition at line 567 of file ppu.cc.

References bg_layer_, m7matrix, m7startX, m7startY, m7yFlip, mosaic_size_, and mosaic_startline_.

Referenced by RunLine().

◆ GetWindowState()

bool yaze::app::emu::video::Ppu::GetWindowState ( int layer,
int x )

◆ CheckOverscan()

bool yaze::app::emu::video::Ppu::CheckOverscan ( )
inline

Definition at line 311 of file ppu.h.

References frame_overscan_, and overscan_.

Referenced by yaze::app::emu::SNES::RunCycle().

◆ HandleVblank()

void yaze::app::emu::video::Ppu::HandleVblank ( )

◆ HandleOPT()

void yaze::app::emu::video::Ppu::HandleOPT ( int layer,
int * lx,
int * ly )
Todo
not sure if correct
Todo
not sure if correct for interlace

Definition at line 356 of file ppu.cc.

References bg_layer_, GetOffsetValue(), yaze::app::emu::video::BgLayer::hScroll, and mode.

Referenced by GetPixel().

Here is the call graph for this function:

◆ GetOffsetValue()

◆ GetPixelForBgLayer()

int yaze::app::emu::video::Ppu::GetPixelForBgLayer ( int x,
int y,
int layer,
bool priority )

◆ Read()

◆ Write()

void yaze::app::emu::video::Ppu::Write ( uint8_t adr,
uint8_t val )
Todo
oam address reset when written on first line of vblank, (and when
Todo
mosaic line reset specifics
Todo
vram access during rendering (also cgram and oam)

Definition at line 733 of file ppu.cc.

References add_subscreen_, bg3priority, bg_layer_, yaze::app::emu::video::BgLayer::bigTiles, brightness, cgram, cgram_buffer_, cgram_pointer_, cgram_second_write_, clip_mode_, direct_color_, fixed_color_b_, fixed_color_g_, fixed_color_r_, forced_blank_, GetVramRemap(), half_color_, high_oam_, interlace, layer_, m7charFill, m7extBg, m7largeField, m7matrix, m7prev, m7xFlip, m7yFlip, yaze::app::emu::video::Layer::mainScreenEnabled, yaze::app::emu::video::Layer::mainScreenWindowed, yaze::app::emu::video::WindowLayer::maskLogic, math_enabled_array_, memory_, mode, mosaic_size_, mosaic_startline_, yaze::app::emu::video::BgLayer::mosaicEnabled, oam, oam_adr_, oam_adr_written_, oam_buffer_, oam_in_high_, oam_in_high_written_, oam_second_write_, obj_interlace_, obj_priority_, obj_size_, obj_tile_adr1_, obj_tile_adr2_, overscan_, prevent_math_mode_, pseudo_hires_, scroll_prev2_, scroll_prev_, yaze::app::emu::video::Layer::subScreenEnabled, yaze::app::emu::video::Layer::subScreenWindowed, subtract_color_, yaze::app::emu::video::BgLayer::tileAdr, yaze::app::emu::video::BgLayer::tilemapAdr, yaze::app::emu::video::BgLayer::tilemapHigher, yaze::app::emu::video::BgLayer::tilemapWider, yaze::app::emu::memory::Memory::v_pos(), vram, vram_increment_, vram_increment_on_high_, vram_pointer, vram_read_buffer_, vram_remap_mode_, window1left, window1right, window2left, window2right, and windowLayer.

Referenced by yaze::app::emu::SNES::WriteBBus().

Here is the call graph for this function:

◆ GetVramRemap()

uint16_t yaze::app::emu::video::Ppu::GetVramRemap ( )

Definition at line 1023 of file ppu.cc.

References vram_pointer, and vram_remap_mode_.

Referenced by Read(), and Write().

◆ PutPixels()

void yaze::app::emu::video::Ppu::PutPixels ( uint8_t * pixel_data)

Definition at line 1038 of file ppu.cc.

References even_frame, frame_interlace, frame_overscan_, and pixelBuffer.

Referenced by yaze::app::emu::SNES::SetPixels().

◆ GetFrameBuffer()

const std::vector< uint8_t > & yaze::app::emu::video::Ppu::GetFrameBuffer ( ) const
inline

Definition at line 329 of file ppu.h.

References frame_buffer_.

◆ GetPixelForMode7()

int yaze::app::emu::video::Ppu::GetPixelForMode7 ( int x,
int layer,
bool priority )
private

Definition at line 307 of file ppu.cc.

References m7charFill, m7largeField, m7matrix, m7startX, m7startY, m7xFlip, and vram.

Referenced by GetPixel().

Member Data Documentation

◆ frame_overscan_

bool yaze::app::emu::video::Ppu::frame_overscan_ = false

Definition at line 296 of file ppu.h.

Referenced by CheckOverscan(), PutPixels(), and Reset().

◆ overscan_

bool yaze::app::emu::video::Ppu::overscan_ = false

Definition at line 297 of file ppu.h.

Referenced by CheckOverscan(), Reset(), and Write().

◆ forced_blank_

bool yaze::app::emu::video::Ppu::forced_blank_

Definition at line 300 of file ppu.h.

Referenced by HandlePixel(), HandleVblank(), Reset(), RunLine(), and Write().

◆ brightness

uint8_t yaze::app::emu::video::Ppu::brightness

Definition at line 301 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ mode

uint8_t yaze::app::emu::video::Ppu::mode

Definition at line 302 of file ppu.h.

Referenced by GetPixel(), GetPixelForBgLayer(), HandleOPT(), HandlePixel(), Reset(), RunLine(), and Write().

◆ bg3priority

bool yaze::app::emu::video::Ppu::bg3priority

Definition at line 303 of file ppu.h.

Referenced by GetPixel(), Reset(), and Write().

◆ even_frame

bool yaze::app::emu::video::Ppu::even_frame

◆ pseudo_hires_

bool yaze::app::emu::video::Ppu::pseudo_hires_

Definition at line 305 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ interlace

bool yaze::app::emu::video::Ppu::interlace

Definition at line 306 of file ppu.h.

Referenced by GetPixel(), HandleVblank(), Reset(), and Write().

◆ frame_interlace

bool yaze::app::emu::video::Ppu::frame_interlace

Definition at line 307 of file ppu.h.

Referenced by HandleVblank(), PutPixels(), Reset(), and yaze::app::emu::SNES::RunCycle().

◆ direct_color_

bool yaze::app::emu::video::Ppu::direct_color_

Definition at line 309 of file ppu.h.

Referenced by GetPixel(), Reset(), and Write().

◆ cyclesPerScanline

const int yaze::app::emu::video::Ppu::cyclesPerScanline = 341
private

Definition at line 334 of file ppu.h.

◆ totalScanlines

const int yaze::app::emu::video::Ppu::totalScanlines = 262
private

Definition at line 335 of file ppu.h.

◆ visibleScanlines

const int yaze::app::emu::video::Ppu::visibleScanlines = 224
private

Definition at line 336 of file ppu.h.

◆ enable_forced_blanking_

bool yaze::app::emu::video::Ppu::enable_forced_blanking_ = false
private

Definition at line 338 of file ppu.h.

◆ cycle_count_

int yaze::app::emu::video::Ppu::cycle_count_ = 0
private

Definition at line 340 of file ppu.h.

◆ current_scanline_

int yaze::app::emu::video::Ppu::current_scanline_ = 0
private

Definition at line 341 of file ppu.h.

◆ vram

uint16_t yaze::app::emu::video::Ppu::vram[0x8000]
private

◆ vram_pointer

uint16_t yaze::app::emu::video::Ppu::vram_pointer
private

Definition at line 345 of file ppu.h.

Referenced by GetVramRemap(), Read(), Reset(), and Write().

◆ vram_increment_on_high_

bool yaze::app::emu::video::Ppu::vram_increment_on_high_
private

Definition at line 346 of file ppu.h.

Referenced by Read(), Reset(), and Write().

◆ vram_increment_

uint16_t yaze::app::emu::video::Ppu::vram_increment_
private

Definition at line 347 of file ppu.h.

Referenced by Read(), Reset(), and Write().

◆ vram_remap_mode_

uint8_t yaze::app::emu::video::Ppu::vram_remap_mode_
private

Definition at line 348 of file ppu.h.

Referenced by GetVramRemap(), Reset(), and Write().

◆ vram_read_buffer_

uint16_t yaze::app::emu::video::Ppu::vram_read_buffer_
private

Definition at line 349 of file ppu.h.

Referenced by Read(), Reset(), and Write().

◆ cgram

uint16_t yaze::app::emu::video::Ppu::cgram[0x100]
private

Definition at line 352 of file ppu.h.

Referenced by GetPixel(), Read(), Reset(), and Write().

◆ cgram_pointer_

uint8_t yaze::app::emu::video::Ppu::cgram_pointer_
private

Definition at line 353 of file ppu.h.

Referenced by Read(), Reset(), and Write().

◆ cgram_second_write_

bool yaze::app::emu::video::Ppu::cgram_second_write_
private

Definition at line 354 of file ppu.h.

Referenced by Read(), Reset(), and Write().

◆ cgram_buffer_

uint8_t yaze::app::emu::video::Ppu::cgram_buffer_
private

Definition at line 355 of file ppu.h.

Referenced by Reset(), and Write().

◆ oam

uint16_t yaze::app::emu::video::Ppu::oam[0x100]
private

Definition at line 358 of file ppu.h.

Referenced by EvaluateSprites(), Read(), Reset(), and Write().

◆ high_oam_

uint8_t yaze::app::emu::video::Ppu::high_oam_[0x20]
private

Definition at line 359 of file ppu.h.

Referenced by EvaluateSprites(), Read(), Reset(), and Write().

◆ oam_adr_

uint8_t yaze::app::emu::video::Ppu::oam_adr_
private

Definition at line 360 of file ppu.h.

Referenced by EvaluateSprites(), HandleVblank(), Read(), Reset(), and Write().

◆ oam_adr_written_

uint8_t yaze::app::emu::video::Ppu::oam_adr_written_
private

Definition at line 361 of file ppu.h.

Referenced by HandleVblank(), Reset(), and Write().

◆ oam_in_high_

bool yaze::app::emu::video::Ppu::oam_in_high_
private

Definition at line 362 of file ppu.h.

Referenced by HandleVblank(), Read(), Reset(), and Write().

◆ oam_in_high_written_

bool yaze::app::emu::video::Ppu::oam_in_high_written_
private

Definition at line 363 of file ppu.h.

Referenced by HandleVblank(), Reset(), and Write().

◆ oam_second_write_

bool yaze::app::emu::video::Ppu::oam_second_write_
private

Definition at line 364 of file ppu.h.

Referenced by HandleVblank(), Read(), Reset(), and Write().

◆ oam_buffer_

uint8_t yaze::app::emu::video::Ppu::oam_buffer_
private

Definition at line 365 of file ppu.h.

Referenced by Reset(), and Write().

◆ time_over_

bool yaze::app::emu::video::Ppu::time_over_ = false
private

Definition at line 368 of file ppu.h.

Referenced by EvaluateSprites(), HandleFrameStart(), Read(), and Reset().

◆ range_over_

bool yaze::app::emu::video::Ppu::range_over_ = false
private

Definition at line 369 of file ppu.h.

Referenced by EvaluateSprites(), HandleFrameStart(), Read(), and Reset().

◆ obj_interlace_

bool yaze::app::emu::video::Ppu::obj_interlace_
private

Definition at line 370 of file ppu.h.

Referenced by EvaluateSprites(), Reset(), and Write().

◆ obj_priority_

bool yaze::app::emu::video::Ppu::obj_priority_
private

Definition at line 371 of file ppu.h.

Referenced by EvaluateSprites(), Reset(), and Write().

◆ obj_tile_adr1_

uint16_t yaze::app::emu::video::Ppu::obj_tile_adr1_
private

Definition at line 372 of file ppu.h.

Referenced by EvaluateSprites(), Reset(), and Write().

◆ obj_tile_adr2_

uint16_t yaze::app::emu::video::Ppu::obj_tile_adr2_
private

Definition at line 373 of file ppu.h.

Referenced by EvaluateSprites(), Reset(), and Write().

◆ obj_size_

uint8_t yaze::app::emu::video::Ppu::obj_size_
private

Definition at line 374 of file ppu.h.

Referenced by EvaluateSprites(), Reset(), and Write().

◆ obj_pixel_buffer_

std::array<uint8_t, 256> yaze::app::emu::video::Ppu::obj_pixel_buffer_
private

Definition at line 375 of file ppu.h.

Referenced by EvaluateSprites(), GetPixel(), Reset(), and RunLine().

◆ obj_priority_buffer_

std::array<uint8_t, 256> yaze::app::emu::video::Ppu::obj_priority_buffer_
private

Definition at line 376 of file ppu.h.

Referenced by EvaluateSprites(), GetPixel(), and Reset().

◆ clip_mode_

uint8_t yaze::app::emu::video::Ppu::clip_mode_ = 0
private

Definition at line 379 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ prevent_math_mode_

uint8_t yaze::app::emu::video::Ppu::prevent_math_mode_ = 0
private

Definition at line 380 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ math_enabled_array_

bool yaze::app::emu::video::Ppu::math_enabled_array_[6] = {false, false, false, false, false, false}
private

Definition at line 381 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ add_subscreen_

bool yaze::app::emu::video::Ppu::add_subscreen_ = false
private

Definition at line 382 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ subtract_color_

bool yaze::app::emu::video::Ppu::subtract_color_
private

Definition at line 383 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ half_color_

bool yaze::app::emu::video::Ppu::half_color_
private

Definition at line 384 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ fixed_color_r_

uint8_t yaze::app::emu::video::Ppu::fixed_color_r_
private

Definition at line 385 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ fixed_color_g_

uint8_t yaze::app::emu::video::Ppu::fixed_color_g_
private

Definition at line 386 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ fixed_color_b_

uint8_t yaze::app::emu::video::Ppu::fixed_color_b_
private

Definition at line 387 of file ppu.h.

Referenced by HandlePixel(), Reset(), and Write().

◆ layer_

Layer yaze::app::emu::video::Ppu::layer_[5]
private

Definition at line 390 of file ppu.h.

Referenced by GetPixel(), Reset(), and Write().

◆ m7matrix

int16_t yaze::app::emu::video::Ppu::m7matrix[8]
private

Definition at line 393 of file ppu.h.

Referenced by CalculateMode7Starts(), GetPixelForMode7(), Read(), Reset(), and Write().

◆ m7prev

uint8_t yaze::app::emu::video::Ppu::m7prev
private

Definition at line 394 of file ppu.h.

Referenced by Reset(), and Write().

◆ m7largeField

bool yaze::app::emu::video::Ppu::m7largeField
private

Definition at line 395 of file ppu.h.

Referenced by GetPixelForMode7(), Reset(), and Write().

◆ m7charFill

bool yaze::app::emu::video::Ppu::m7charFill
private

Definition at line 396 of file ppu.h.

Referenced by GetPixelForMode7(), Reset(), and Write().

◆ m7xFlip

bool yaze::app::emu::video::Ppu::m7xFlip
private

Definition at line 397 of file ppu.h.

Referenced by GetPixelForMode7(), Reset(), and Write().

◆ m7yFlip

bool yaze::app::emu::video::Ppu::m7yFlip
private

Definition at line 398 of file ppu.h.

Referenced by CalculateMode7Starts(), Reset(), and Write().

◆ m7extBg

bool yaze::app::emu::video::Ppu::m7extBg
private

Definition at line 399 of file ppu.h.

Referenced by GetPixel(), Reset(), and Write().

◆ m7startX

int32_t yaze::app::emu::video::Ppu::m7startX
private

Definition at line 402 of file ppu.h.

Referenced by CalculateMode7Starts(), GetPixelForMode7(), and Reset().

◆ m7startY

int32_t yaze::app::emu::video::Ppu::m7startY
private

Definition at line 403 of file ppu.h.

Referenced by CalculateMode7Starts(), GetPixelForMode7(), and Reset().

◆ windowLayer

WindowLayer yaze::app::emu::video::Ppu::windowLayer[6]
private

Definition at line 406 of file ppu.h.

Referenced by GetWindowState(), Reset(), and Write().

◆ window1left

uint8_t yaze::app::emu::video::Ppu::window1left
private

Definition at line 407 of file ppu.h.

Referenced by GetWindowState(), Reset(), and Write().

◆ window1right

uint8_t yaze::app::emu::video::Ppu::window1right
private

Definition at line 408 of file ppu.h.

Referenced by GetWindowState(), Reset(), and Write().

◆ window2left

uint8_t yaze::app::emu::video::Ppu::window2left
private

Definition at line 409 of file ppu.h.

Referenced by GetWindowState(), Reset(), and Write().

◆ window2right

uint8_t yaze::app::emu::video::Ppu::window2right
private

Definition at line 410 of file ppu.h.

Referenced by GetWindowState(), Reset(), and Write().

◆ bg_layers_

std::array<BackgroundLayer, 4> yaze::app::emu::video::Ppu::bg_layers_
private

Definition at line 413 of file ppu.h.

◆ mosaic_startline_

uint8_t yaze::app::emu::video::Ppu::mosaic_startline_ = 1
private

Definition at line 414 of file ppu.h.

Referenced by CalculateMode7Starts(), GetPixel(), HandleFrameStart(), Reset(), and Write().

◆ bg_layer_

BgLayer yaze::app::emu::video::Ppu::bg_layer_[4]
private

◆ scroll_prev_

uint8_t yaze::app::emu::video::Ppu::scroll_prev_
private

Definition at line 417 of file ppu.h.

Referenced by Reset(), and Write().

◆ scroll_prev2_

uint8_t yaze::app::emu::video::Ppu::scroll_prev2_
private

Definition at line 418 of file ppu.h.

Referenced by Reset(), and Write().

◆ mosaic_size_

uint8_t yaze::app::emu::video::Ppu::mosaic_size_
private

Definition at line 419 of file ppu.h.

Referenced by CalculateMode7Starts(), GetPixel(), Reset(), and Write().

◆ pixelBuffer

uint8_t yaze::app::emu::video::Ppu::pixelBuffer[512 *4 *239 *2]
private

Definition at line 423 of file ppu.h.

Referenced by HandlePixel(), PutPixels(), and Reset().

◆ pixelOutputFormat

uint8_t yaze::app::emu::video::Ppu::pixelOutputFormat = 0
private

Definition at line 424 of file ppu.h.

Referenced by HandlePixel(), and Init().

◆ h_count_

uint16_t yaze::app::emu::video::Ppu::h_count_
private

Definition at line 427 of file ppu.h.

Referenced by LatchHV(), Read(), and Reset().

◆ v_count_

uint16_t yaze::app::emu::video::Ppu::v_count_
private

Definition at line 428 of file ppu.h.

Referenced by LatchHV(), Read(), and Reset().

◆ h_count_second_

bool yaze::app::emu::video::Ppu::h_count_second_
private

Definition at line 429 of file ppu.h.

Referenced by Read(), and Reset().

◆ v_count_second_

bool yaze::app::emu::video::Ppu::v_count_second_
private

Definition at line 430 of file ppu.h.

Referenced by Read(), and Reset().

◆ counters_latched_

bool yaze::app::emu::video::Ppu::counters_latched_
private

Definition at line 431 of file ppu.h.

Referenced by LatchHV(), Read(), and Reset().

◆ ppu1_open_bus_

uint8_t yaze::app::emu::video::Ppu::ppu1_open_bus_
private

Definition at line 432 of file ppu.h.

Referenced by Read(), and Reset().

◆ ppu2_open_bus_

uint8_t yaze::app::emu::video::Ppu::ppu2_open_bus_
private

Definition at line 433 of file ppu.h.

Referenced by Read(), and Reset().

◆ tile_data_size_

uint16_t yaze::app::emu::video::Ppu::tile_data_size_
private

Definition at line 435 of file ppu.h.

◆ vram_base_address_

uint16_t yaze::app::emu::video::Ppu::vram_base_address_
private

Definition at line 436 of file ppu.h.

◆ tilemap_base_address_

uint16_t yaze::app::emu::video::Ppu::tilemap_base_address_
private

Definition at line 437 of file ppu.h.

◆ screen_brightness_

uint16_t yaze::app::emu::video::Ppu::screen_brightness_ = 0x00
private

Definition at line 438 of file ppu.h.

◆ memory_

Memory& yaze::app::emu::video::Ppu::memory_
private

Definition at line 440 of file ppu.h.

Referenced by LatchHV(), Read(), and Write().

◆ clock_

Clock& yaze::app::emu::video::Ppu::clock_
private

Definition at line 441 of file ppu.h.

Referenced by UpdateClock().

◆ tilemap_

Tilemap yaze::app::emu::video::Ppu::tilemap_
private

Definition at line 443 of file ppu.h.

◆ bg_mode_

BackgroundMode yaze::app::emu::video::Ppu::bg_mode_
private

Definition at line 444 of file ppu.h.

◆ sprites_

std::vector<SpriteAttributes> yaze::app::emu::video::Ppu::sprites_
private

Definition at line 445 of file ppu.h.

◆ tile_data_

std::vector<uint8_t> yaze::app::emu::video::Ppu::tile_data_
private

Definition at line 446 of file ppu.h.

◆ frame_buffer_

std::vector<uint8_t> yaze::app::emu::video::Ppu::frame_buffer_
private

Definition at line 447 of file ppu.h.

Referenced by GetFrameBuffer(), and Init().

◆ oam_size_

OAMSize yaze::app::emu::video::Ppu::oam_size_
private

Definition at line 450 of file ppu.h.

◆ oam_address_

OAMAddress yaze::app::emu::video::Ppu::oam_address_
private

Definition at line 451 of file ppu.h.

◆ mosaic_

Mosaic yaze::app::emu::video::Ppu::mosaic_
private

Definition at line 452 of file ppu.h.

◆ bgsc_

std::array<BGSC, 4> yaze::app::emu::video::Ppu::bgsc_
private

Definition at line 453 of file ppu.h.

◆ bgnba_

std::array<BGNBA, 4> yaze::app::emu::video::Ppu::bgnba_
private

Definition at line 454 of file ppu.h.

◆ bghofs_

std::array<BGHOFS, 4> yaze::app::emu::video::Ppu::bghofs_
private

Definition at line 455 of file ppu.h.

◆ bgvofs_

std::array<BGVOFS, 4> yaze::app::emu::video::Ppu::bgvofs_
private

Definition at line 456 of file ppu.h.


The documentation for this class was generated from the following files: