cemu-project / cemu_graphic_packs

Community Graphic Packs for Cemu
https://cemu-project.github.io/cemu_graphic_packs/
Creative Commons Zero v1.0 Universal
1.3k stars 583 forks source link

The Legend of Zelda: Breath of the Wild [ALZ#01] #38

Closed ActualMandM closed 6 years ago

ActualMandM commented 7 years ago

[Moved to #137]

Since this is a pretty huge game, a lot of work will have to be put into the graphic packs. Issues with the game can easily appear when working on the graphic packs for this game.

Main:

Optional:

ActualMandM commented 7 years ago

For enhancements (and performance): Seems like there's more than two shadow resolutions, according to SunBroDave. http://www.neogaf.com/forum/showpost.php?p=231879693&postcount=1668


256x256
512x512
128x128
160x160
192x192
16x16
8x8
64x64
720x720
360x360
1x1
2x2
32x32
96x96
48x48
24x24
12x12
6x6
3x3
40x40
20x20
1024x1024
80x80
90x90
45x45
getdls commented 7 years ago

As far as I can tell this is the shadow rendering path for gameplay. 720x720 long shadows > (360x360 long shadows slice?) ->640x360 blur of shadow texture > 192x192 (light/dark grading)

Cut scenes have a per scene lighting as well (ie gl_FragCoord that needs a PS fix, somebody get me a 1.7.4 shader dump plz :P) . Player perspective is roughly the resolution of the projection of shadow textures 720 (tv res) ->640 (buffer res) When we uncomment that part for fixing buffer effects shadows look worse, the soft/blur pass is done in 640x360.

720x720 shadows 2d array 3 slices. 3 detail levels. Left distant, middle closest, right medum distance (flipped wrong way) . Red circle is Link So scaling 720 will increase resolution of all these 720x720shadows

360x360 shadows may just be the slices of 720, or 360 may be used for performance scaling.

2048x2048 Link light/shadow projection cut scene? Unverified. 1280x720 depth component projection player perspective 640x360 depth component projection player perspective, 2d blur/soften of toon shader, light projection spheres 320x180 depth component projection player perspective, bloom pass. 240x135 depth componet projection player perspective 160x90 depth component projection player perspective, medium detail bloom pass. , 80x45 depth component projection player perspective 192x192, 2d depth maps top down 64x64 depth component projection, 2d depth maps top down 40x22 low detail bloom pass.

64x64 > 32x32>16x16>8x8 cube map lod (world reflections)

512x512 format 0x005 Ground geometry LOD from height map, almost like old voxel engines. Should be interesting when we have texture modding.

1024x1024 + mipchain shrine volumetric fog ?

3x3, 6x6, 12x12 24x24 48x48 96x96 Unknown, noise pass, sprites? 3x3 is possible a noise cube map? 48 and 96 are probably GUI, breaks mini map when scaling.

64x45, 32x24, 16x12, 8x6, 4x3, 2x2 Lods of the same rendering, colour grading?

Texture dump also gives us 1024x1024, and 256x256 format 0005 textures, used for stencil shadows in other games. But I haven't seen/verified them in-game as actual shadows. 255x256 looks like its being used for lots of different things.

Tyrindor commented 7 years ago

You deleted my comment about the graphic pack not working with the new H264 workaround, yet it is not listed as a "known issue". Green screen when playing H264 videos, disabling the graphic pack fixes it.

https://sshnuke.net/cemuhook/

ActualMandM commented 7 years ago

@Tyrindor the next cemu hook update should fix the issue

ActualMandM commented 7 years ago

@Tyrindor 0.3.2.1 was just released, try it now

Tyrindor commented 7 years ago

Yup, H264 videos work now. Thanks.

Hopefully the lighting/effects bug is fixable soon.

ActualMandM commented 7 years ago

Lighting/Effects would probably have to be via shader edits, which'll be fun

ActualMandM commented 7 years ago

1.7.4 has been release..guess it's time for shader edits.

ActualMandM commented 7 years ago

Analyzing the shader dump that I have, these are all the shaders with 640x360:


// shader 00b74cdab38bd72d
// shader 055ca11a2e1c7de6
// shader 064174d03c7a7338
// shader 0a096d54107e22ab
// shader 1795744e5f959f55
// shader 1b6f1cb8d9fb2e79
// shader 1e0db7f18a7fef6c
// shader 1f2005679839f0ca
// shader 23c38da5c9aef0bc
// shader 265d3b30365a7138
// shader 266154d0365a7138
// shader 2759f8fd8a735d3a
// shader 28db0599573c4806
// shader 2c59c3af9167a570
// shader 31fde125871e70fa
// shader 3687cdb7bfe0a409
// shader 37d676b70ae6d357
// shader 392c495d12fe7be4
// shader 3be4a1d5966e5777
// shader 3c273ecef686dd8e
// shader 484f91d9ce86dda5
// shader 4cbfa4f6f8951733
// shader 4d036d99baf4ac0c
// shader 4d1ca7b9ece760d4
// shader 54027daa28ffe7e7
// shader 56bd38afd5afe30a
// shader 58584e3e2274fc43
// shader 58ef95e82a9705f5
// shader 5e66cff5db8184d1
// shader 618888517454b9bf
// shader 6231fee6894e3d79
// shader 646cb096281601e2
// shader 6c85af072694c2de
// shader 7354e1fdfa8a188d
// shader 790a1e1d52dae75c
// shader 7e31e6960354adb3
// shader 7ecbdbb1112e707f
// shader 869ee5a45d342865
// shader 890bc565a9bc40de
// shader 8abfa013f73d37ab
// shader 8bd41c459395db60
// shader 9f547256a5f2f2f6
// shader a40774e97ade15e0
// shader ace9a35e9e57d7ae
// shader b1002498154be3b4
// shader b44e557a637e76dc
// shader b55f825ef2af47ec
// shader b9f0cdeddf4fc7d3
// shader bac9e2015fecb3fc
// shader bd0442a1f7b73829
// shader bd288d85ec4f4c54
// shader bf5806b1290b6780
// shader c1a365bf63770190
// shader c470d852c2b43df3
// shader c4ad4fa8f7336b3b
// shader c71f19b3e12c9a07
// shader c797a1f793b1e3ac
// shader ca38bde2798599c6
// shader ce13b60ad9985473
// shader ceba17482659c1bd
// shader cf48323c7ceee04e
// shader cf48323c7ceee04e
// shader d2a1fc0ac6e87c0b
// shader d9de492cf31cc796
// shader dc345c7263d9eb44
// shader dc345c7263d9eb44
// shader e5ae13123ed8c9f3
// shader e5ca1be130f3e0e7
// shader e904a915f9f38891
// shader f02ede79447a61e3
// shader f10afc39e87a8ab5
// shader f1b567f005678b4a
// shader f2ea198f5cbcdaa5
// shader f3894eed08431ab9
// shader f6598d952b098f5f
// shader f819754f9c220aaa
Darkemaste commented 7 years ago

Awesome, 640x360 confirmed to break more than just heatwaves when uncommented. Also it seems fog uses 720x360. (discovered in GPUPerfStudio in 1.7.3)

getdls commented 7 years ago

640x360 upres issues I've seen Breaks normal mapping, example light on ground when opening chests and wall lights -> Fixed w PS edit "Breaks" distant blur so blending gets too sharp, introduces artifacts in edges. Example church roof.. Looks like an L shaped noise texture, probably 3x3. Cut-scenes are however the worst.. they combine all of the above with DOF issues further muddying the waters.

getdls commented 7 years ago

This fixes lights for shrine of Resurrection while scaling 640x360 for dof/shadows etc.

It looks like a generic approach can be taken as long as you're careful to scale the right shaders. So anyone can dig in.. its more about persistence from here on :) Look for any light source shader, dump, copy paste. I'll leave it here instead of committing. If anyone can confirm it works for AMD/doesn't break a bunch of stuff.. feel free to stick it in the repo.

edit Old files removed, please use repo files after commit, they have been tested by some nice ppl. There are at two dependencies

lightitup

I'm going after AO and the distant horizon artifacts, AO doesn't increase sample amount.

ActualMandM commented 7 years ago

@getdls Some people found shaders not scaled. (I don't know what shaders they are, sadly) Cooking Pots are broken, reported by Loli Co. and JoelAlone on official discord image image

Shrine teleport is broken, reported by JoelAlone on discord image

Shrine Monk Barrier, reported by Kieron on discord image

Heart Piece, reported by flocker on discord image

This one was also reported by flocker on discord image

image image shader edits aren't being used in that screenshot

Someone noted that the fire on the torch disappeared for them

NiagA on GBAtemp reported Tower lighting issues image image image

ActualMandM commented 7 years ago

I don't understand how I would have broken bloom. Apparently people who use your fixed graphic packs get bloom, but those who use the packs in the repo have no bloom. And yet it uses pretty much the same exact values. Only thing I tried was adding format exclusions to make the bloom not scale, both title screen and in-game. Nobody gets bloom because of these format exclusions. Is it because of q-res being scaled in the repo but not in the fixed packs? I've reverted those changes already, but it gives the pixelated bloom that everyone hates. I honestly don't know at this point. Either way, I'm just gonna take a break from this.

Images are by Kieron on the official Discord Repo ones with format exclusion: image Your fix graphic pack: image

Edit: Seems like I messed something up when scaling the images. Kieron found what seems to be the same issue that NiagA found, but can't find it on your pack. I give up. I'll leave BotW up to you guys. I'll be focusing on other games instead. image image

getdls commented 7 years ago

v0.3

edit Old files removed, please use repo files after commit, they have been tested by some nice ppl.

I'm not scaling any of the bloom resolutions, nor AO right now . So far I haven't seen any improvements in other fx that makes it worth it. Could be that... or what you're seeing bloom + shader fix? update Now includes temple of time heart fix..

Any new issues, please report, and include a save file... I'd like to avoid spoilers as much as possible.

MaxG3D commented 7 years ago

@slashiee Yes, the scaling of the bloom offset is what causing the bloom to be pixelated. If you want to scale the size of the bloom like that, you would also need to find the weights in the code (Assuming the big N is using the Gaussian Bloom). It's an easy fix, either delete the scaling code lines or replace them with default resolutions:

[TextureRedefine] #q-res1 width = 320 height = 180

formatsExcluded = 0x816,0x01a #Completely gets rid of bloom

overwriteWidth = 320 overwriteHeight = 180

[TextureRedefine] #q-res2 width = 320 height = 145 overwriteWidth = 320 overwriteHeight = 145

[TextureRedefine] #q-res3 width = 320 height = 144 overwriteWidth = 320 overwriteHeight = 144

[TextureRedefine] #o-res1 width = 160 height = 90 overwriteWidth = 160 overwriteHeight = 90

EDIT: One could also comment those lines, as so many people on Discord so gracefully corrected me.

ActualMandM commented 7 years ago

@getdls I've just added the new shaders with commit e269ac3. For those reading this, please send thanks to him, not me. I've also said in #gfx_packs (and #botw_discussion) for the official discord to send a save file for new issues.

@MaxG3D The issue is not the pixelated bloom, the issue is that excluding the bloom makes it disappear altogether. Values commented out in f9af446.

Tyrindor commented 7 years ago

The new commits are working really well for me, it's definitely getting there. I have noticed that water ripples change color at certain camera angles when swimming, and it doesn't seem to happen with the pack disabled. Really minor though.

getdls commented 7 years ago

These are two "enhancement" packs in one zip. They show how to scale 640/ DOF to arbitrary resolution and still keep light fixes working. Nothing new is fixed, it just gives some minor improvements and possible breaks other stuff.

Since they scale up 640, things limited by that viewport prettied up abit.

Edit 3 Attached wrong 1440 version last night, sorry abt that, lights should work now.
4k/8k replaced with 1080 and 1440 only clean horizon versions should be more useful for actual gaming.. and I'm guessing what most ppl want.

edit Old files removed, please use repo files after commit, they have been tested by some nice ppl.

I'm hoping the 4k/8k version can be used in combination with AO fixes and some new blur implementation eventually.

zeldahoirzon2

motionloops commented 7 years ago

Hey Guys, have you tried increasing the depthbuffer accuracy (change it from 16bit to 32bit)? This could help fix some of the issue with distant terrain flickering aka Z-fighting. The Cemu changelog for 1.7.4 mentions "'overwriteFormat' and allows to respecify the data format of a texture. For example, using this property it's possible to turn a 16bit depthbuffer into a 32bit depthbuffer" but it doesn't say how. I also noticed that the low lying distant clouds in the terrain are missing so this might fix that as well.

ActualMandM commented 7 years ago

I tried changing the game format from 0x019 to 0x816, Only saw regression 2017-04-03_19-49-55

getdls commented 7 years ago

Yea that and some of the atmospheric / shadow/texture layer blending def could use some higher precision. I was going to try it out for fixing Xenogears bloom, but I'd love to see some examples where it works and not just pads the values.

As for depth, can we get higher precision (apart from increasing resolution) and still use Wiiu features? Depth is 0x005 afaik and unorm has higher precision than float 32 at 0-1 values. GX2_SURFACE_FORMAT_UNORM_R16 = 0x05, Let's hope I'm wrong here..

ActualMandM commented 7 years ago

@Tyrindor Issue seems to be a Cemu issue, reznoire 1.7.4 preview video has it as well https://youtu.be/B548VlSXykI?t=22

CubanLegend commented 7 years ago

@getdls thank you for the 8k DOF, its performance heavy but the research leading to it's fix is appreciated. :)

Would you happen to be able to check out removing the remaining hud elements like the hearts and the horse sprint spurs? Just curious is that's something you might like to do, it would make for greater immersion in the Pro HUD mode, and would also double as a great start to a proper BoTW CEMU photomode.

ActualMandM commented 7 years ago

image 8f175aa8e7c01843be523b9600be3b2dd226aa0a

motionloops commented 7 years ago

I took a look at the depth buffer using Nvidia's Nsight and Cemu is already using a 32 bit depth component. But it seems like all the precision is towards the near clip plane of the buffer. So in botw, for example distant objects have issues with Z-fighting and missing low lying clouds and fog in the distant terrain. This leads me to believe that the depth value is not being encoded properly (https://developer.nvidia.com/content/depth-precision-visualized). I'm a graphics developer but i know almost nothing about emulation so i could be totally wrong about this. Either way I'm just trying to help by pointing out a possible issue. Anyone know how to get in touch with Exzap or one of the other cemu dev. Tried discord but I'm guessing he's being inundated with questions.

RedDevilEvo commented 7 years ago

Hi guys ! how could i resolve those light glitch? I have the last 1080p graphique pack. I love Link but a twin is too much lol!..

cemu 2017 04 07 - 13 51 54 02

cemu 2017 04 07 - 13 41 21 01

motionloops commented 7 years ago

@RedDevilEvo Delete then update your graphics pack, I'm using the latest one and i don't have those issues.

RedDevilEvo commented 7 years ago

@motionloops I just tried but still the same. 1080p pack. I did not have a 4k monitor so.. :/

ActualMandM commented 7 years ago

Make sure that the text files with the long names are in the same folder as the 1080p pack

RedDevilEvo commented 7 years ago

@slashiee It worked thanks a lot !

If anyone got the same glitch .. be sure your pack look like this. haha 1

ActualMandM commented 7 years ago

@getdls image

getdls commented 7 years ago

@slashiee image

pretty plz? with sugar on top

JoelAlone commented 7 years ago

@getdls save.zip Save with broken heatwaves

getdls commented 7 years ago

Issue is intermittent, not much I can do about it. From what I can see, the PS has some delay when viewport doesn't match half size, if I just stand still, it loads after about 8 seconds, and then everything works fine. BOTW uses lazy evaluation of some effects, for example the wall lights.

JoelAlone commented 7 years ago

@getdls Can you tell me how to kill this effect?

getdls commented 7 years ago

Any way that stops the resource from being used should work. ie Dump the texture to get ID and type, work backwards from there to the PS and remove the texture line from the shader.

3450514d9d25fd6e_0000000000001e49_vs_source.zip

getdls commented 7 years ago

This is an updated AA removal that also fixes the issues with horizon and grass. Files are resolution independent so just drag and drop into any pack. To avoid any confusion, AA removal is meant for ppl using their GPU drivers for AA , not to replace the in game AA with a new version.

Botw_AAremovalV2.zip

Happy Easter for anyone who celebrates!

getdls commented 7 years ago

Commit fixes Dof masking, used for near field blur, haze blur, water effects etc. This works by only scaling depth for 320, 160, 80, ie not breaking bloom

AAremovalV2 was also added

maskingfix

https://github.com/slashiee/cemu_graphic_packs/commit/693778d88ade1c1eb4277c88ffde8ae352fedb0a

ActualMandM commented 7 years ago

1800p pack added witch 76786a1cad71d73c428252b53e62506a368fe0af, please thank @JoelAlone for making the 1800p pack itself, saved me some time with making 1800p packs altogether

I heard there's a new graphical issue with 1.7.5, but I haven't messed with BotW much this update. If there's anyone that can confirm this graphical issue and can upload a save file to it, it would be gladly appreciated.

LUCKASSs commented 7 years ago

Hello guys, and sorry for the shitpost, but how I can use these files : http://prntscr.com/f117wv

And how I can use these + another rules.txt like this ? : http://prntscr.com/f117sv

BTW I use the 1.7.5, I can upload what you want from It.

thx !

RedDevilEvo commented 7 years ago

Read the comment i did a post for that.

Make a txt file for all of thoses with the name you see with all of those number.

And pute it on your CEMU/graphiquepack folder

Create a new folder in and give it the name you want. And drop all your txt files in it.

Should look like my post i did here just look up

LUCKASSs commented 7 years ago

@RedDevilEvo Yeah I have already do that : http://prntscr.com/f121u2

btw, why people want to remove AA ?

RedDevilEvo commented 7 years ago

Yeah on a different folder. And you have to activate your mods ( pack ) via CEMU

LUCKASSs commented 7 years ago

@RedDevilEvo ok thx, and Why people want to remove the AA ? it make the game much better ?

RedDevilEvo commented 7 years ago

I dont know i'm still playing with the AA. Maybe it's a performance issue. Low fps or visual glitch i dont know.

JoelAlone commented 7 years ago

BoTW's AA is really bad in comparison to SMAA or even FXAA, that's why many people remove and replace it with other AA method.

ActualMandM commented 7 years ago

Updates to BotW pack will be postponed until 1.7.6, we don't want to work on shader edits just for it to be completely wiped with the next update. It would just be a waste of effort. Please don't report issues about lighting issues when 1.7.6 releases please. But if it happens to be a new lighting issue that wasn't fixed though, then please do report it.

amunozj commented 7 years ago

Hi! First of all thank you so much for all the work you have put into the graphic packs. I wanted to ask you a quick question. The performance 540p pack is too severe a reduction and the quality 1080 is too demanding. I wish there was an in-between option. When I run the game without packs it has the perfect resolution, but I was wondering if I could benefit from all your other fixes. Is there an easy way to modify your packs so that they don't change resolution, but include the rest of the things? Thank you!

BreakPoints commented 7 years ago

@amunozj The fixes here are all fixes for bugs that happen due to overriding the default resolution. If you aren't using any graphics packs then you don't need any fixes, it should be less buggy than even these graphics packs with their fixes.