Skip to content

SQRT Domain Error (Toolset) Bug

symmetricsymmetric Member Posts: 57
A couple of people have been running into this problem in the toolset. It seems it is not yet fixed, so here is a way you can avoid it altogether:

This bug is caused by broken uv-maps. It happens when the uv-vertices of a face share the same coordinates, i.e. are degenerated into a point or a line:


This is a picture of the standard barrel placeable (plc_h07.mdl) in blender. As you can see, the underside of the barrel lid is not mapped correctly. A lot of the standard placeables have this problem.

If you try to use fancymapping (normal & specular mapping) on this it will explode in your face ;)



LaputianBirdSylvus_Moonbow

Comments

  • virusmanvirusman Member, Developer Posts: 173
    Does this crash the game too?
  • symmetricsymmetric Member Posts: 57
    No, it works fine in-game. It only affects the toolset.
  • ZwerkulesZwerkules Member Posts: 112
    Before 1.74 the sqrt error already occured when a face was degenerated into a line or a point even if there were no t-verts like on a walkmesh. The interesting thing is that it didn't do that for the original compiled models, but once you uncompiled them and worked on them you could get that sqrt error. There are a number of cylindrical placeables where whole "rings" of faces were reduced to lines.

    That this also happens when it is just the t-verts of faces is new however.
    symmetric
  • LaputianBirdLaputianBird Member Posts: 107
    edited March 2018
    I think the compiler might be splitting tverts upon compilation. That might explain why stock models don't trigger the issue, as they are mostly compiled files.

    However, I find degenerated "tverts faces" to be a legitimate thing, unlike degenerated geometry faces. I think the engine should be made able to handle them, instead of having to enforce constraints on the mapping
    Zwerkules
  • symmetricsymmetric Member Posts: 57
    Just to be clear: That error only occurs with enabled normal maps, i.e. when adding "renderhint NormalAndSpecMapped". It works fine otherwise.
Sign In or Register to comment.