gonetz / GLideN64

A new generation, open-source graphics plugin for N64 emulators.
Other
771 stars 179 forks source link

Castlevania 64 Legacy of Darkness: Game so slow when framebuffer is on (worse if i enable texture dumping) and game freezes in certain scenarios and cutscenes in LOW mode resolution #2709

Open md500 opened 2 years ago

md500 commented 2 years ago

Version information:

Describe the bug

ISSUE A: Game is slow when i are in this place, when framebuffer is on. Notice 4FPS: Screenshot_1

The issue is worse (to 2FPS) if I enable Texture dumping (I am retexturing the game on my own). No 100% gpu-cpu issue: No-Cpu-Gpu ISSUE

The issue disappars if i disable framebuffer emulation and texture dumping ( if you disable framebuffer emulation but you enable texture dumping, framerate will go to 4fps):

Screenshot_3-framebuffer disabled

This issue also happens in some places of the mansion, try to explore and you will face the same issue: Framebuffer ON-Texture Dumping ON: framebuffer-dumping-on-on Screenshot_3-986 Screenshot_3-9874

ISSUE B (This happens on HIGH mode Resolution):

Resolution

Another issue, that is critical on this plugin,when game is in High Resolution Mode: When i grab "The Contrat" (no matter in which level,scenario) game crashes with this error loop:

Screenshot_2

Crash in contrat on this place: Crash_Contract

This issue happens also in some situations (and i had to switch to Jabo Plugin to continue the game, and reenable GLideN64 when conflicting part is done):

Cornell:

Reinhardt, Carry and Cornell:

When Malus try to teleport to another place to battle Crash

Save State: Malus Teleport Crash.pj.zip

Save State: Back to Normal World Crash.pj.zip

To Reproduce

Steps to reproduce the behaviour:

  1. Open Project64 32bit (64bit not tested)
  2. Select GLideN64 Plugin 32bit QT
  3. Run Castlevania 64 Legacy of darkness.
  4. For ISSUE A:

5.A: Go to Villa Mansion, General room with this savestate: Framebuffer ON too slow-Mansion.pj.zip 6.A: Game slow due to framebuffer on, or texture dumping triggered.

  1. For ISSUE B:

  2. B: Set the game as HIGH mode Resolution.

  3. B: Go to Villa Mansion, Exit room (where contrat is) with this savestate: Game Crashes if i try to grab Contrat.pj.zip or
    Game Crashes if i try to grab Contrat2.pj.zip

  4. B: Grab Contrat with C> Button.

  5. B: Load the savestates attached on the screenshots to see cutscene crash.

  6. B: CRASH!

Expected behaviour

ISSUE A:

60 FPS when framebuffer and texture dumping is ON (like in various places)

ISSUE B:

No crashing when i grab contrat and cutscenes like on LOW mode resolution.

Screenshots Screnshots are included to corresponding context.

Additional context

Seems that GlideN64 tries to emulate a effect in HIGH resolution but when tries to do, it crashes, saying _Breakpoint found in MemoryVirtualMem.cpp line 615. Savestates is in High mode resolution. if you want to test it on low resolution, save the game,reset the game and configure the resolution as LOW.

Interestingly, the textures size don't change when you change the quality resolution from High to Low or viceversa.

Config of GLideN64: Screenshot_1 0 Screenshot_1 1 Screenshot_1 2 Screenshot_1 3 Screenshot_1 4

md500 commented 2 years ago

Seems what High quality Resolution is the culprit, causing the crashes in specific situations.

I dont know the reason why it doesn't happen on LOW mode Resolution. i know that game runs on 480i when is set to HIGH, and LOW is set to 240p.