Jump to content

AMD MSAA 1x bug


Slimwaffle
 Share

Recommended Posts

But this is only happening with water right? Maybe there's just something in the water's shader that isn't compatible with AMD. If we can narrow it down to a line of code, then it will help AMD to find the issue.

With MSAA 1x that whole screen is "static" regardless of the existence of water. I will update my script to toggle water to show this. Setting MSAA 2x most everything else looks normal except water, water is still broken no matter what value we use for MSAA.

 

MSAA 1x = static everywhere

MSAA 2x+ = water glitched

Link to comment
Share on other sites

  • 2 weeks later...

Curious. If you place this dll in with your game exe, will the issue magically go away? I'm on a Nvidia GPU so I can't test it myself.

 

Dll is from an old CCC driver before AMD started breaking OpenGL support.

Cyclone - Ultra Game System - Component PreprocessorTex2TGA - Darkness Awaits Template (Leadwerks)

If you like my work, consider supporting me on Patreon!

Link to comment
Share on other sites

@thehankinator : Will the waterbug (look into) vanish if you set reflection camera to MSAA=2 ?

 

   --check if we have reflection camera.
   self.world=World:GetCurrent()
   if self.rcamera==nil then
       for i=self.world:CountEntities()-1,0,-1 do
				    if self.world:GetEntity(i):GetClass()==Object.CameraClass then
                           if self.world:GetEntity(i):GetScale().y<0 then
                               self.rcamera=self.world:GetEntity(i)
						    tolua.cast(self.rcamera,"Camera")
						    System:Print("..found reflection cam")
						    self.rcamera:SetMultisampleMode(2)
                               break
                           end
				    end
		    end
  end

  • Upvote 1

HP Omen - 16GB - i7 - Nvidia GTX 1060 6GB

Link to comment
Share on other sites

@thehankinator : Will the waterbug (look into) vanish if you set reflection camera to MSAA=2 ?

 

This fixed looking into water but only when the camera(not the reflection camera) set to 2x MSAA. If 1x MSAA there is no change. This will work as a workaround for now, thanks shadmar!

 

2x MSAA camera + 2x reflection camera = no corruption

1x MSAA camera + 2x reflection camera = full corruption (same as my previous screenshot)

  • Upvote 1
Link to comment
Share on other sites

I expanded on shadmar's code for a somewhat automatic workaround. If you take the below script and put on a pivot in your level, it will set 2x MSAA on every camera in the map. The first frame rendered will be corrupted but after that it should look good. Has to be on post render because I don't think reflection cameras are created until Render().

 

--The Hankinator's workaround for AMD's 1x MSAA bug present in driver version 16.2.1
--Thanks shadmar for initial code
Script.amd_1x_msaa_workaround_executed = false
function Script:PostRender(ctx)
if not self.amd_1x_msaa_workaround_executed then
 System:Print("!!!WARNING!!! AMD 1X WORKAROUND ACTIVE WARNING!!!")
 System:Print("!!!WARNING!!! REMOVE THIS WHEN DRIVERS ARE FIXED WARNING!!!")

 self.amd_1x_msaa_workaround_executed = true
 local w = World:GetCurrent()

 for i = w:CountEntities()-1,0,-1 do
  if w:GetEntity(i):GetClass() == Object.CameraClass then
   local cam = w:GetEntity(i)
   tolua.cast(cam,"Camera")
   System:Print("!!!WARNING!!! Found cam, setting 2x MSAA !!!WARNING!!!")
   cam:SetMultisampleMode(2)
  end
 end
end
end

  • Upvote 2
Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...

AMD driver version 16.3.2 released. Still broken.

 

Is there any pressure being applied to AMD to fix this? I assume Josh reported this through some other avenue when he said it should be reported on Nov 15th 2015 or at least on Jan 21st 2016 when he said he would talk to AMD. The public post from the 2nd is basically forgotten.

 

It seems fishy to me that there are no other posts on AMD's forums about this because this is a pretty serious bug.

 

I realize I'm beating a dead horse here but I am really getting irritated because from the outside, it doesn't seem like anything is happening to get AMD to fix this. An argument could be made that this is an AMD problem and I/we should just buy an Nvidia card but AMD holds significant share and if this game engine is to be taken seriously, this is the type of bug that should be a top priority because it is new and higher end (ie future) AMD cards that are suffering primarily.

Link to comment
Share on other sites

Do any games (non LE games) have this issue that you can tell?

I've not had any trouble with any (non-LE) games but I can't be sure which games use DX or OpenGL (not to mention which version). However, I've been running GFXBench GL which is a benchmark utility specifically for OpenGL. I've run a number(focusing on OpenGL 4 tests) all of them run just fine.

Link to comment
Share on other sites

I decided to download Unity3D to try and reproduce the bug. I'm no expert with this engine but I verified "good" quality has MSAA turned off (1x) and I set the Graphics API to use OpenGL Core, which should be the latest API (I tried 3.3 also, looked fine). What are they doing differently to avoid this problem?

 

7fx8N2q.png

Link to comment
Share on other sites

  • 2 weeks later...

There's two ways around this, for me to implement.

 

Switch the default MSAA level to 2x when AMD hardware is detected.

 

Implement a second copy of the light shaders using regular texture2D textures when 0x MSAA is used.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

×
×
  • Create New...