1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

P3D v4 Ground Poly Offset

Discussion in 'ModelConverterX' started by mdm248111, 19 Jun 2017.

  1. mdm248111

    mdm248111

    Joined:
    17 Feb 2009
    Messages:
    1,269
    Country:
    us-northcarolina
    Gents,

    Converting some current work from FSX to P3D. Using the same Afcad file and Ground poly coordinates, I am for some reason noticing that in P3D the poly seems to be offset. This happens regardless of whether the "Optimize Reference Point" box is checked or not. Everything appears to be offset by about 3-5 feet northeast-ish.

    Anybody else having this same issue or is it a known P3D bug?

    [​IMG]

    Thanks.
     
  2. arno

    arno Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    28 May 2004
    Messages:
    24,826
    Country:
    netherlands
    Do you use the same bgl in both or did you recompile in the GPW?

    Although I don't see how that should matter, since the round earth correction is the same.
     
  3. mdm248111

    mdm248111

    Joined:
    17 Feb 2009
    Messages:
    1,269
    Country:
    us-northcarolina
    I've tried doing both, with the same results each time.
     
  4. jonmkj

    jonmkj

    Joined:
    10 Feb 2007
    Messages:
    697
    Country:
    us-northcarolina
    Just to add, when putting the FSX version directly into P3D, it isn't offset. It becomes shifted only after applying the z-bias settings per the P3D SDK. The shift is present in both V3 and V4.
     
  5. arno

    arno Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    28 May 2004
    Messages:
    24,826
    Country:
    netherlands
    Are you using the latest MCX build? I fixed a bug last week that could cause an upwards shift of the polygons.
     
  6. jonmkj

    jonmkj

    Joined:
    10 Feb 2007
    Messages:
    697
    Country:
    us-northcarolina
    I don't think we are actually. We will update and try again. If by upward you mean vertically though, we aren't seeing any of that, rather it's being shifted to the side.
     
  7. arno

    arno Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    28 May 2004
    Messages:
    24,826
    Country:
    netherlands
    I have no clue why it would be shifted. Are you comparing with photo scenery or the ADE airport?
     
  8. mdm248111

    mdm248111

    Joined:
    17 Feb 2009
    Messages:
    1,269
    Country:
    us-northcarolina
    Exporting with the latest MCX release does not fix it. I am comparing it with the ADE airport. I have traced the ground poly using ADE/SimConnect in FSX to prevent any overlap, and it works perfectly in FSX. Export the same .x to P3D using the same coordinates and same ADE file results in a poly shift.
     
  9. arno

    arno Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    28 May 2004
    Messages:
    24,826
    Country:
    netherlands
    Maybe you can check which of the two shifted by measuring some coordinates in P3D?
     
  10. mdm248111

    mdm248111

    Joined:
    17 Feb 2009
    Messages:
    1,269
    Country:
    us-northcarolina
    It is certainly the GP that has moved.

    [​IMG]
     
  11. arno

    arno Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    28 May 2004
    Messages:
    24,826
    Country:
    netherlands
    If you measure the same GP corner in FSX you get a different coordinate you mean?

    Especially if this also happens with the same BGL file loaded, it seems to indicate the P3D does some changing to the polygons before rendering...
     
  12. mdm248111

    mdm248111

    Joined:
    17 Feb 2009
    Messages:
    1,269
    Country:
    us-northcarolina
    The position for the bottom left corner of the hard surface in ADE matches the corner of the hard surface in P3D. The concrete apron is just being used to make the surface hard beneath the GP, not for any decorative purposes. Normally, the GP will cover it completely.

    Unfortunately, the coordinates of P3D aren't precise enough to let me make a direct comparison, but using the coordinates within ADE/SimConnect, it is obvious that it doesn't match. If I recall correctly, @jonmkj was saying that this had occurred at another airport in development as well.

    Edit 1: After posting, I understand what you were actually asking. Here are the actual coordinates of the southwestern corner of the GP runway. Not "exact" but about as close as you can ask for.

    FSX: 36.760326657 -80.823611509
    P34: 36.760334871 -80.823600967

    Est. Difference: -0.00000821399 -0.000010542

    Using this convertor, it tells me that it shifted about 4.29 feet at a direction of 314.264°.

    I disagree with the direction given since it is clearly shifted north-east not north-west from FSX to P34, however I do believe the distance looks quite reasonable. In addition, this shift seems reasonable for the entire GP, which leads me to believe that there is not any stretching/shrinking of the poly.

    Edit 2: I decided to apply those corrections to the GP reference coordinate to see if I could shift it just enough. to make it work but just realized that I had missed a decimal place somewhere. Gotta run for now, but I will make the correct shift later tonight and give an update.
     
    Last edited: 20 Jun 2017
  13. mdm248111

    mdm248111

    Joined:
    17 Feb 2009
    Messages:
    1,269
    Country:
    us-northcarolina
    Update.

    Did the math correctly and offset the GP ref point by those values listed above. Everything seems to be aligned properly. I'm content with this workaround for now, but am certainly curious to see if it occurs for all P3x GP's and, if so, by how much.
     
  14. jonmkj

    jonmkj

    Joined:
    10 Feb 2007
    Messages:
    697
    Country:
    us-northcarolina
    We figured it out! Not sure why, but disabling DRAW CALL BATCHING solves the problem, and a heap of other issues as well!
     
  15. arno

    arno Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    28 May 2004
    Messages:
    24,826
    Country:
    netherlands
    Ah, that's something I could implement in the GPW. For ground polygons I doubt the batching has much effect anyway.
     
  16. jonmkj

    jonmkj

    Joined:
    10 Feb 2007
    Messages:
    697
    Country:
    us-northcarolina
    I read that it's a known bug with draw call batching to offset objects at higher altitude, in this case over 2,300 ft elevation. Turning it off in MCX settings solved that and some other issues we've had such as flickering and transparency problems.
     
  17. arno

    arno Administrator Staff Member FSDevConf team Resource contributor

    Joined:
    28 May 2004
    Messages:
    24,826
    Country:
    netherlands
    Yes, now that you mention it. I wasn't aware that your airport was at higher altitude.
     
  18. jonmkj

    jonmkj

    Joined:
    10 Feb 2007
    Messages:
    697
    Country:
    us-northcarolina
    another benefit of disabling DCB is that we don't have to use the alpha testing on our fences that make them shimmer and disappear in the distance. We're fairly efficient in the way we model and try to build everything into one scene.

    Also Arno, we placed our grass as six different types of model over and over on the airport. I know MCX can build a scene from multiple BGLs but is there a way to take all of those individually placed MDLs and combine them into one?
     
  19. tgibson

    tgibson

    Joined:
    22 Sep 2006
    Messages:
    6,954
    Country:
    us-california
    Hi,

    Wouldn't it be more efficient to create the MDL files as library objects and place the *same* MDL file over and over again?
     
  20. jonmkj

    jonmkj

    Joined:
    10 Feb 2007
    Messages:
    697
    Country:
    us-northcarolina
    Well, that's how we did it... am I wrong in thinking it would be more efficient for the simulator to handle one big object rather than a hundred of them?