Jump to content
Sign in to follow this  
arno

VTP maximum points

Recommended Posts

Our scenery team has almost finshed are VTP scenery (well, we still need to test it, but we have something that can run almost). We are solving the last crashes we get now and it seems that these crashes are caused by polygons with too many points. We are using the VTP method1 polygons and they cause a crash in FS when we have more then 24 points in them. We haven't got the extended point count working, anybody done this before? :).I searched the forum and couldn't find anything.While searching I found this quote of Dick:The first version of cellgrid was made before much was known about the behavior of VTP method1 polys. In FS2002, VTP method1 polys MUST have a full seasonal and night set of textures, or it will crash the sim. Simply assigning one texture doesn't work. This has been corrected in the latest version of cellgrid... by assigning the same texture name to each season and night:VTPTextureName "LOD8define.bmp;LOD8define.bmp;LOD8define.bmp;LOD8define.bmp;LOD8define.bmp;LOD8define.bmp"I can say that we use them with only one texture name and that seems to work fine, no crashes caused by that (I have checked that before I hit the point count).Arno


Member Netherlands 2000 Scenery Team[link:home.wanadoo.nl/arno.gerretsen]Arno's FlightSim World for scenery design hints, tips and other tricks...

Arno

If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done.

FSDeveloper.com | Former Microsoft FS MVP | Blog

Share this post


Link to post
Share on other sites

Hi Arno.The problem with cellgrid was due to the seasons in FS2002. I ( and others ) got crashes when I switched seasons or night in FS2002 without the full name set. CFS2 is fine with a single name, as it has no seasons. This crash doesn't always happen... and may be a "designer's bug".. like with autogen disappearing during the design process. I just bypassed the problem by including the seasonal variation names... which can all be the same name. A little typing avoided all the FS crashes... so I never looked into it more than that. I had discussed that point limit for VTP1 some time ago... I thought it was 23 points... but may well be 24.Christian Stock may have found an example, but I don't recall seeing a default VTP1 poly in either FS2002 or CFS2. CFS2 had several VTP1 "strips", which are their first attempt at lines. The lines would be unlikely to have more than 24 points. That would explain why the point limit "bug" was never found. I don't think it's a bug, but another case of the SDK not being correct.The idea of 63 being a switch to mark an extended form makes sense, as that is 111111 in binary. Supposedly, if the point count is 63, then you follow with an extra byte for extending the count.But 24 is 011000 in binary... and that makes no sense. I never found a reason for it. And I never found the key to using the extended form... but it might exist.Apparently you are using VTP1 so you can control the vertical flipping of textures... or need the texture orientation abilities of VTP1?The cure would be to split polys, or simplify them, so their point count is less than 25. And I would agree that is not the best solution, but I wouldn't know what else to do with it.Another odd thing with VTP1 I noted. If you entirely fill LOD13 Areas ( using 0-255 as the range limit ), and view the result in TMFViewer, you'll see the polys overlap each other, rather than butt each other. That overlapping could mean a "seam" problem when trying to butt textures over several LOD13 Areas. ( Haven't really tested it ). That indicates that the actual span might be 1-255, not 0-255. But would 1-255 introduce a thin line where textures don't quite touch? Maybe.EDITED Here:Another thought, regarding the crashing I had with FS using a singular texture name. Christian Fumey experienced a problem with 8-bit textures used in BGLs created with Ground2K. I wonder if the 8-bit mipped w/alpha texture I use with cellgrid is the cause of the random crashing with a singular texture name.Perhaps DXT1 doesn't have this problem.Dick

Share this post


Link to post
Share on other sites

Hi Dick,Yes, we also found crashes when we didn't have all textures in DXT1 format. Now we have them all in DXT1 it seems to work fine (but maybe it is still saver to add all names, just as some users might get the problem).About the points, I just got a mail from the guy programming our tool. He has already fixed it by splitting polygons that are bigger. It works really fine now he says. It's strange the the extended pointcount from the SDK doesn't seem to work, but now it is no problem anymore :-).I don't know exactly why he choose VTP1 instead of VTP2. I think it is because he already had to build in the polygon splitting etc for the LWM polygons and then wanted to use the same process for the VTP. Of course the texture flipping abbility is a nice option if you want some variation in the looks of the textures.Arno


Member Netherlands 2000 Scenery Team[link:home.wanadoo.nl/arno.gerretsen]Arno's FlightSim World for scenery design hints, tips and other tricks...

Arno

If the world should blow itself up, the last audible voice would be that of an expert saying it can't be done.

FSDeveloper.com | Former Microsoft FS MVP | Blog

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...