Weird and sudden display problem
![rindfan_2393f1598d](https://secure.gravatar.com/avatar/54043076e2426e53b86adfdb74591db9?&r=pg&s=100&d=https%3A%2F%2Fvanillicon.com%2F54043076e2426e53b86adfdb74591db9_100.png)
Hey guys,
Wondered if you can shed some light on this issue. All of a sudden, I'm getting this VERY odd display bug with surfaces of particular items. It's like all the surfaces are inverted and not displaying properly. It makes them completely unusable as I can't see their textures or anything.
Bizarrely, it renders absolutely fine.
I've tried reinstalling Daz, resetting to factory defaults, changing the display type - from shaded texture to iRay and back again - and nothing's worked. This problem literally just started this morning, and seems to be entirely randomly affecting various items. Some clothing displays fine, others have this issue. Until I load something, I don't know whether or not it'll display correctly.
Genuinely at a loss for what on Earth has happened, and it's actually rather upsetting to be honest, as it makes things next to impossible to use. :(
Comments
UPDATE:
Switching to Wire Texture Shaded display makes them work properly - can see the surfaces and stuff - but it makes life difficult to work with. The problem seems to be lying with the Texture Shaded display option somewhere...
If it's the OpenGL issue I'm thinking of, sadly I think it's something we have to live with for now, and it's been like that for years. I'm not sure if its something that can't be fixed (ie, built into 3rd party logic) or something that's just considered less important than other things (since it is cosmetic in the viewport only.) It does indeed make it hard to work with items when the surfaces behind are displayed in front of the surfaces in front.
It is the OpenGL tranparency map issue...and the only way to 'fix' it is to replace the basic OpenGL shaders with ones made this century....as the OpenGL shaders in Studio seem to be circa mid-90s.
It's weird, because it only just started happening today. It's been fine for literally years beforehand, so why it's suddenly decided to play up, smeg knows...
Note that it depends on the material being used, so you won't see it all the time, only for certain things. I see it on hair and the morphing fantasy dress often enough to remember those for example. (I'm guessing you haven't been using this identical scene seen in the screenshot above for years? Do you remember what changes you made to the scene today vs. yesterday that might affect it?).
Of course there could also be something else going on too in addition to the above-mentioned OpenGL issue.
You could try temporarily changing the material of the object in question (or those behind the object in question) to not use any transparency to see if that makes it go away. I'm not sure if that would help you as sort of a workaround while working with the scene, then reapplying the material that triggered the issue near the end?
Here's an example to help clarify my previous comment. This is the MFD with a randomly-selected material on the right, where you can see the issue happen with bits of the back of the dress drawn over the front of the dress.
On the left is a copy of it, except I went into the surfaces pane and set the opacity parameter's image to nothing, at which point the issue disappears. So if you are having trouble with one specific area you are working with, you could do this (if you have the same issue as this) just temporarily, then set it back when done. Of course that might be more trouble than it's worth for many surfaces or doing it all the time and won't help if you actually NEED the opacity set correctly while you are working on your scene.
And of course you could also test this with the material(s) in your scene above just to see if this is truly the same thing you are experiencing.
This is a figure I've been working on during this week and I just added the clothing - which worked perfectly before - and it was looking like that. I tried your suggestion of clearing the opacity, and whilst it makes the mesh clearer, all the surfaces remain completely black. It's most bizarre...
Necro-ing this thread because I had the same bug with a different product by the same vendor (Dogz).
Symptom: In Viewport (OpenGL) Texture Shaded view some surfaces are black. This is not due to lights (other surfaces are correct, and because Wire Texture Shaded view displays correctly) or opacity/transparency (none of the objects in the scene have any transparency). Also surfaces display correctly when rendered.
Workaround: For me, enabling Backface Lighting and disabling Per-pixel Shading in the Preferences->Interface fixes the problem. (The latter is not ideal as then you can get bad lighting in some other places, but it's a better workaround than Wire Texture Shading).
Bug analysis: Based on what I can see, this is very vaguely but not really a content bug, and mostly a Daz Studio bug.
1 Two-sided material. What's going on is that some geometry (like clothes) is modeled as infinitely thin, with just single polygons representing a thicker material. This means that a single polygon is used to draw both the inside and the outside of the surface. ("One-sided" material polygons have an "interior" and an "exterior" and are only expected to be seen from the exterior, and to create a double-sided surface there is explicit geometry modeling the inside surface and the outside surface.)
2 Two-sided lighting. When drawing a two-sided material, the renderer must take care to compute the lighting as seen from whichever side the viewer is looking at. This is because the direction the surface is "facing" is used in the math for lighting calculations. A single polygon can only be facing in one direction, so when using the same polygon to appear to face in two directions as described in point 1, care must be taken to adjust the math if the viewer is looking at the "back side". Daz has an interface preference called Backface Lighting which enables this behavior. If you have it disabled, the "interior" side of polygons will display incorrectly, which is perfectly reasonable behavior given the point of the preference.
3 Content bug. The products exhibiting the broken behavior are "turned inside out"; their primary facing direction is inwards, towards the interior, instead of outwards, towards the exterior, so the interior of the clothing is "primary" and the geometric facing will be towards the interior if you don't adjust the math as described previously. Thus the interior of the clothing draws correctly, but the exterior draws incorrectly if you don't enable Backface Lighting.
4 Daz Studio bug. If you enable Per-Pixel Shading, the setting of Backface Lighting is not respected, and the interior of polygons draw dark or black. So the OpenGL shader Daz is using doesn't do the math it needs to do, described in section 2. (It should probably ignore the setting and just always draw backface lighting correctly, really.)
Although the above bug cause (bad shader) is a guess, the fact that with per-pixel shading on, the interior of the clothing renders correctly but the exterior doesn't is a pretty big giveaway so I'm 95% sure that's the reason.