nesdev.com
http://forums.nesdev.com/

Error graphic
http://forums.nesdev.com/viewtopic.php?f=10&t=16446
Page 1 of 1

Author:  giupviecnha [ Sun Sep 03, 2017 8:27 pm ]
Post subject:  Error graphic

[admin: spambot copy/paste, links removed]

Hello nesdev users

I'm working on a simple one-screen platforming game, which is actually coming along quite nicely. I have one small thing that annoys me though, if I turn on PAL emulation there is garbled graphics at the top of the screen (and bottom, but I know where that is coming from).

I'm guessing this has to do with the fact that I have set the Y scroll to 248 to make the top 8 pixels visable, that are hidden by the NTSC overscan if Y scroll is set to zero. However I'm living in PAL country so I really want it to look nice in PAL aswell.

I'm not really sure where the error graphics at the top is coming from, and hence my question. I was thinking of clearing the entire VRAM in my init section (right now it just clears Work RAM), I figured that might make the problem go away, but I'm still curious where the error at the top is coming from? If I look in FCEUX's NameTable viewer the error is not visible. The game currently doesn't use any mapper and is set to vertical mirroring if that makes any difference?

I tried blanking out most of VRAM in the RAM editor in FCEUX with no luck... soo, to sum it all up, where is the PPU picking up the garbled graphics at the top?

Author:  lidnariq [ Sun Sep 03, 2017 8:35 pm ]
Post subject:  Re: Error graphic

Y scroll values of 240 through 255 render the attribute table as though it were part of the nametable.

You probably actually wanted to use 232 (or maybe 488??) instead of 248.

Author:  tokumaru [ Sun Sep 03, 2017 8:37 pm ]
Post subject:  Re: Error graphic

Values 240-255 are "invalid" for the vertical scroll because name tables are only 240 pixels tall. What that does is force the PPU to render attribute table data as if it were name table data (hence why the glitch doesn't show up in the NT viewer).

Also, there are no guarantees as to how many scanlines will be hidden by the overscan in NTSC, but FCEUX is pre-configured to hide 8 scanlines at the top and bottom, which is hardly accurate. I suggest you go into the video settings and configure it to show all scanlines in NTSC as well as PAL, and code your game to not have glitches at the top or bottom, whenever possible. In scrolling games, glitches are sometimes unavoidable, but one-screen games should not have any trouble always generating clean backgrounds.

Author:  thefox [ Mon Sep 04, 2017 7:56 am ]
Post subject:  Re: Error graphic

It's spam: viewtopic.php?f=10&t=8175

Page 1 of 1 All times are UTC - 7 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/