PPU rendering: Difference between revisions

From NESdev Wiki
Jump to navigationJump to search
m (workin' workin' workin')
 
mNo edit summary
Line 1: Line 1:
Work in progress, do not alter.
= NTSC PPU =
= NTSC PPU =
The PPU renders 262 scanlines per frame. Each scanline lasts for 341 PPU clock cycles (113.667 CPU clock cycles; 1 CPU cycle = 3 PPU cycles), with each clock cycle producing one pixel.
The PPU renders 262 scanlines per frame. Each scanline lasts for 341 PPU clock cycles (113.667 CPU clock cycles; 1 CPU cycle = 3 PPU cycles), with each clock cycle producing one pixel.
Line 6: Line 8:


== Scanline 20 ==
== Scanline 20 ==
This is a dummy scanline, whose sole purpose is to perform the [PPU_Sprite_Evaluation|sprite evaluation] for the next scanline. Although no pixels are rendered for this scanline, the PPU '''still''' makes the same memory accesses it would for a regular scanline.
This is a dummy scanline, whose sole purpose is to perform the [PPU_Sprite_Evaluation|sprite evaluation] for the next scanline. Although no pixels are rendered for this scanline, the PPU ''still'' makes the same memory accesses it would for a regular scanline.

Revision as of 18:54, 3 April 2011

Work in progress, do not alter.

NTSC PPU

The PPU renders 262 scanlines per frame. Each scanline lasts for 341 PPU clock cycles (113.667 CPU clock cycles; 1 CPU cycle = 3 PPU cycles), with each clock cycle producing one pixel.

Scanlines 0 to 19

These occur during VBlank. The VBlank flag of the PPU is pulled low during scanline 0, so the VBlank NMI occurs here. During this time, the PPU makes no memory accesses, so PPU memory can be freely accessed by the program.

Scanline 20

This is a dummy scanline, whose sole purpose is to perform the [PPU_Sprite_Evaluation|sprite evaluation] for the next scanline. Although no pixels are rendered for this scanline, the PPU still makes the same memory accesses it would for a regular scanline.