Crash City Mayhem/Runabout 3D Drive Impossible - crashes "Shader not linked"


#1

Issue:
The game crashes with “Shader not Linked” when switching vehicles or when completing the Hard difficulty version of the first mission.

System Information
Win7 x64 Home Premium SP1
Intel I7 3770
Nvidia GTX 760
citra-windows-msvc-20170516-8d55877 (happens on older builds as well, both nightly and bleeding edge)
Runabout 3D Drive Impossible/Crash City Mayhem
Screenshot of Issue:

Log(s): Annnd it turns out Pastebin cut them off. Chrissakes.
I’ll Google Drive them - this is the log for the car select menu crash:
https://drive.google.com/open?id=0B3UBOLSVNVVyWDU5anE4MkVKd0k
And here’s the log for the first mission on Hard crash, right up to the crash:
https://drive.google.com/open?id=0B3UBOLSVNVVyUkJzSFByOWhZakk


#2

Do you perhaps have any 3rd party applications running, such as FRAPS, Dxtory, MSI Afterburner, etc, that may interfere with Citra’s performance? I don’t own this game so I’m not able to corroborate.


#3

3rd party applications such as?
Can’t really think of anything I got running in the background that’d screw with it. Malwarebytes, Spybot S&D, Microsoft Security Essentials, nvtray.exe, Discord, PWRISOVM.exe and Steam, that’s about it.


#4

Sorry, forgot to include examples, I’ve edited my original reply. Basically programs that hook into OpenGL processes.


#5

Nothing of the sort.
Would it be possible to upload my copy of the game for you to test out, or is that against the rules?


#6

That would be piracy, so absolutely not, haha. The only other thing I can think of at this time is updating your GPU’s drivers? Otherwise, hopefully a developer can provide some insight.


#7

My drivers are up to date, so yep, need a dev to check it out.


#8

I’ve tested the game (Crash City Mayhem), and the same problem shows up here, everytime, in the same way. So, it’s safe to say it’s not any 3rd party app fault (I’m not running anything but Citra). Same results for the most recent nightly and Bleeding Edge builds.


#9

Yup, figured that was the case.


#10

After watching a video on Youtube - I figured out why it crashes after the end of that mission - you unlock a new car and it’s supposed to display a spinning 3d model of it. (3:52)


#11

Both logs are incomplete. They miss a couple of lines each (those which would be important).
This probably has to do with buffering in your terminal (Citra crashes before your terminal has finished outputting all of its messages).

However, this seems to be related to cubemapping and tangent bumpmapping.


#12

Yeah, that’s not my fault. I let it sit and output the log until the process kills itself.


#13

So should I try getting the logs again, or nah? It looks like it’ll take a hell of a lot of reverse engineering miracles to fix these bugs.


#14

Uploaded new logs from the latest Nightly build (as of typing this, citra-windows-msvc-20170522-c291db7)
Same shit looks to be happening. It keels over before it can completely output the entire log.


#15

@RM76 the log has enough detail in there to tell us why it crashes. specifically this line

[  42.187579] HW.GPU <Critical> video_core\renderer_opengl\gl_shader_gen.cpp:GLShader::WriteLighting:499: unimplemented bump mapping mode (tangent mapping)

means that the code hit this if statement

which means that it didn’t set up the surface_normal variable in the shader. the very next line in the shader (line 508) attempts to use that variable, but it wasn’t actually declared, so the shader fails to compile. Then citra attempts to use the shader, but since it didn’t compile, it doesn’t exist, so it just crashes horribly.

The fix for this is to implement tangent mapping but i have no clue how to do that shrugs

Is there an issue for this game on github? if not i’ll go ahead an make one


#16

There is no issue related to this for the game on GitHub


#17

Yep, there isn’t anything on Github regarding this.


#18

okay. i did start working on it last night. The issue is a missing lighting function in the hardware renderer, so i checked the software renderer to see how its supposed to work… and the software renderer doesn’t have any lighting methods at all which is kinda dumb. So the fix is going to take a lot more work, since I’ll need to implement it in software first and write a test case for this (and then finally fix the issue). So I can’t say if i’ll ever finish working on this, as I tend to project hop often (working on other things for citra right now as well) But I’ve been looking for a good “first graphics issue” to get into the graphics code, and this seems doable. when i make a tracking issue for this on github, I’ll link it back here in case you wanna watch progress


#19

Awesome, i’ll definitely keep an eye on it.


#20

FYI another dev wwylele has beat me to it, and the fix should be in the latest bleeding edge build (367)