Does rF2 support edited normals?

Discussion in 'Car Modding' started by GTFREAK, Nov 1, 2012.

  1. GTFREAK

    GTFREAK Registered

    Joined:
    Mar 27, 2011
    Messages:
    340
    Likes Received:
    5
    I performed an experiment awhile back (when rFactor2 was still being developed/alpha stage) where I exported an object that had edited normals into the original rFactor and it worked. The edited normals were maintained.

    Is it the same with rF2? Do the edited normals remain in their edited state when exporting to rF2?

    Here is an explanation of what I am referring to...

    http://wiki.polycount.com/VertexNormal

    There are a couple of scripts that make this easier. More specifically, a script called "GetNormalsFromFace" handles this quite easily. The object needs to be an editable poly. You select the faces which you want edited and run the script, either manually or by hotkey.

    There are several benefits from using this. The most desirable of which is less polygons being used. Another is having a cleaner looking model with less shadow anomalies.

    Sims these days are able to handle a much higher poly count model, but that doesn't mean we should abuse it. Having a clean model with good polyflow is something every modeller should aspire to. Editing normals just makes thing a bit easier and cleaner and has been used in the industry for quite some time. However, as you can see in the wiki, there are only a handful of formats which can maintain the edited normals when exporting.
     
  2. Fabio Pittol

    Fabio Pittol Registered

    Joined:
    Oct 4, 2010
    Messages:
    274
    Likes Received:
    71
    Well, the GMT Exporter rollout lets you choose between MAX and gMotor Normals for and specific instance. So I guess it will work. A quick test could solve the question though.

    Judging by this insanely simple test, it works fine.
    [​IMG]
     
    Last edited by a moderator: Nov 1, 2012
  3. Luc Van Camp

    Luc Van Camp Track Team Staff Member

    Joined:
    Oct 4, 2010
    Messages:
    1,030
    Likes Received:
    15
    I strongly recommend using gMotor normals though, as Max normals will add extra trilists.
    The current Exporter has some more options for normals. Be sure to give them a go :) .
     
  4. GTFREAK

    GTFREAK Registered

    Joined:
    Mar 27, 2011
    Messages:
    340
    Likes Received:
    5
    Could you possibly explain what you mean by "trilists"? Are you saying it will add extra triangles? I've never seen that happen. Is it some form of tessellation?

    I forgot about the toggle between MAX normals and gMotor Normals. Thanks for reminding me. It's been awhile since I exported a model from MAX to rFactor.
     
  5. Luc Van Camp

    Luc Van Camp Track Team Staff Member

    Joined:
    Oct 4, 2010
    Messages:
    1,030
    Likes Received:
    15
    Extra triangles? No. Extra vertices; entire elements that could be processed in one time using gMotor normals that are split into multiple parts, which could have dramatic effects on performance depending on what you feed into the exporter.
     
  6. GTFREAK

    GTFREAK Registered

    Joined:
    Mar 27, 2011
    Messages:
    340
    Likes Received:
    5
    I see. While I have never seen that happen, I'll definitely look out for it. Every single model I have exported into rFactor has always been intact (No extra elements within an object - proven by re-importing into MAX). The only time I have seen separate elements within an object is when I have purposefully separated them or "split" the edges to create a transition.

    It sounds to me as if the exporter reads the normals and determines whether or not those faces should be separated into elements within an object based on their normals. So this new exporter has a way to edit normals in the same fashion as editing normals with MAX? If so, great!

    Do you happen to know what constraints are involved? Is it 45 degrees before it splits them? Is it 90 degrees before it splits them? is it over 90 degrees? For example, at what degrees does the exporter say "OK, this normal is too far out of whack when compared to the adjacent face, so I'm going to split you two up". That's actually quite funny. It's almost as if two kids are fighting and they need to be separated. Interesting. If that's not how it works, then forgive me. According to what I'm hearing, I believe this is how it works. Feel free to correct me.

    I'll check out the new exporter before I pass judgement, but so far I have not seen any adverse affects on my models using MAX normals.
     
    Last edited by a moderator: Nov 2, 2012
  7. Luc Van Camp

    Luc Van Camp Track Team Staff Member

    Joined:
    Oct 4, 2010
    Messages:
    1,030
    Likes Received:
    15
    Try exporting a mesh using both options and take note of the trilist count. I've always seen it explode when I last tried it.
     
  8. GTFREAK

    GTFREAK Registered

    Joined:
    Mar 27, 2011
    Messages:
    340
    Likes Received:
    5
    Just tried an export on my BODY_VA just as an experiment.

    Trilist for MAX Normals: 10
    Trilist for Gmotor Normals: 10

    Granted, this is with the original rFactor exporter, so I have no idea what it will do with the new exporter. I'll have to do some experiments with it to see. However, like I said, I have never seen extra elements be created when using MAX normals.
     
  9. Joe Campana

    Joe Campana Registered

    Joined:
    Jan 19, 2012
    Messages:
    129
    Likes Received:
    2
    The rF2 exporter supports the EditNormals modifier, you can edit individual normals one by one if you want. Export with this modifier on the stack and use Max normals to get the modified normals. As far as generating additional verts based on settings, the meshmender tolerances Tan and Bin can cause a lot of extraneous verts to be generated if you set either of these tolerances above 0.0 or so.
     
  10. GTFREAK

    GTFREAK Registered

    Joined:
    Mar 27, 2011
    Messages:
    340
    Likes Received:
    5
    I performed the same experiment using the rF2 exporter and indeed the trilist went from 10 to 23 and I can imagine how bad it would be for multiple objects. This was with Tan and Bin set to 0.0 both.

    This is quite strange because when using MAX normals for the original rFactor it remained the same. No extra Trilist were created. What changed?


    EDIT: Damnit, I read the post wrong.

    If I edit normals using the modifier, then collapse the stack, does "Gmotor normals" overwrite the edited normals? Or does it calculate it's own normals when exporting? I always thought that collapsing the stack was final and those changes would stick.

    EDIT 2: Just performed another experiment using both MAX Normals and Gmotor Normals and I believe I have encountered a bug or just an anomaly.

    I selected my car body and exported using Gmotor Normals and the Trilist was 10.

    I then re-selected my car body and exported using MAX normals and the trilist was 23.

    I then went back and added an "edit normals" modifier (without editing anything) and collapsed the stack. I then exported again using MAX normals and the trilist was back to 10. Every subsequent export after that always had a trilist of 10 using either MAX or Gmotor normals.

    This leads me to believe that if you never edit the normals (add a modifier and then collapse the stack / or leave the stack as-is) and then export using MAX normals, you will end up with a much higher trilist. As soon as you edit the normals and then export using either method, the trilist remains the same.

    Can you guys confirm this on your side? I'd like to know if this is just happening for me, or if this was intended.
     
    Last edited by a moderator: Nov 3, 2012
  11. Joe Campana

    Joe Campana Registered

    Joined:
    Jan 19, 2012
    Messages:
    129
    Likes Received:
    2
    Using gMotor normals will calculate and export new normals, but won't affect Max normals or any modifiers.

    Only Max normals w/ meshmender can change the number of vertex output, gMotor normals and alternate tangent basis will not change the number of vertex. I'll have test out this specific sequence of actions to see if this is a bug or not.
     
  12. GTFREAK

    GTFREAK Registered

    Joined:
    Mar 27, 2011
    Messages:
    340
    Likes Received:
    5
    That's interesting because I never checked "Meshmender" when I performed this experiment and got 23 in the Trilist. When you use MAX normals, is Meshmender on by default? The checkbox to use it was never checked for me. Just FYI.
     

Share This Page