Jump to content
  • 0

Tree LOD Shaders


doodlum

Question

I made a shader modification for tree LOD where I'm currently happy with the results. Because lighting is simulated through normal maps, it would need DynDOLOD to support it by adding a config to check for what worldspaces use the format, and drawing out normals to the bottom of the atlas. There's an additional mask in the alpha channel available which is unused. Additionally the atlas could be tiled further for additional masks.

Only the texture coordinate is available for unique information about the current pixel. The vanilla shader is so stripped down there is only that. Additional information is provided through RE plus generated normals and tangents.

https://www.nexusmods.com/skyrimspecialedition/images/182805

I don't really know how good of an option this is. If it's a bad idea or just won't be supported then I'll drop this. It should theoretically be beneficial in bottlenecked situations over object LOD, and can be tweaked specifically for flora 

 

Link to comment
Share on other sites

Recommended Posts

  • 0

Awesome!

One thing with that page is that it doesn't reference complex grass support from community shaders. It should make clear anything ENB does, community shaders does too.

With grass I actually use vanilla lighting code where the soft lighting/backlighting color is the diffuse. So for grass LOD it might be able to match almost perfectly. If there's an easy way for me to detect grass LOD I could also just inject separate lighting code.

Link to comment
Share on other sites

  • 0

I haven't had time to test anything with the community shader yet. Need to do that first before I can write anything about it :)

The grass LOD shapes in the BTOs will always have a name starting with "grass". If the name can not be used we could probably use unique shader settings/ flags that are not used by object LOD.

Object LOD does support soft lighting and backlighting though. So just using a billboard NIF that sets those in this case might be all that is needed. Give me some time to look into it.

Link to comment
Share on other sites

  • 0

Object LOD does not support using SoftLighting and BackLighting at the same time. It results in the sky blue textures.

Download this test version https://mega.nz/file/hIoAxYLD#OvXQj44oyHB5lpAzsUA8McuXagNxtn3_buOVJFwsfPo or latest Alp[ha

Set ForceComplexGrass=2 in ..\DynDOLOD\Edit Scripts\DynDOLOD\TexGen_SSE.INI to always generate normal map textures for grass LOD billboards regardless if complex textures are installed or not.

Set ComplexGrassBillboard=6 in ..\DynDOLOD\Edit Scripts\DynDOLOD\DynDOLOD_SSE.ini to select DynDOLOD_flat_4x2alt3_lod.nif for grass LOD generation, which sets both SoftLighting and BackLighting flags and assigns the diffuse to be used for the corresponding texture slots.

Then generate grass LOD as usual. You can edit the DynDOLOD_flat_4x2alt3_lod.nif if necessary to make changes and just Execute LODGen to update a specific (specific chunk drop down to 4 and W/S = cell coordinates from filename) or all BTOs in expert mode https://dyndolod.info/Help/Expert-Mode

In case you do not want to generate grass LOD for yourself right now, download this archive https://mega.nz/file/YRRjVDIJ#APeAe1_ot8Nj_zodmxo8O5K1-BBBgsDkL3TpsAw7ViE which contains object LOD level 4 meshes and the texture atlases for vanilla game/grass that above settings generate.
Make sure to check the current shader settings for the grass LOD in one of the BTOs.
If just adding support both options to the object LOD shader is enough to make it match visually, it does not need to be limited to the grass shapes only. Right now this particular combination of shader flags would be unique for grass LOD for the community shader.

You can edit anything in the BTO for testing to whatever you might need. I can update the tools to create whatever accordingly.

If this requires or can be done with a double sided version instead of 4 sides, let me know.

Link to comment
Share on other sites

  • 0

Now there's a thought. Put grass lod in tree LOD and ultra trees in 3d lod. Only problem would be enb compatibility. But you could basically treat grass lod separately so that you wouldn't hurt performance of object lod, setting the grass distance via fTreeLoadDistance and shortening fBlockLevel0Distance. 

Link to comment
Share on other sites

  • 0

Read https://dyndolod.info/Help/Tree-LOD#Limitations. The inability to angle the billboards with the terrain would look simply silly in addition to obvious change when full grass loads.

Tree LOD also can not support the individual brightness change of each grass placement.

Never mind the single side billboard texture.

Each placement requires a unique reference form ID without load order ID to unload.

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
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

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