About Store Forum Documentation Contact



Post Reply 
Heightmap problem
Author Message
kulesz Offline
Member

Post: #1
Heightmap problem
Hi,

I'm using the new "Edit::heightMap" feature to generate some heightmap meshes from perlin noise (I use libnoise library to generate the noise arrays).
Everything is fine until I try to render few heightmaps side by side - I'm trying to make huge map from few smaller ones. The border vertexes' values of two neighbor heightmaps are exactly the same, but the shadows look somewhat broken. Some screens are attached.
Is there some way to fix it?


Attached File(s) Image(s)
           
05-29-2011 01:00 PM
Find all posts by this user Quote this message in a reply
Demi Offline
Member

Post: #2
RE: Heightmap problem
Try using smooth function with speed and size at minimum and soft at max. Not guaranteed to work but that was what I did with a mosaic.

You have to run down the seam.
(This post was last modified: 05-29-2011 02:14 PM by Demi.)
05-29-2011 02:13 PM
Find all posts by this user Quote this message in a reply
kulesz Offline
Member

Post: #3
RE: Heightmap problem
The problem is, that theoretically they are seamless. Vertexes on left side of one heightmap are exactly the same are the ones on the right side of second heightmap - there are no gaps etc. Just this shadow/seam effect on the texture is causing a problem.
05-29-2011 03:07 PM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #4
RE: Heightmap problem
in the build method you need to pass heightmap neighbors pointers
05-31-2011 10:08 AM
Find all posts by this user Quote this message in a reply
kulesz Offline
Member

Post: #5
RE: Heightmap problem
Hmm, ok, and how to enable colisions with the generated terrain?
06-05-2011 05:52 PM
Find all posts by this user Quote this message in a reply
Esenthel Offline
Administrator

Post: #6
RE: Heightmap problem
create phys/actor from mesh
06-05-2011 07:49 PM
Find all posts by this user Quote this message in a reply
kulesz Offline
Member

Post: #7
RE: Heightmap problem
Well, I've tried to combine my app with the dynamic object creation tutorial.
After doing:
Code:
Mesh *m_temp;
PhysBody   phys ;
Actor      actor;

m_temp = new Mesh;
m_temp = create_mesh_from_heightmap();

phys .parts.New().createMesh(*m_temp); // create physical body from 'mesh'
actor.create(phys);

After hitting space, a new barrel appears, but it comes through my terrain :/
06-05-2011 08:04 PM
Find all posts by this user Quote this message in a reply
Post Reply