User Tag List

Page 1 of 5 123 ... LastLast
Results 1 to 40 of 176

Thread: Nature Environment in UE4

  1. #1
    0
    Luminary

    Join Date
    Mar 2014
    Posts
    1,977

    Exclamation Nature Environment in UE4

    UPDATE
    New shading model for foliage has been added in 4.7 version of Unreal Engine, so complaints in original post are no more valid.
    Foliage shading model is awesome, check out Koola work for example




    My thread in feedback is ignored, but I think this issure should be addressed.
    It's not some minor issue
    Due to the absence of proper lighting model for 2-sided foliage it's impossible to create good foliage, grass or whatever, no matter how you will setup your material.
    The current workaround - using diffuse texture wired with sunlight parameter connected to emissive light output plus ss lighting model, but this is so NOT next-gen =_=
    I can't understand how so basic thing keep being ignored
    Few examples from UE3 and UE4 for you to feel the difference:
    Unreal Engine 3
    Name:  YzRFy.jpg
Views: 47446
Size:  260.6 KB Name:  damian_lazarski_3dmotive_foliage_for_udk_1.jpg
Views: 39299
Size:  361.9 KB
    Unreal Engine 4 from Epic Demos
    Name:  foliage_.jpg
Views: 33981
Size:  101.2 KB

    Maybe I'm not aware of some super duper way to shade your grass, maybe I overlooked something - that's why I'm posting this in Content Creation and not in feedback
    Last edited by zeOrb; 03-21-2015 at 03:43 AM.

  2. #2
    0
    It's well known issue. There are some "workarounds" but don't expect they will provide you with plausible results.

    First you can use emissive to uniformly lit you grass.

    https://answers.unrealengine.com/questions/11949/request-foliage-lighting.html

    Here are also some work arounds.

    In other words, you are absolutely right. We just need proper forward rendering path, to properly lit foliage. On stream about rendering, they said they will be evaluating various forward rendering techniques over next few months, to add to engine. So we can just wait for now.

  3. #3
    0
    Quote Originally Posted by zeOrb View Post
    My thread in feedback is ignored, but I think this issure should be addressed.
    It's not some minor issue
    Due to the absence of proper lighting model for 2-sided foliage it's impossible to create good foliage, grass or whatever, no matter how you will setup your material.
    The current workaround - using diffuse texture wired with sunlight parameter connected to emissive light output plus ss lighting model, but this is so NOT next-gen =_=
    I can't understand how so basic thing keep being ignored
    Few examples from UE3 and UE4 for you to feel the difference:
    Unreal Engine 3
    Name:  YzRFy.jpg
Views: 47446
Size:  260.6 KB Name:  damian_lazarski_3dmotive_foliage_for_udk_1.jpg
Views: 39299
Size:  361.9 KB
    Unreal Engine 4 from Epic Demos
    Attachment 1032 Name:  foliage_.jpg
Views: 33981
Size:  101.2 KB

    Maybe I'm not aware of some super duper way to shade your grass, maybe I overlooked something - that's why I'm posting this in Content Creation and not in feedback
    Pic 3 is a real photo I think...

  4. #4
    0
    Luminary

    Join Date
    Mar 2014
    Posts
    1,977
    Quote Originally Posted by Errvald View Post
    Pic 3 is a real photo I think...
    Hah, well, maybe I'm overcritizing then But still, I think idea is pretty clear

  5. #5
    0
    I use edit normals + sss(distance blending) + fresnel shading for my foliage

    final grass shader:
    https://www.dropbox.com/s/fvu7e1mb7rkuttv/grass_lighting.jpg

    360° lighting
    https://www.dropbox.com/s/l3vebdyg6ocqpig/grass_shading1.jpg

  6. #6
    0
    Quote Originally Posted by Ulrich.Thümmler View Post
    I use edit normals + sss(distance blending) + fresnel shading for my foliage

    final grass shader:
    https://www.dropbox.com/s/fvu7e1mb7rkuttv/grass_lighting.jpg

    360° lighting
    https://www.dropbox.com/s/l3vebdyg6ocqpig/grass_shading1.jpg
    Man, this is AMAZING!!! Such a beautiful grass!

  7. #7
    0
    Quote Originally Posted by Ulrich.Thümmler View Post
    I use edit normals + sss(distance blending) + fresnel shading for my foliage

    final grass shader:
    https://www.dropbox.com/s/fvu7e1mb7rkuttv/grass_lighting.jpg

    360° lighting
    https://www.dropbox.com/s/l3vebdyg6ocqpig/grass_shading1.jpg
    Wow. That's beautiful work. Have you considered adding tutorials to your blog for UE4?

  8. #8
    0
    Looks fantastic!, great work.

  9. #9
    0
    Samaritan
    Join Date
    Mar 2014
    Posts
    106
    Quote Originally Posted by Errvald View Post
    Pic 3 is a real photo I think...
    Indeed it is. http://www.forwallpaper.com/wallpaper/mountain-valley-544948.html

    Not sure why it was claimed to be from Unreal 4?

  10. #10
    0
    Luminary

    Join Date
    Mar 2014
    Posts
    1,977
    Quote Originally Posted by Ulrich.Thümmler View Post
    I use edit normals + sss(distance blending) + fresnel shading for my foliage

    final grass shader:
    https://www.dropbox.com/s/fvu7e1mb7rkuttv/grass_lighting.jpg

    360° lighting
    https://www.dropbox.com/s/l3vebdyg6ocqpig/grass_shading1.jpg
    Bravo, sir! Looks excellent!
    How do you utilize fresnel?
    Quote Originally Posted by Joviex View Post
    Indeed it is. http://www.forwallpaper.com/wallpaper/mountain-valley-544948.html

    Not sure why it was claimed to be from Unreal 4?
    Someone posted this photo, claiming UE4 and my perverted brain said something like: HM, THIS GRASS LOOKS BAD. IN OTHER DEMO GRASS LOOKS BAD TOO. NOTHING ELSE DOESN'T MATTER!

  11. #11
    0
    Quote Originally Posted by Ulrich.Thümmler View Post
    I use edit normals + sss(distance blending) + fresnel shading for my foliage

    final grass shader:
    https://www.dropbox.com/s/fvu7e1mb7rkuttv/grass_lighting.jpg

    360° lighting
    https://www.dropbox.com/s/l3vebdyg6ocqpig/grass_shading1.jpg
    @Ulrich: Would be lovely if you could share the shader setup for the grass - it does look very good!

    Cheers,
    Michael

  12. #12
    0
    Samaritan
    Join Date
    Mar 2014
    Posts
    102
    Quote Originally Posted by Ulrich.Thümmler View Post
    I use edit normals + sss(distance blending) + fresnel shading for my foliage

    final grass shader:
    https://www.dropbox.com/s/fvu7e1mb7rkuttv/grass_lighting.jpg

    360° lighting
    https://www.dropbox.com/s/l3vebdyg6ocqpig/grass_shading1.jpg
    That looks amazing! As others have asked, is it possible to have you share your magic?

  13. #13
    0
    Infiltrator
    Join Date
    Apr 2014
    Posts
    18
    @_@Ulrich would love to see the shader setup or maybe a tutorial on how you made this grass.. looks really nice and I am trying to make a foliage map as well

  14. #14
    0
    thx guys

    here a short break down(is from ue4 beta):

    1. Use Edit normals to create custom normals for your mesh.
    http://wiki.polycount.com/VertexNormal

    2. When u import the texture with alpha mask, check the "DitherMipMapAlpha" is true.

    3. Here the basic MatTree():
    https://www.dropbox.com/s/mndlu7w6dshayen/grass_shader_setup_base.jpg
    Blend Mode: Masked
    Lighting Model: Subsurface
    Two Sided: true

    For the gradient textures use a simple TexCoordinate with ComponentMask.

    I use in my shader alpha mask distance filling. The mask is no pixelated and flickering in the distance.
    Here my MatTree:
    https://www.dropbox.com/s/nfnjtskpbz2tia8/mat_tree_multi.jpg

    The SSS is very hardware hungry i use the distance blending for better performance.
    http://oliverm-h.blogspot.de/2012/06/distance-based-texture-blending-ue3udk.html

    Use the Opacity Slot for SSS transparently.

    4. Create a custom Wind Shader with high z vector offset.
    Here my custom wind shader(i use it for all(weather, trees, ocean, flaggs etc.)):
    https://www.dropbox.com/s/zkonxpg08farbmd/Wind_Shader.mov
    Here the animate texture:
    https://www.dropbox.com/s/pm8bmddke2n8aqy/dynamic_wind.mp4
    the final texture has 32px x 32px resolution


    Hope this was helpful, sry for my bad english. :P

    greeting,
    Ulrich

  15. #15
    0
    Samaritan
    Join Date
    Mar 2014
    Posts
    102
    Thank you a lot for sharing Ulrich will try this later (and your English is just fine).

  16. #16
    0
    Infiltrator
    Join Date
    Apr 2014
    Posts
    18
    Awesome, Thank you for the information, this will help a lot. Distance blending is a really good idea for terrain and foliage!

  17. #17
    0
    Thanks for the specifics. Your work with Unreal materials is so good I'm surprised Epic hasn't snatched you up yet!

    Cheers,
    -D

  18. #18
    0
    Quote Originally Posted by Ulrich.Thümmler View Post
    thx guys

    here a short break down(is from ue4 beta):

    1. Use Edit normals to create custom normals for your mesh.
    http://wiki.polycount.com/VertexNormal

    2. When u import the texture with alpha mask, check the "DitherMipMapAlpha" is true.

    3. Here the basic MatTree():
    https://www.dropbox.com/s/mndlu7w6dshayen/grass_shader_setup_base.jpg
    Blend Mode: Masked
    Lighting Model: Subsurface
    Two Sided: true

    For the gradient textures use a simple TexCoordinate with ComponentMask.

    I use in my shader alpha mask distance filling. The mask is no pixelated and flickering in the distance.
    Here my MatTree:
    https://www.dropbox.com/s/nfnjtskpbz2tia8/mat_tree_multi.jpg

    The SSS is very hardware hungry i use the distance blending for better performance.
    http://oliverm-h.blogspot.de/2012/06/distance-based-texture-blending-ue3udk.html

    Use the Opacity Slot for SSS transparently.

    4. Create a custom Wind Shader with high z vector offset.
    Here my custom wind shader(i use it for all(weather, trees, ocean, flaggs etc.)):
    https://www.dropbox.com/s/zkonxpg08farbmd/Wind_Shader.mov
    Here the animate texture:
    https://www.dropbox.com/s/pm8bmddke2n8aqy/dynamic_wind.mp4
    the final texture has 32px x 32px resolution


    Hope this was helpful, sry for my bad english. :P

    greeting,
    Ulrich

    Wow that is beautiful. The wind effect is incredible. The darkening and lightening as the random wind waves move the grass. Wonderful.

    Is there a tutorial for UE4 on how to make custom wind shaders like yours? How to make the animate texture?

    Thank you for sharing. That is better than any grass I have ever seen in any game. I mean it. The wind effect is glorious.

  19. #19
    0
    Ulrich, you are my new favourite person ever.

    Love your work.

  20. #20
    0
    Ulrich, how exactly do you use the Edit Normals modifier to average the normals? Is there an automatic way to do it?

  21. #21
    0
    @Jamsh all you really need to know is here : http://docs.autodesk.com/3DSMAX/16/ENU/3ds-Max-Help/index.html?url=files/GUID-82722323-100B-4711-A01D-8A87EB53DD96.htm,topicNumber=d30e234498

    Also you can find a custom script by google searching that does your bidding :P
    VFX Artist
    Portfolio: Here

  22. #22
    0
    Quote Originally Posted by TheJamsh View Post
    Ulrich, how exactly do you use the Edit Normals modifier to average the normals? Is there an automatic way to do it?
    I think he also uses SlideNormalThief -> you can copy the normals from another mesh to your target mesh

  23. #23
    0
    My result didn't turn out as well And for some reason, my foliage isn't shaded/darkened by the surrounding geometry. Notice how it's equally bright through the level rather than being darker in the shadowed areas. This occurs wether I use a static, stationary or moveable directional light.

    Is there anything I'm doing particularly wrong? I used the exact same material setup as Ulrich for now. My vertex normals are all pointing straight up too.



    I think a lot of Ulrich's magic is also done with how he made his meshes. Ulrich did you create your own backfaces rather than using a 2-sided material and use those normals, and are they flat planes or actual geometry with depth?
    Last edited by TheJamsh; 05-07-2014 at 06:09 PM.

  24. #24
    0
    Quote Originally Posted by TheJamsh View Post
    My result didn't turn out as well And for some reason, my foliage isn't shaded/darkened by the surrounding geometry. Notice how it's equally bright through the level rather than being darker in the shadowed areas. This occurs wether I use a static, stationary or moveable directional light.

    Is there anything I'm doing particularly wrong? I used the exact same material setup as Ulrich for now. My vertex normals are all pointing straight up too.
    Are you using static lighting? Foliage doesnt work well with static lighting currently as far as i know.

  25. #25
    0
    I know that it only casts dynamic shadows, but changing my light source settings doesn't seem to change anything... must have missed something somewhere. Even so, that shouldn't effect the shadowing from the surrounding geometry should it? I'm still not entirely sure how the foliage system works. Might be better to use static meshes for the mean time. That's going to be a lotta lightmaps though :/

  26. #26
    0
    Lightmaps are the least of your problem if you place them as staticmeshes. UE3 foliage was lightmapped as well. Never was a big issue.

    Drawcalls on the other hand.... The prime reason to use foliage over manually placed meshes are the drawcalls.

    You must have something in your material that makes them this bright. Try to add a very simple grass material to the mesh just to narrow that if it is indeed the material, or something else.

  27. #27
    0
    Using an identical setup to Ulrich here, I even darkened the colours to no avail, the lighting still doesn't affect the grass.



    The meshes are simple planes with a few extra verts and all normals facing up. Ulrich's meshes must be doing something different surely... are you guys actually getting shadowed foliage at all?

  28. #28
    0
    Samaritan
    Join Date
    Mar 2014
    Posts
    102
    Bumping this.

  29. #29
    0
    Quote Originally Posted by TheJamsh View Post
    Using an identical setup to Ulrich here, I even darkened the colours to no avail, the lighting still doesn't affect the grass.


    The meshes are simple planes with a few extra verts and all normals facing up. Ulrich's meshes must be doing something different surely... are you guys actually getting shadowed foliage at all?
    Have you placed those meshes with the foliage tool? When yes, then enable moveable in your directional light

  30. #30
    0
    Yep I did that, still no luck I had to seriously multiply the colour down too, so now it looks too dark all round.

  31. #31
    0
    Quote Originally Posted by TheJamsh View Post
    My vertex normals are all pointing straight up too.
    What exactly do you mean by that? Wouldn't it be a pretty good reason for your shading being messed up when all normals are pointing to the sky?

  32. #32
    0
    Luminary

    Join Date
    Mar 2014
    Posts
    1,977
    Quote Originally Posted by TheJamsh View Post
    Using an identical setup to Ulrich here, I even darkened the colours to no avail, the lighting still doesn't affect the grass.



    The meshes are simple planes with a few extra verts and all normals facing up. Ulrich's meshes must be doing something different surely... are you guys actually getting shadowed foliage at all?
    Probably they should not face just up.

    Look at second picture - 100% dark on polys that looks down and in your case you get 100% bright polys, when they look just up.

  33. #33
    0
    here a basic shader without edit normals:

    old
    https://www.dropbox.com/s/0tywrbrbm7mkhnn/grass_shading.jpg

    mirror[old]:
    http://www.fotos-hochladen.net/uploads/grassshadingce6l2qsr1j.jpg

    @Edit:
    fixing shadow
    Last edited by Ulrich.Thümmler; 05-29-2014 at 08:42 PM.

  34. #34
    0
    Veteran
    Join Date
    Mar 2014
    Posts
    454
    Looking good!

    Is there any way you can help explain your wind shader a bit more? My "wind" shader feels more like an underwater current (if that current was having a seizure).

    Do you paint weights on the grass?

  35. #35

  36. #36

  37. #37
    0
    Thanks Ulrich. It does actually appear to be working in a new level. My current level has quite a lot of lighting so perhaps a rebuild will help the problem.

    Just a shame it's so expensive to use SSS on foliage

  38. #38
    0
    Quote Originally Posted by Daerst View Post
    What exactly do you mean by that? Wouldn't it be a pretty good reason for your shading being messed up when all normals are pointing to the sky?
    Nope, see Ulrich's first post about editing the mesh normals. The idea is to have uniform shading across all of your grass, rather than have normals on the planes that face away from each other.

    Quote Originally Posted by zeOrb View Post
    Probably they should not face just up.
    Look at second picture - 100% dark on polys that looks down and in your case you get 100% bright polys, when they look just up.
    Again, that's for a single tree object. On a grass plane, you want them to all face the same way, as the grass is supposed to be one huge object, not a collection of small objects. A quick lighting re-build seems to have fixed my problem, bit odd though.
    Last edited by TheJamsh; 06-01-2014 at 07:54 AM.

  39. #39
    0
    Supporter
    Join Date
    Jun 2014
    Posts
    1
    hey guys, will ulrich's method work for something like this:

    http://i.imgur.com/4rp9hJR.jpg

    It's a screengrab from Tera. My team might be looking into making something like that for our project. We wanted to go PBR but with the theme we have in mind, foliage is unavoidable. From what I've been hearing, you can't make good proper foliage in PBR for UE4 yet. But Ulrich seems to have come up with something, but it's applied to grass, will it work the same way for other plants?
    Attached Images Attached Images  

  40. #40
    0
    ok another way without Edit Normals and SSS Shading is, to deactivate the Tanget Space Normal and add 128.128.255 Color to Normal Slot.

    https://www.dropbox.com/s/qd3zpxf2lv9nwim/FoliageShading_without_SSS.jpg



    Quote Originally Posted by Zooch View Post
    Looking good!

    Is there any way you can help explain your wind shader a bit more? My "wind" shader feels more like an underwater current (if that current was having a seizure).

    Do you paint weights on the grass?
    I make a short making of.
    Last edited by Ulrich.Thümmler; 06-01-2014 at 02:26 PM.

Page 1 of 5 123 ... LastLast

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •