Originally posted by hippowombat
View Post
Announcement
Collapse
No announcement yet.
Blending meshes with landscapes with no seams: how?
Collapse
X
-
Jorickan replied
-
长ㄩ尺ㄖ repliedHmm.. i was trying the Material .. Thanks but i have an Problem.. it seems i have an Dark Shadow when im Using this Feature , When im Reduce the Dithering , The Shadow Disappears but.. than i dont have that blending anymore.. any ideas?
Leave a comment:
-
NilsonLima repliedOriginally posted by kjetilhj View PostYou can normalize the distancefieldgradient node. Feed it a worldposition and it will give you the normal from the distancefield. Use distancetonearestsurface to decide where to blend in the normal. It's takes a bit of tweaking to get right, and most likely does not work in all cases, but it's worth a try. I commented on another post here. https://forums.unrealengine.com/deve...-of-two-meshes
It shows a basic version of the material + video here - http://take.ms/v0nUZL
Leave a comment:
-
kjetilhj repliedYou can normalize the distancefieldgradient node. Feed it a worldposition and it will give you the normal from the distancefield. Use distancetonearestsurface to decide where to blend in the normal. It's takes a bit of tweaking to get right, and most likely does not work in all cases, but it's worth a try. I commented on another post here. https://forums.unrealengine.com/deve...-of-two-meshes
It shows a basic version of the material + video here - http://take.ms/v0nUZL
Leave a comment:
-
jonimake repliedOriginally posted by Norman3D View Post
This does not accomplish what OP is asking for. He wants to be able to blend the normals with the underlying mesh so that there are no visible seams.
You can't access the underlying terrain's normal maps. So you'll have to take the terrain to 3dsMax or other 3d software and get the normal map from the terrain by projecting it on to a plane.
Leave a comment:
-
APOCRS1980 repliedIt's been quite some time since anyone posted on this thread but I am looking for this exsact solution to get rid of the nasty hard edges on my static meshes that are intersecting the terrain dynamically. Since it's been so long has anyone come up with a solution? I'm not a programmer so I would have to follow a tutorial to set up the proper MF, definitely a topic worthy of being necro'd.
Leave a comment:
-
Sickmoocow repliedHey Ryan, any updates on adding the ability to sample the terrain's heightmap/normal and weightmaps in the material editor? I'm using a technique you described in another thread by transforming the normals of the mesh blend layer and a paintable terrain layer, but it obviously looks very flat on curved terrain, not to mention expensive and inconvienent. Having this kind of access would be a lifesaver for a project I'm working on!
Leave a comment:
-
Blackhole Bilbao repliedThanks for your responses guys. Time ago I tried with PixelDepthOffset. Worked fine but ... problems in lights&shadows.
Originally posted by RyanB View Post"Landscape_Manual_UVW" to help map textures to fit the landscape.
All you need is to know the min and max XYZ coordinates of the landscape.
Leave a comment:
-
OlmoPotums repliedOriginally posted by Daedalus51 View PostMan, I would actually really love for this to gain some momentum so it becomes something that is a native part of the core engine code in Unreal. I cant go into any details, but thats how we do it. Its a core functionality and thus its also way cheaper so we can afford to do it cross platform [MENTION=2654]6[/MENTION]0 fps. I can also say that our solution automatically picks up the terrain texture, so there is no need for custom material instances depending on where you wanna place the asset, but again...its all handled natively via the engine code to make it fast and working in all cases.
I also think this is really something that will become more and more important to keep a high visual quality for games now and in the near future so PLS Epic...think about a native solution for this
Cheers!. To have someone from the studio that created Battlefront, which was the impetus for my project, notice this tool is AWESOME!!
Conveniently swapping materials is the thing I'm currently working on. I have some ideas for automatic terrain material sampling, although I have no clue how you would tackle a mesh that is is located on a transition-area between two landscape materials.
It would be indeed way more desirable to achieve this effect by accesing the terrain-information somehow. Before I got the idea to use Distance Fields, I spent a couple of weeks pulling my hair out while trying to get some useful information out of the landscape actor.
Last edited by OlmoPotums; 12-20-2016, 07:50 PM.
Leave a comment:
-
Deathrey repliedBeing able to sample terrain's heightmap and weightmaps from other materials would be invaluable addition. For now I've been using a downsized power of 2 copy of terrain heightmap. While technically doing so is a waste of memory, it is still good sacrifice and gives acceptable results for large and medium meshes.
For small terrain scatters, that were placed with grass system, I've actually used slightly different approach. I've sampled terrain's normal map and used it to drive direction of gradient mask on the meshes. Eventually, the mask looked like a band around the mesh's pivot(pivots were centered for small scatter meshes), that was aligned with terrain's normal.
Leave a comment:
-
RyanB repliedIts funny this just came up internally as well.
Terrain can now influence DF, but its not a whole solution because then you have the issue about 'who writes to DF and who reads', but its one option.
While we internally would love a more automated way to sample the heightmap texture, there are no current plans. Its much more likely (in the near term at least) that we could make a little blueprint that captures it and sets some MPC parameters for you to make it easier to set up.
A while ago I added a function "Landscape_Manual_UVW" to help map textures to fit the landscape. A user posted an image of it here:
https://forums.unrealengine.com/show...l=1#post639688
All you need is to know the min and max XYZ coordinates of the landscape.
Leave a comment:
-
Daedalus51 repliedTrue....that would be the preferred method! But I am not aware of any access to the terrain heightmap via the material editor
Edit: [MENTION=3692]RyanB[/MENTION] or [MENTION=404]DanielW[/MENTION] would it be possible in an easy way for you guys to enable access to the landscape heightmap via materials (like lightmassAO or the DistanceField Nodes) so we could figure out a way to do this that doesnt need the overhead of DistanceFields just to achieve that specific effect?
The rest can actually be handled quite in a smart way....like the different terrain materials etc that doesnt need code workLast edited by Daedalus51; 12-20-2016, 04:11 PM.
Leave a comment:
-
Deathrey repliedWhere distance fields are out of option, you can sample terrain's heightmap in vertex shader and apply proper math to get terrain height at mesh's vertices in order to get initial blend mask procedurally.
Leave a comment:
-
Daedalus51 repliedMan, I would actually really love for this to gain some momentum so it becomes something that is a native part of the core engine code in Unreal. I cant go into any details, but thats how we do it. Its a core functionality and thus its also way cheaper so we can afford to do it cross platform [MENTION=2654]6[/MENTION]0 fps. I can also say that our solution automatically picks up the terrain texture, so there is no need for custom material instances depending on where you wanna place the asset, but again...its all handled natively via the engine code to make it fast and working in all cases.
I also think this is really something that will become more and more important to keep a high visual quality for games now and in the near future so PLS Epic...think about a native solution for this
Cheers!Last edited by Daedalus51; 12-20-2016, 12:49 PM.
Leave a comment:
Leave a comment: