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

MMC1 question about rendering
http://forums.nesdev.com/viewtopic.php?f=3&t=14730
Page 1 of 1

Author:  DarkMoe [ Tue Aug 23, 2016 1:28 pm ]
Post subject:  MMC1 question about rendering

Hi ! me again,

So I'm trying to implement that official_only.nes test, that uses MMC1.

I managed to get the bankmapping working with the 5 bits shift register and it looks like it works ok.

What I don't understand at all, is how this impacts my rendering functions. According to the header, it has 16 banks of PRGROM of 16 kb each, which is the full rom, and no data for chrRom. So this means that the graphics are not hardcoded into the rom like other games ?

How am I supposed to change my logic to draw the letters for this test ?

I managed to implement all that t and v internal registers to get accurate scrolling, but this is something different.

Sorry for these basic questions, and thanks as always.

Author:  rainwarrior [ Tue Aug 23, 2016 1:33 pm ]
Post subject:  Re: MMC1 question about rendering

If the header says there are no CHR banks, then it is CHR-RAM instead of CHR-ROM: iNES format reference

Maybe this wiki article could help explain: CHR ROM vs. CHR RAM

Basically CHR-RAM just means you can write to it (via $2007) just like you would the nametables, except PPU range $0000-$1FFF is mapped to the CHR-RAM. (There are other obscure mappings, but this is the normal configuration for CHR-RAM.)

Author:  Rahsennor [ Tue Aug 23, 2016 6:05 pm ]
Post subject:  Re: MMC1 question about rendering

This is technically offtopic, but blargg's CPU tests are also available in NROM form. They can be found in the rom_singles folder of instr_test-v5.zip.

The NROM versions test both official and unoffical opcodes, but check the official opcodes first, so if you ignore tests that fail unofficial opcodes, you'll still cover all the official ones.

Author:  tokumaru [ Tue Aug 23, 2016 11:31 pm ]
Post subject:  Re: MMC1 question about rendering

I just want to point out that CHR-RAM is not an obscure thing, it's actually very common, a great number of NES games use that instead of CHR-ROM. This is actually what most other consoles and computers use too... Master System, Game Boy, Genesis, SNES... none of those have the option to use patterns directly from ROM, it's always RAM.

The NES is a rare exception, since Nintendo decided to put the pattern memory inside the cartridge instead of inside the console, probably to reduce costs, and this allowed developers to choose between ROM or RAM for each game.

Author:  Dwedit [ Wed Aug 24, 2016 5:53 am ]
Post subject:  Re: MMC1 question about rendering

I looked at bootgod's list and determined that around 25% of all games used CHR-RAM.

Author:  rainwarrior [ Wed Aug 24, 2016 12:28 pm ]
Post subject:  Re: MMC1 question about rendering

Dwedit wrote:
I looked at bootgod's list and determined that around 25% of all games used CHR-RAM.

There's a stats page with exactly that information on it: http://bootgod.dyndns.org:7777/stats.php?page=3

Author:  tokumaru [ Wed Aug 24, 2016 12:41 pm ]
Post subject:  Re: MMC1 question about rendering

rainwarrior wrote:
There's a stats page with exactly that information on it: http://bootgod.dyndns.org:7777/stats.php?page=3

Cool!

OK, CHR-RAM is slightly less common than I imagined, but it's still pretty common. :wink:

Author:  DarkMoe [ Wed Aug 24, 2016 2:06 pm ]
Post subject:  Re: MMC1 question about rendering

Thanks ! I just discovered my video rendering is not as good as I thought.

I will try those nrom alternatives.

Yeah I know about video ram, I have a fairly advanced GB/GBC emulator, but well .. I was confused with the NES.

Thanks everyone !

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