Unity 3d exporter missing terrain

unity-exporter
#1

Hi.
I’m using unity 3d 2019 to create a terrain and the babylonjs unity exporter to export it.
I watched the getting started video and all seems to work with plane and cube objects. But when i add the terrain it doesn’t appear in the preview. I placed under the cube but there’s only the cube in the preview.
Where am i wrong ?
Thanks.

#2

Pinging @MackeyK24

#3

The classic version DOES NOT fully support terrains. I am working on this feature for the new up coming version :slight_smile:

1 Like
#4

@manrix : I see you are still looking for a way to create a terrain with with textures - and are trying Unity.

Here is an alternative that you might want to look at in Blender 2.80:

  1. Activate the Blender Landscape addon (comes already installed in 2.80) See this video to give you an idea of its functionality:

Landscape Mesh Blender 2.8. Create Rock Hill,River,Lake and Others In Blender 2.8

Once you have a mesh you like (lots of options to play with), then Texture Paint it using the set up you can find in this video:

Like Substance Painter but in Blender 2.8!!

The video successfully mixes two textures. When he tries a third texture he crashes. Not sure why computer or state of Blender 2.80 at the time. I have a version that I got last week and had no problem adding a 3rd texture - see image below.

cheers, gryff :slight_smile:

#5

Ah ok.
Reading the documentation i understood it was possible to export the terain with up to 12 textures. However i see it exports an heightmap, splat map and textures in the export folder. How can i use the spaltmap to paint the terrain after i create the ground from heightmap ?
Thanks.

@gryff, i’ll look at them. However unity fits better for terrain creation. Blender seems for creating models. Plus my knowledge of blender is null. :slight_smile:
Thanks.

#6

Yeah I can get the stuff out of unity just fine.

My problem is the splatmap shader. I had two version one with up to 12 max textures 6 diffuse and 6 normal maps and another using texture atlas … both had issues that I need to work with a shader guru to get that worked out in new version … pinging @nasimiasl

1 Like
#7

I understand.
I hope you solve that. Using unity to create a terrain with many textures would be really nice.
Thank you. :wink:

#8

hey

how many texture we need add in maximum for support unity shader??

#9

That all depend on if we can get Texture Atlas working… Then i would say lets set max to 12 SPLATS (Textures and Normal Map pairs)

If we have to use separate textures… I would love at least 6 SPLATS (Texture and Normal Map pairs)

Worse case at least 3 SPLATS (Texture Normal Map pairs)

#10

please send me any sample of texture or shader code

#11

Do you mean only 3 textures ? That’s too few. I hope at least 10.

#12

the best solution is texture atlas i guess

#13

Texture atlas is what I want to use. Both you and I looked at this before and we had a bunch of edge seams. We tried the 9 crop image approach as well and you made a function I glsl to try and help but is was way to complicated for me to fully understand what was going on in shader…

I think WebGL 2 has texture2DLod or something like that so we don’t have to use fract function… I think… that’s kinda what I need help in determining… what the best way to handle the exported terrain materials and glsl shader we have to write to handle all that stuff on the Babylon side

#14

This:

will be in 4.1

#15

If we can’t get texture atlas working then we are screwed on the glsl total texture limit… rembember unity has a matching normal… so just for the additional terrains textures using 3 SPLATS … you need 1 texture for splatmap, 3 for terrain textures and 3 for normal map and 1 for lightmap and if using pbr environment you need one more for the reflection texture… on mobile that’s already puts you 1 too many for the iOS which only support 8 max textures per call… or your gonna have to dump one of the textures…

Using a texture atlas we could pack up to 4 splatmaps in one texture atlas and up to 16 1K textures in main texture atlas and the matching normals in another texture… that’s only 3 extra texture to the normal material pipeline your terrain is painted with… albedo or diffuse

Good news thow … looks like @Deltakosh is gonna add some sort of texture atlas support in 4.1 that we can hopefully tap into to solve this terrain splatmaps issue

1 Like
#16

i have the solution I need make demo

#17

this is solution for edge seams


in progress for make tools for atlas texture

#18

Hey guys, any progress on this ? :slight_smile:

#19

for texture atlas Yes but for export more than 12 texture ( that not support in webgl in some mobile device ) no

** solution : that maybe work if we have texture atlas + a tools you can collect other images on one pic

1 Like
#20

12 textures are enough for me.
I hope the exporter will be updated soon.
Thanks for your work. :wink: