Jump to content

DynDOLOD 3.00 Alpha 180


sheson

Recommended Posts

52 minutes ago, sheson said:

The settings affect all (alpha) textures on the object LOD or tree LOD atlas.

1. is explained by reading the explanations above the setting. AlphaCoverage is used if texconv is used to generate mipmaps. AlphaFactor is used for the internal mipmap generation
2. AlphaCoverage = texconv command line argument -keepcoverage, AlphaFactor = factor used for internal alpha coverage algorithm.

Instead of changing these values here, I suggest to change the alpha threshold of the 3D tree LOD model.

https://dyndolod.info/Help/3D-Tree-LOD-Model
Note that LOD only has binary alpha with a fixed threshold of 128. DynDOLOD reads the alpha threshold from the NiAlphaProperty from the models used for LOD and adjusts the textures before it is added to the atlas texture. The final result in game may be to thick or thin like certain objects seem to be missing or transparency looks off. Try adjusting the NiAlphaProperty in the 3D LOD model. Again, note that the UV texture coordinates need to be >= 0.0 and <= 1.0 for LOD being able to use the atlas texture. If the UV is outside those limits, LOD will use the texture directly.

Thanks for the explanation.

Again, I did test AlphaCoverage=0.15 and 0.95 (default is 0.85) with TreeLODGenerateMipMaps=1 and saw no impact on any trees in object LOD (focusing on Aspens Ablaze though).

Basically, the mipmap alpha threshold in LOD is too low, I think, so I will try raising the NiAlphaProperty in the LOD crowns from 128 (current) to like 176 and test. Thank you.

As I mentioned, you might consider lowering AlphaFactor default value of 0.25, as I find that 0.125 works better for tree mods I have worked with recently (HLT, AA, EVT). Now this may not be the best baseline for other tree mods or tree types ... or vanilla. Just throwing the idea out there.

Link to comment
Share on other sites

57 minutes ago, z929669 said:

Thanks for the explanation.

Again, I did test AlphaCoverage=0.15 and 0.95 (default is 0.85) with TreeLODGenerateMipMaps=1 and saw no impact on any trees in object LOD (focusing on Aspens Ablaze though).

Basically, the mipmap alpha threshold is too low in LOD is too low, I think, so I will try raising the NiAlphaProperty in the LOD crowns from 128 (current) to like 176 and test. Thank you.

As I mentioned, you might consider lowering AlphaFactor default value of 0.25, as I find that 0.125 works better for tree mods I have worked with recently (HLT, AA, EVT). Now this may not be the best baseline for other tree mods or tree types ... or vanilla. Just throwing the idea out there.

Do not use texconv to generate mipmap for the LOD atlasses. It is the inferior method and will cause mipmap artifacts.

A tree LOD texture atlas for which the TreeLODGenerateMipMaps is used and only created when generating standard tree LOD.

Ultra tree LOD is LOD for trees done in object LOD, so the ObjectLODGenerateMipMaps applies.

The alpha threshold of LOD is fixed to 128 and can not be changed. As explained in the documentation, the alpha threshold from LOD models is used to adjust the texture of the first mipmap / largest resolution of the texture.

The mipmaps with lower resolution are derived from this adjusted texture and their alpha adjusted with the AlphaFactor. 0.25 (1/4) is the actual reduction of the resolution for each mipmap. It is the correct value. 3D tree LOD models (and any other other LOD model with alpha) included in DynDOLOD Resources SE expects this value. It also works correctly with the billboards added to the standard tree LOD atlas.

Adjusting the alpha threshold in the NIF is the documented method to control "thickness" of alpha textures for ultra tree LOD since many years.

  • Thanks 2
Link to comment
Share on other sites

5 hours ago, sheson said:

Do not use texconv to generate mipmap for the LOD atlasses. It is the inferior method and will cause mipmap artifacts.

A tree LOD texture atlas for which the TreeLODGenerateMipMaps is used and only created when generating standard tree LOD.

Ultra tree LOD is LOD for trees done in object LOD, so the ObjectLODGenerateMipMaps applies.

The alpha threshold of LOD is fixed to 128 and can not be changed. As explained in the documentation, the alpha threshold from LOD models is used to adjust the texture of the first mipmap / largest resolution of the texture.

The mipmaps with lower resolution are derived from this adjusted texture and their alpha adjusted with the AlphaFactor. 0.25 (1/4) is the actual reduction of the resolution for each mipmap. It is the correct value. 3D tree LOD models (and any other other LOD model with alpha) included in DynDOLOD Resources SE expects this value. It also works correctly with the billboards added to the standard tree LOD atlas.

Adjusting the alpha threshold in the NIF is the documented method to control "thickness" of alpha textures for ultra tree LOD since many years.

So in my and @DoubleYou's testing, we have found that NiAlphaProperty adjustments work, but only if the initial texture size is small enough. Beginning with a 4k texture, NiAlphaProperty as large as 224 has no visible impact. We had to extract the 256 mip (or resize the texture to 256) before we saw any impact on the resulting LOD alpha.

You will probably have your own ideas, but I assume texconv can extract the 512/256/128 mip level as the basis for applying the AlphaFactor and the resulting tree objects (maybe safer to just resize the top level in case the MA has made custom mips). Then the NiAlphaProperty has room to impact.

Link to comment
Share on other sites

7 hours ago, z929669 said:

So in my and @DoubleYou's testing, we have found that NiAlphaProperty adjustments work, but only if the initial texture size is small enough. Beginning with a 4k texture, NiAlphaProperty as large as 224 has no visible impact. We had to extract the 256 mip (or resize the texture to 256) before we saw any impact on the resulting LOD alpha.

You will probably have your own ideas, but I assume texconv can extract the 512/256/128 mip level as the basis for applying the AlphaFactor and the resulting tree objects (maybe safer to just resize the top level in case the MA has made custom mips). Then the NiAlphaProperty has room to impact.

Upload log and debug log and provide example files required to reproduce the problem.

Existing mipmaps in full textures are irrelevant and can not reliably be used - we learned that many years ago. The tools load the largest resolution of a textures, DynDOLOD applies the alpha threshold adjustment and the mipmaps are build from them. The alpha threshold adjustment should always be applied. The generated mipmaps should always have alpha-to-coverage applied. It's possible if a texture is too large there is an (automatic) resize step somewhere that forgets required alpha treatment.

Link to comment
Share on other sites

4 hours ago, sheson said:

Upload log and debug log and provide example files required to reproduce the problem.

Existing mipmaps in full textures are irrelevant and can not reliably be used - we learned that many years ago. The tools load the largest resolution of a textures, DynDOLOD applies the alpha threshold adjustment and the mipmaps are build from them. The alpha threshold adjustment should always be applied. The generated mipmaps should always have alpha-to-coverage applied. It's possible if a texture is too large there is an (automatic) resize step somewhere that forgets required alpha treatment.

I will need to regenerate a few times to get the logs, as they currently don't go back far enough. However, the trees in question are Aspen's Ablaze (using the Autumnal variety for test, but shouldn't matter) with my test LODs from Aspens Ablaze Add-On - DynDOLOD 3. Tests were as follows:

1. Full 4k texture with 128 NiAlphaProperty (default)

2. Full 4k texture with 224 NiAlphaProperty - no observable difference

3. Resized to 256 texture with 128 NiAlphaProperty - mostly same as 1

4. Resized to 256 texture with 224 NiAlphaProperty - way too thin

Currently the best ratio for this that I've found is resize to 128 with default NiAlphaProperty and Normal texture modified to remove alpha (fixes lighting and possibly even tint issues - not sure or not about what is causing the tint issues, but it significantly improved when I did this.).

 

Link to comment
Share on other sites

1 hour ago, DoubleYou said:

I will need to regenerate a few times to get the logs, as they currently don't go back far enough. However, the trees in question are Aspen's Ablaze (using the Autumnal variety for test, but shouldn't matter) with my test LODs from Aspens Ablaze Add-On - DynDOLOD 3. Tests were as follows:

1. Full 4k texture with 128 NiAlphaProperty (default)

2. Full 4k texture with 224 NiAlphaProperty - no observable difference

3. Resized to 256 texture with 128 NiAlphaProperty - mostly same as 1

4. Resized to 256 texture with 224 NiAlphaProperty - way too thin

Currently the best ratio for this that I've found is resize to 128 with default NiAlphaProperty and Normal texture modified to remove alpha (fixes lighting and possibly even tint issues - not sure or not about what is causing the tint issues, but it significantly improved when I did this.).

Only one session with a threshold that is not anywhere near 128 not having an affect on the texture on the object LOD atlas is required.

The texture in question is one of birch03_c.dds, birch03g_c.dds or birch03y_c.dds?

How do you check/compare the generated object LOD atlas texture and its mipmaps?

Normal map textures have no effect on diffuse alpha. The 4th channel of normal map textures is typically used for the specular map.

Link to comment
Share on other sites

Hi guys! I've generated LOD for skyrim, but trees look very bad in a far distance. When I come closer it become good quality, how can I do good quality for a log distance ? I used Happy little trees mod and Veydogolt trees which have Ultra 3d trees LOD.

 image.thumb.png.17f737c056b5195cabb3e76e1bca6180.png

My DynDOLOD settings which I used to generate LOD

image.thumb.png.c402976c52a592dd4d0d5808cd610205.png

Edited by KaktuZHD
Link to comment
Share on other sites

1 hour ago, KaktuZHD said:

Hi guys! I've generated LOD for skyrim, but trees look very bad in a far distance. When I come closer it become good quality, how can I do good quality for a log distance ? I used Happy little trees mod and Veydogolt trees which have Ultra 3d trees LOD.

 image.thumb.png.17f737c056b5195cabb3e76e1bca6180.png

My DynDOLOD settings which I used to generate LOD

image.thumb.png.c402976c52a592dd4d0d5808cd610205.png

Read the first post which log and debug log to upload when making posts.

The settings show you opted to use Billboard4 for the first LOD Level 4 for the "tree" mesh mask rule. Read https://dyndolod.info/Help/Ultra-Tree-LOD to learn how to generate LOD for trees with 3D tree LOD models and its requirements, e.g. download/create 3D tree LOD models and set LOD Level 4 to Level0 in order to use the 3D tree LOD models.

Link to comment
Share on other sites

6 hours ago, sheson said:

Only one session with a threshold that is not anywhere near 128 not having an affect on the texture on the object LOD atlas is required.

The texture in question is one of birch03_c.dds, birch03g_c.dds or birch03y_c.dds?

How do you check/compare the generated object LOD atlas texture and its mipmaps?

Normal map textures have no effect on diffuse alpha. The 4th channel of normal map textures is typically used for the specular map.

Texture in question are birch03_c.dds and birch03_n.dds.

Looking at texture in DynDOLOD output mod (not as many aspens as expected in the atlas) ..\textures\DynDOLOD\LOD (10 mip levels)

 

A couple things to note about Aspens Ablaze main mod:

  • It uses a diffuse with alpha opacity that seems to have custom mips to help achieve its look (4k)
  • It uses a custom normal likewise, and the normal also uses alpha opacity (rather than specularity in the alpha) (also 4k)
  • The NiAlphaProperty of all crown nodes is 128
  • We are testing with 'Autumnal' version (v2.35, no thickets or LOD from main mod)

Testing LOD versions:

  1. Reduced poly crowns with same crown NIF parameters as full (v0.1) - logs 0.1
  2. Reduced poly crowns (as in #1) with NiAlphaProperty=224 (v0.1) - logs 0.1-224
  3. Reduced poly crowns (as in #1) with same crown NIF parameters as full and pointing to 256 px LOD textures (diffuse just resized, normal with alpha romoved and then resized (v0.2 ) - logs 0.2
  4. Reduced poly crowns (as in #1) with NiAlphaProperty=224 and pointing to 256 px LOD textures (diffuse just resized, normal with alpha romoved and then resized (v0.2 ) - logs 0.2-224

Screens in same order as above:

0 aa Performance 0.1.jpg0 aa Performance 0.1-224.jpg0 aa Performance 0.2.jpg0 aa Performance 0.2-224.jpg

I think this demonstrates that lower texture resolution textures used in the crown LOD respond better to alpha scaling but adjustment of NiAlphaProperty threshold in the crown doesn't seem to have any impact. I doubt that the normal alpha plays a role. Textures are available in the download links above

 

EDIT: Interestingly, the BTO NIF properties for aspens are applied to non-aspen trees on the BTO (pines here), and they are really different in the full/LOD models:

image.pngimage.png

 

Link to comment
Share on other sites

57 minutes ago, z929669 said:

A couple things to note about Aspens Ablaze main mod:

  • It uses a diffuse with alpha opacity that seems to have custom mips to help achieve its look (4k)
  • It uses a custom normal likewise, and the normal also uses alpha opacity (rather than specularity in the alpha) (also 4k)
  • The NiAlphaProperty of all crown nodes is 128
  • We are testing with 'Autumnal' version (v2.35, no thickets or LOD from main mod)

Testing LOD versions:

  1. Reduced poly crowns with same crown NIF parameters as full (v0.1) - logs 0.1
  2. Reduced poly crowns (as in #1) with NiAlphaProperty=224 (v0.1) - logs 0.1-224
  3. Reduced poly crowns (as in #1) with same crown NIF parameters as full and pointing to 256 px LOD textures (diffuse just resized, normal with alpha romoved and then resized (v0.2 ) - logs 0.2
  4. Reduced poly crowns (as in #1) with NiAlphaProperty=224 and pointing to 256 px LOD textures (diffuse just resized, normal with alpha romoved and then resized (v0.2 ) - logs 0.2-224

Screens in same order as above:

0 aa Performance 0.1.jpg0 aa Performance 0.1-224.jpg0 aa Performance 0.2.jpg0 aa Performance 0.2-224.jpg

I think this demonstrates that lower texture resolution textures used in the crown LOD respond better to alpha scaling but adjustment of NiAlphaProperty threshold in the crown doesn't seem to have any impact. I doubt that the normal alpha plays a role. Textures are available in the download links above

There are differences between image #1 (left) and #2 and #3? #3 and #4 (right) seem close. Could the order be reversed? 

Which screenshot or LOD version is the one where you believe LOD matches the full trees best? Not what seems to look best in a still, what has the least noticeable switch between LOD / full model?

When you say diffuse just resize, how? Upload it. Normal map texture does not matter.

Link to comment
Share on other sites

1 hour ago, sheson said:

There are differences between image #1 (left) and #2 and #3? #3 and #4 (right) seem close. Could the order be reversed? 

Which screenshot or LOD version is the one where you believe LOD matches the full trees best? Not what seems to look best in a still, what has the least noticeable switch between LOD / full model?

When you say diffuse just resize, how? Upload it. Normal map texture does not matter.

Images are correct order. The differences you note in the screen are subtle (Obsidian Mountain Fogs can impact brightness in some places). In game, they are more apparent. Changing NiAlphaProperty in the second test did result in a small change to brightness, but alpha was still quite 'blotchy' in game. no apparent increase in transparency. Reduced resolution does increase transparency marginally, but NiAlphaProperty change in the final test had no visible impact at all.

Best transitions and LOD matching full is in last two screens, since last two tests use the 256 px textures (first two use 4K from main mod). The main issue is color-bleeding in branches/leaves due to alpha scaling. Full trees get slightly thinner in loaded cells as distance increases, and the same is true in LOD4 as distance increases.

I'm currently testing with diffuse at 128 px res. Will share result when finished.

Main mod textures

Reduced textures (open DDS, resize 4k to 256 in Ps, save using NVIDIA TT) - these LOD mod variants are also available for download from Nexus (linked previously)

image.png

Link to comment
Share on other sites

Just finished testing with 128k diffuse/normals resized with mipmaps @127 alpha test from original full textures used in AA main mod. Hopefully, you can see that the alpha transparency is best when the source textures used by DynDOLOD for these trees is 128:

I;m not showing changes in NiAlphaProperty, since it doesn't really have any impact. All are default AA values of 128 as full crowns.

4k  >>  256  >>  128

0 aa Performance 0.1.jpg0 aa Performance 0.2.jpg0 aa Performance 0.3.jpg

PS: You can see where full trees transition to LOD when switching between these screens. Full is obviously at bottom of screen nearest the PC. Most apparent alpha diff in LOD are those trees at lower right, which are obviously LOD trees.


For reference, this is an earlier screen I captured using the main mod AA textures (Autumnal Variety w/bigger treeaspen01-02) including normal with alpha opacity). Notice how the alpha is much too thick in LOD for these trees in comparison to lower res. I think this is apparent in the screens.

 

485868694_SkyrimSE2022-08-2321-20-57-12.jpg.b29d6c30c0222cf5db2cd557ab88ada7.jpg

All mesh rules used for all testing as follows:

[Skyrim aspensablazeesp]
LODGen1=cceejsse001-hstead.esm;08000BC2,Level0,Level1,Billboard4,Level2,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen2=cceejsse001-hstead.esm;08000BEB,Level0,Level1,Billboard4,Level2,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen3=cceejsse001-hstead.esm;08000B90,Level0,Level1,Billboard4,Level2,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen4=cceejsse001-hstead.esm;08000BD5,Level0,Level1,Billboard4,Level2,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen5=treeaspen05,Level0,None,None,None,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen6=treeaspen06,Level0,None,None,None,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen7=treeaspen07,Level0,None,None,None,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen8=treeaspen08,Level0,None,None,None,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen9=treeaspen09,Level0,None,None,None,FarLOD,Unchanged,1,Aspens Ablaze High Preset
LODGen10=treeaspen,Level0,Level1,Billboard4,Level2,FarLOD,Unchanged,1,Aspens Ablaze High Preset

 

Link to comment
Share on other sites

Asking here mostly 'cause I'm a lazy and impatient bastid so here goes...
As you can see from this image the NGIO-generated cached grass LOD has a lighter tint than the nearer grass.

20220826111015_1.thumb.jpg.46746bc7c20fd16adbc8db8d0ec51c14.jpg

The notes I can find about this say

Quote

In case the grass LOD brightness or color seems off (it might depend on weathers or ENB settings), try different Direct/Ambient settings for grass LOD billboards in TexGen. In addition or alternatively change the GrassBrightnessTop* and GrassBrightnessBottom* settings in ..\DynDOLOD\Edit Scripts\DynDOLOD\DynDOLOD_SSE.ini - those settings help if the color tone is off. Especially the image based lighting effect from ENB has a big impact on the brightness and color tone of the grass LOD.

I will guess that the DynDOLOD_SSE.ini settings are the way to go here, but how much to change them and in what direction?


These are my current settings (I believe they're default):

; grass LOD brightness multipliers
GrassBrightnessTopR=0.400
GrassBrightnessTopG=0.445
GrassBrightnessTopB=0.450
; make bottom darker to fake shadowing
GrassBrightnessBottomR=0.200
GrassBrightnessBottomG=0.223
GrassBrightnessBottomB=0.225

I know I can experiment with these but that is a tedious and time-consuming endeavor.
I'm hoping that you'll have a bit of insight to shortcut that process.

Other perhaps relevant info - Vivid Weathers, ENB .475 - Silent Horizons preset, Direct/Ambient settings for grass LOD billboards in TexGen are at default 160/25.

Thank you in advance for any advice you can offer.

Edited by Mephitic
Link to comment
Share on other sites

54 minutes ago, Mephitic said:

Asking here mostly 'cause I'm a lazy and impatient bastid so here goes...
As you can see from this image the NGIO-generated cached grass LOD has a lighter tint than the nearer grass.

20220826111015_1.thumb.jpg.46746bc7c20fd16adbc8db8d0ec51c14.jpg

The notes I can find about this say

I will guess that the DynDOLOD_SSE.ini settings are the way to go here, but how much to change them and in what direction?


These are my current settings (I believe they're default):


; grass LOD brightness multipliers
GrassBrightnessTopR=0.400
GrassBrightnessTopG=0.445
GrassBrightnessTopB=0.450
; make bottom darker to fake shadowing
GrassBrightnessBottomR=0.200
GrassBrightnessBottomG=0.223
GrassBrightnessBottomB=0.225

I know I can experiment with these but that is a tedious and time-consuming endeavor.
I'm hoping that you'll have a bit of insight to shortcut that process.

Other perhaps relevant info - Vivid Weathers, ENB .475 - Silent Horizons preset, Direct/Ambient settings for grass LOD billboards in TexGen are at default 160/25.

Thank you in advance for any advice you can offer.

Have a look at this post for a fairly fool-proof way to match grass LOD to full with almost any grass. The tint settings are mostly for edge cases or for non-linear ENB shader effects.

Link to comment
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
×
×
  • Create New...

Important Information

By using this site, you agree to our Guidelines, Privacy Policy, and Terms of Use.