conceptual question:
I if I position a floor on a plot created by a heightmap, this I will be sunken in the ground since it is not the same plane.
you as you have settled the matter?
I thought of 2 ways:
by model (difficult) to create each model on the ground and not the other way
via code: make sure that the soil is suitable for automatic, but I do not think you can do this on heightmaps these being the result of a calculation on the basis of heights.
any suggestions?
thanks
Nevarim
conceptual question on heightmaps + models
- nevarim
- Gnoll
- Posts: 675
- Joined: Mon Jul 05, 2010 6:16 pm
- Location: Pavia Italy
- x 4
- Contact:
conceptual question on heightmaps + models
i'm a noob until proven otherwise
used in my project and thanks to everyone
Ogre 3d
Mygui
Skyx
Hydrax
MOC
CCS
used in my project and thanks to everyone
Ogre 3d
Mygui
Skyx
Hydrax
MOC
CCS
- tod
- Troll
- Posts: 1394
- Joined: Wed Aug 02, 2006 9:41 am
- Location: Bucharest
- x 94
- Contact:
Re: conceptual question on heightmaps + models
- put models on flat surface.
- make model thicker so part of it can get into the ground and still look good (like a house model)
- flatten terrain before placing
- make model thicker so part of it can get into the ground and still look good (like a house model)
- flatten terrain before placing
- nevarim
- Gnoll
- Posts: 675
- Joined: Mon Jul 05, 2010 6:16 pm
- Location: Pavia Italy
- x 4
- Contact:
Re: conceptual question on heightmaps + models
I too had thought about these answers,
analyzing them point by point:
- Put models on flat surface.
means I have to put everything on one sixth of the land and the effect is not the greatest, the world would be relatively empty.
- Make model thicker part of it I can get into the ground and still look good (like a house model)
makes the design of 3d models much more complicated and makes it unlikely the creation by the player of your own home at the point you wish to
- Flatten terrain before Placing
me this is the most difficult prer the programmer but also the most used in the world, this would mean me isntallare a concept of world modeling which falls into the dynamic modeling.
since the solution I'm using is the one applied in tutorial3, the use of heightmaps the only system would be:
find the midpoint of the mesh (eg a house but could also be something much more like a small rock) we recover the height of the point of intersection with a raylight.
so far so good
from here on, the problems arise:
on the ground aplico the height of all pixels that correspond to the rock doing so that they become a plan, then edit the area around the mesh so that it is softer than the difference of heights.
as in the attached image where the red line is the first and the black line is after
the problem is how to apply this solution on a heightmaps?
there is a tutorial or explanation of how it works dynamically changing the heightmaps?
thanks
Neva
analyzing them point by point:
- Put models on flat surface.
means I have to put everything on one sixth of the land and the effect is not the greatest, the world would be relatively empty.
- Make model thicker part of it I can get into the ground and still look good (like a house model)
makes the design of 3d models much more complicated and makes it unlikely the creation by the player of your own home at the point you wish to
- Flatten terrain before Placing
me this is the most difficult prer the programmer but also the most used in the world, this would mean me isntallare a concept of world modeling which falls into the dynamic modeling.
since the solution I'm using is the one applied in tutorial3, the use of heightmaps the only system would be:
find the midpoint of the mesh (eg a house but could also be something much more like a small rock) we recover the height of the point of intersection with a raylight.
so far so good
from here on, the problems arise:
on the ground aplico the height of all pixels that correspond to the rock doing so that they become a plan, then edit the area around the mesh so that it is softer than the difference of heights.
as in the attached image where the red line is the first and the black line is after
the problem is how to apply this solution on a heightmaps?
there is a tutorial or explanation of how it works dynamically changing the heightmaps?
thanks
Neva
- Attachments
-
- Untitled.png (3.51 KiB) Viewed 467 times
i'm a noob until proven otherwise
used in my project and thanks to everyone
Ogre 3d
Mygui
Skyx
Hydrax
MOC
CCS
used in my project and thanks to everyone
Ogre 3d
Mygui
Skyx
Hydrax
MOC
CCS
- areay
- Bugbear
- Posts: 819
- Joined: Wed May 05, 2010 4:59 am
- Location: Auckland, NZ
- x 69
Re: conceptual question on heightmaps + models
If you don't want to modify your models to have a base then you could just make a separate model (or just an Ogre::SceneManager:PT_CUBE) and call it a 'foundation' or something.
When placing a building, first figure out the maximum height value inside the area that you'll be placing it. Create the foundation object and set it so that the top of the foundation is at the maximum height of the underlying terrain. Then place the house on top of the foundation.
When placing a building, first figure out the maximum height value inside the area that you'll be placing it. Create the foundation object and set it so that the top of the foundation is at the maximum height of the underlying terrain. Then place the house on top of the foundation.
- tod
- Troll
- Posts: 1394
- Joined: Wed Aug 02, 2006 9:41 am
- Location: Bucharest
- x 94
- Contact:
Re: conceptual question on heightmaps + models
Ogre terrain can be created by a heightmap, but once this is done, the heightmap is not used. The terrain is also editable, so you can flatten it at runtime. So don't focus on the heightmap, as it's only used in pre-production, not at runtime.
- Zonder
- Ogre Magi
- Posts: 1168
- Joined: Mon Aug 04, 2008 7:51 pm
- Location: Manchester - England
- x 73
Re: conceptual question on heightmaps + models
exactly what i was going to post.areay wrote:If you don't want to modify your models to have a base then you could just make a separate model (or just an Ogre::SceneManager:PT_CUBE) and call it a 'foundation' or something.
When placing a building, first figure out the maximum height value inside the area that you'll be placing it. Create the foundation object and set it so that the top of the foundation is at the maximum height of the underlying terrain. Then place the house on top of the foundation.
There are 10 types of people in the world: Those who understand binary, and those who don't...