Infinite tunnel environment

Hello,

i just wanna know if there’s a way to load a scene where the cam “runs” inthrough an infinite tunnel…



Thank you



Gianni,

giannign1

You can’t load an infinite scene as that would take infinite memory. But you can procedurally generate this tunnel, yes.

Yes,

i was meaning something as that you tell about



But how??? Can you give me some example?



Thanks



Gianni,

giannign1

Do you mean something like procedural 3D cave generation? I don’t know what it’s status is in terms of working with the latest jME3. You’d have to ask @mazander or @rickard about that.



It’s on GoogleCode:

http://code.google.com/p/cave3d/

Infact i have downloaded the version for jme3 but it doesn’t work well



Now i’ll ask mazander







Someone else know some other example like this?



Thank you

Hello,

the jme3 version is done by @rickard and there is no changes for that after Dec 2010. That time I had troubles to use custom texture mapping shader in jme3, maybe it’s currently easier. The geometry generation should still be usable. Anyway the procedural geometry creation is good choice for infinite tunnel.

  • mazander

The TerrainAdvanced material has tri-planar texturing which would be ideal for these tunnels. You should be able to directly apply it.

1 Like

Hi,



I’m also interested, @Sploreg you say that the TerrainAdvanced (which I’ll take a shoot in the dark and guess is the same as terraingrid) can work for this, and I would really like to know how to do that, since I’ve trying with the examples and I haven’t been able to make any more than “2d terrains” since it only goes up and down, I haven’t been able to “twist” it or rotate parts of it.



Thanks,

TerrainAdvanced.j3md is a material, not geometry. TerrainQuad/TerrainGrid are heightfields (no tunnels)

@Sploreg said:
TerrainAdvanced.j3md is a material, not geometry. TerrainQuad/TerrainGrid are heightfields (no tunnels)


I see, so I'm even more confused now (sorry about that, I'm just learning this terrain stuff), I searched on the wiki and the forums and couldn't find anything about the TerrainAdvanced, so I'll fire at will some questions (maybe so many that they fit on another topic):

1) if it's a material, it is possible to use collision with it? (I guess it can't but you never know)
2) how to use it? in general, I'd like to know more about all this so I can create more complex forms like caves and cliffs (which I was initially asuming it would be something like rotating the terrain on some parts)
3) I tried to create height maps separately and then rotating some of them, but I haven't been able to solve the gaps and unmatched borders thing, ¿do you know how I might accomplish this (or which way start to investigate)?.

I ask all these questions since I want to create a terrain with different features, but because of the performance geometries as a replacement are out of the table (I think), and as I have seen on the forums leaving holes on the terrainGrid was quite unlikely (or at least for now).

Thanks
  1. nope, materials are just the color and texture of a ‘mesh’. meshes are what collide. Terrain is a mesh, boxes are meshes, models are meshes.
  2. like any other material https://wiki.jmonkeyengine.org/legacy/doku.php/jme3:beginner:hello_material
  3. if you rotate heightmaps, they will not seam together. Picture a texture that gets wrapped around a cylinder. The ends of the texture will touch at the back side of the cylinder. Those edges of the picture should match up so they can “tile” together, and not look like a seam. Same goes for heightmaps.
1 Like

To do something like this you would need to use a perlin noise generator with or without LUT (lookup texture), preferably a 4D although a 3D might work. The noise generator would need dynamic parameters so the tunnel is not the same everywhere.



That’s how I’d do it.

Wow, thanks a lot, I’ll check that out.

Hi @cedadcamus @giannign1



I have a similar post in the forum http://hub.jmonkeyengine.org/groups/general-2/forum/topic/3d-tunnelcave-effect/



I would like to inquire about your progress so far …



Cheers…

@xavi-ripper i’m sorry but i have abbandoned this development much time ago…