The forum has been set to read-only mode. For community discussion and questions, head over to our Discord: https://discord.taleoftwowastelands.com

FNVLODGen

General mod discussion and requests.
Post Reply
User avatar
zilav
Gary
Posts: 225
Joined: Tue Apr 09, 2013 4:03 pm

Actually this is not what I

Post by zilav » Tue Mar 31, 2015 2:42 pm

Actually this is not what I need :)


Let me briefly describe you how Trees LOD system works in Fallouts (and Skyrim with some minor changes).


When you build trees LOD in GECK for a worldspace it collects all the references of TREE, STAT and ACTI objects with "Has Tree LOD" flag. Then it builds a list of unique "trees" from them and assigns an index starting from 0. Then for every tree it gets model filename, adds _lod_flat.nif suffix and opens that file. The only info needed for trees lod is width/height of that model, and min/max UV values, so a total of 6 float values.


This info is written in treetypes.lst file: tree index, width, height, U min, V min, U max, V max. Then *.dtl files are generated for cells blocks, they contain tree index, x, y, z position of tree and scale. The displayed atlas image for all trees is landscale\trees\treedeadlod.dds (treeswamplod.dds if worldspace name starts with 'DLC4', hardcoded in the engine).


So as you can see, those _lod_flat.nif files are just fakes only used for storing width, height of a tree in game units and UV position of it's image on atlas texture. They are *NOT* the actual models shown in game. That's why I got rid of them in TES5LODGen and get that info from txt files or just calculate from object bounds field. You can read more here


http://afkmods.iguanadons.net/index.php?/topic/4051-wipz-tes5lodgen-for-trees-lod/


But lets get to the point. Trees LOD isn't working properly in New Vegas. LOD trees randomly disappear when you approach them before full model is shown. It is very irritating and noticeable for large or semi large objects. Can be used probably only for bushes since they are small and hardly noticeable. The other downside of trees LOD is that only vertical trees can be shown in Trees LOD, they always have 0 rotation around X and Y axis (Z is random since they are just flat images). This is a hardcoded limitation. You can't have a lod for fallen trees or angled ones using Trees LOD system.


That's why I want to get rid of Tees LOD and generate lod for trees using Objects LOD system and real 3D models. This is how Obsidian did it with joshua and other trees in New Vegas.  So I need someone to get the actual trees models, make them low poly and reUV them to low resolution texture(s) without tiling since those textures will be put on a common atlas with other lod textures.



sesom
Posts: 464
Joined: Thu Sep 20, 2012 7:16 pm

I understood you correctly

Post by sesom » Tue Mar 31, 2015 3:57 pm

I understood you correctly zilav. That's why I wrote "!!object!! lod files"  (nifs to be more precise). I finish Tricky's door problem and then I get to it.



User avatar
zilav
Gary
Posts: 225
Joined: Tue Apr 09, 2013 4:03 pm

Thanks, will also need lod

Post by zilav » Tue Mar 31, 2015 5:09 pm

Thanks, will also need lod models for Point Lookout trees at some point. But dead trees should be enough to test for now.



User avatar
zilav
Gary
Posts: 225
Joined: Tue Apr 09, 2013 4:03 pm

Testing time!

Post by zilav » Fri Apr 03, 2015 7:22 pm

Testing time!


Download the latest dev version of TES5Edit and rename to FNVLODGen.exe


http://afkmods.iguanadons.net/index.php?/topic/3750-wipz-tes5edit/


You can specify -O:"c:\some\output folder" command line parameter to generate LOD files in designated folder if needed instead of Data (for MO users mostly). Run as admin, or put FNVLODGen in a folder where it has write access writes.


Remove "Trees LOD" in options, it requires billboards for trees anyway which are not provided for now.


LOD files are generated in those folders, you can rename "blocks" to "_blocks" for example in meshes to switch to vanilla LOD if needed (for comparison)


meshes\landscape\lod\<worldspace>\blocks\


textures\landscape\lod\<worldspace>\blocks\


Check for any bugs and oddities like missing, wrongly positioned, rotated, wrong textured etc. LOD objects in game.


The generated atlas for WastelandNV worldspace has about 80% free space, so there is plenty of space for higher resolution LOD textures or additonal LOD models as vanilla LOD is lacking in this regard. Sheson is currently trying to improve nv_rocks lod models.



User avatar
RoyBatty
Gary
Posts: 7742
Joined: Sun Apr 27, 2014 10:26 am
Location: Vault 108

Awwww yus! Going to test this

Post by RoyBatty » Fri Apr 03, 2015 7:45 pm

Awwww yus! Going to test this RIGHT NOW...


Thanks so much zilav, sheson and sesom too right?


 


Image

User avatar
zilav
Gary
Posts: 225
Joined: Tue Apr 09, 2013 4:03 pm

Oh forgot, install this also

Post by zilav » Fri Apr 03, 2015 7:52 pm

Oh forgot, install this also


https://drive.google.com/file/d/0B4rR0C-Bcx_JajJZUW5pTHk2dTQ/view?usp=sharing


it contains some renamed lod normal maps since originally TES5LODGen was made with assumption that normal maps always have the same name as diffuse with _n suffix like in Skyrim. Turned out this is not true for Fallouts, so I copied unmatched files with "correct" names. There are still some missing normals for DLC lod meshes though, FNVLODGen will report them so you can copy manually.



Gallahorn
Posts: 45
Joined: Sat Jul 26, 2014 10:37 am

Give screenshots of results

Post by Gallahorn » Fri Apr 03, 2015 7:52 pm

Give screenshots of results please.



User avatar
chucksteel
Posts: 1388
Joined: Wed Aug 15, 2012 3:20 pm

Haven't tested much but I ran

Post by chucksteel » Fri Apr 03, 2015 8:58 pm

Haven't tested much but I ran this on all of TTW and I have to say I am already quite impressed. places that would pop in do not anymore. 


Thanks can't wait to try it with the trees. 



User avatar
zilav
Gary
Posts: 225
Joined: Tue Apr 09, 2013 4:03 pm

I noticed that there are some

Post by zilav » Fri Apr 03, 2015 9:05 pm

I noticed that there are some LOD meshes included with the game, but their records don't have VWD flag and they are probably not in vanilla LOD, I think GECK doesn't included unflagged objects. I decided to ignore VWD flag completely, so now the only requirement for any object (STAT, SCOL and ACTI) to have lod is a presence of _lod.nif file with the same name as full model.



User avatar
chucksteel
Posts: 1388
Joined: Wed Aug 15, 2012 3:20 pm

The Monorail tracks in DC

Post by chucksteel » Fri Apr 03, 2015 9:17 pm

The Monorail tracks in DC have some funky LOD texture on them. 


Since you made the choice to ignore the VWD Flag should I download and run again? 



Post Reply