gonetz / GLideN64

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

Texture dump doesn't happen (Detailed explanation) #2693

Closed md500 closed 2 years ago

md500 commented 2 years ago

Version information:

Describe the bug

A clear and concise description of what the bug is.

Latest plugin version doesnt dump textures in Donkey Kong 64 (not tested if happens in other games). Tried setting File Storage instead of memory cache in N64 textures, Use File Storage istead of memory cache, and Save Enhanced texture cache to hard disk. Only hires_texturesS folder is loaded but texture_dumpS it seems that it does not see the folder and does not dump anything (although the program creates the folder if it is deleted). However Hi Res texture loading works.

DUMP

Folder permissions is in Everyone (no permissions error)

PERMS

In Glide64 Final ( May 8 2012) when "Texture dumping/editing mode" and "save texture cache to hard disk" is ticked, textures are dumped if i press "D" Button toggle, on keyboard (controls are configured to prevent conflict with Glide64) and hires_texture folder is loaded if there are texture files texture files there if (ej. hires_texture\DONKEY KONG 64\GlideHQ) exists and texture dumping happens in (ej. texture_dump\DONKEY KONG 64\GlideHQ), and Press "R" keyboard button to reload hires_texture regenerating its hires cache related files. In other words, you can dump textures and/or load hires textures at same time with option reloading with "R" button.

glide64options

GLideN64 finds hires_textures files without GlideHQ (i think to prevent colission if both gfx plugin texture location points to same folder).

But in this case, GLideN64 doesnt dump textures. Tried Pressing D button toggle to dump, but it doesn't do anything...

LOCATION

ResultOfDump

To Reproduce

Steps to reproduce the behaviour:

  1. Open Project64 32bit (64bit not tested)
  2. Select GLideN64 Plugin 32bit WTL
  3. Options > Graphics Settings.
  4. In Texture Enhancement, tick Use File Storage Instead of memory cache, Use Texture Pack, Use file storage istead of memory cache, and Save enhanced texture cache to hard disk. (On my case,changed default folder paths to another with an S, (hires_texturesS,cacheS,texture_dumpS)
  5. Run DK64 ROM.
  6. While Gameplay press R, to reload hires textures or D to start dumping
  7. Check C:/Program Files (x86)/Project64 3.0.1/Plugin/texture_dumpS folder to see if any texture is dumped.
  8. No texture dump in Texture_dumpS triggered. In addition, the corresponding game folder textures is not created. Again, no permissions issue because, the permissions are inherited from the Plugin folder and set to Everyone owner and set to total control/full control.

permissionsS

Expected behaviour Textures are dumped to configured texture pack folders if "D" button toggle is pressed and "R" to reload hi res textures (and regenerates cache)

Screenshots Screnshots are included to corresponding context.

Additional context I dont know if this works on GlideN64 stable versions and old commits, and i dont know if its works on Project 64 64bit and GLideN64 64bit architecture. Not tested if this issue happens in other games.

Jj0YzL5nvJ commented 2 years ago

The really important part is whether the problem is reproducible with the Qt version.

WTL hasnt been updated in quite a while, use the Qt version

md500 commented 2 years ago

@Jj0YzL5nvJ It works on QT version! Now how I can disable framebuffer textures dump? (I paused game but it also dumps framebuffer textures) ? I only want to dump textures in game but no framebuffer textures.

Jj0YzL5nvJ commented 2 years ago

Disabling the frame buffer emulation... maybe? I really have no idea.

md500 commented 2 years ago

@Jj0YzL5nvJ

Disabling the frame buffer emulation... maybe? I really have no idea.

Mmm, i forgot to mention that Glide64 Final doenst emulate framebuffer. Well back to this case, unticking options and setting, disables Framebuffer emulation, but it dumps textures very well. but i dont know if GLideN64 will determine whether the texture is a framebuffer or not, and add a feature like "Dump also framebuffer textures" or "Render framebuffer as texture"

Framebufer Disable

Jj0YzL5nvJ commented 2 years ago

efb

md500 commented 2 years ago

efb

Emulate framebuffer with copy options disabled (on this case framebuffer like copy options disables "image mirroring?" and textures framebuffer is not dumping.

Framebuffer enable but processing disabled

Emulate framebuffer with copy options enabled ( framebuffer copy mirrorring is working, but texture framebuffer is also dumping)

Framebuffer enable whith video card frame buffer and depth buffer enable

From what I'm seeing it is not necessary to completely disable framebuffer emulation

Jj0YzL5nvJ commented 2 years ago

Async mode is for speed, it corrupts some effects:

The broken jigsaw puzzle effect (Async mode): banjo-kazooie-008

The correct jigsaw puzzle effect (Sync mode): banjo-kazooie-009

md500 commented 2 years ago

Async mode is for speed, it corrupts some effects:

The broken jigsaw puzzle effect (Async mode): banjo-kazooie-008

The correct jigsaw puzzle effect (Sync mode): banjo-kazooie-009

Yeah, it also occurs when i use dk64 camera: on async mode the reticle also shows in the photo, which is not correct. So sync mode is recommended (altough it also dumps texture framebuffer, including async/sync modes). i dont know if is correct to use "VI Origin Change" at least, in dk64 i dont see any issue about it.

Mmm so the issue to texture dump issue must be closed, and file other bug like framebuffer dumping on texture. someone can link the bug, to prevent duplicate?

md500 commented 2 years ago

Context about texture dumping: Making texture retexture using Real-ESRGAN, texture framebuffer doesnt make sense when i making hi res textures with Real-ESRGAN. so i had to disable sync/async modes (Copy video card framebuffer to N64 memory set to Never) to prevent it.

Hopefully in the future Gliden64 will avoid dumping framebuffer textures when "Copy video card framebuffer to N64 memory" is set to sync/async mode.

Xii-Nyth commented 1 year ago

Hey md500 Ive also started on a pack for this but got pushed back since im working on pd. I managed to dump everything with the newest update usuing inaccuate texture coordinates and mipmaps off like I did with perfect dark

Xii-Nyth commented 1 year ago

heres my dumps sorted ot a tiny bit

zip is too big and 7z isnt supported, so just rename to .7z DONKEY KONG 64.zip