Terrain Texturing
- RyanN
- Halfling
- Posts: 82
- Joined: Thu Aug 19, 2004 6:41 am
- Location: Victoria, Australia
- Contact:
Terrain Texturing
Whats the best way to paint a terrain?
I want to get a similar effect used in FarCry with different high detailed textures blending together in specified areas.
Multitexturing i guess is the only way but how can i have textures with their own masks?
I want to get a similar effect used in FarCry with different high detailed textures blending together in specified areas.
Multitexturing i guess is the only way but how can i have textures with their own masks?
- tuan kuranes
- OGRE Retired Moderator

- Posts: 2653
- Joined: Wed Sep 24, 2003 8:07 am
- Location: Haute Garonne, France
- x 4
- Contact:
- PeterNewman
- Greenskin
- Posts: 128
- Joined: Mon Jun 21, 2004 2:34 am
- Location: Victoria, Australia
- Contact:
That's not exactly the effect he's after, though. I happen to know this because RyanN is my art guy.
He's got a texture that has green for grass and brown for path and so on, that's fairly low detail and just defines ther area's. He'd like to put a higher detail tiled "rocky" texture on where the path area's are, and a higher detail tiled "grass" texture on the grass, and "cliff wall" on the cliffs, and so forth.
We've done something like this already by using multiple texture units and modulative blending, but this really only worked for producing a lightmap.
He's got a texture that has green for grass and brown for path and so on, that's fairly low detail and just defines ther area's. He'd like to put a higher detail tiled "rocky" texture on where the path area's are, and a higher detail tiled "grass" texture on the grass, and "cliff wall" on the cliffs, and so forth.
We've done something like this already by using multiple texture units and modulative blending, but this really only worked for producing a lightmap.
- tuan kuranes
- OGRE Retired Moderator

- Posts: 2653
- Joined: Wed Sep 24, 2003 8:07 am
- Location: Haute Garonne, France
- x 4
- Contact:
- monster
- OGRE Community Helper

- Posts: 1098
- Joined: Mon Sep 22, 2003 2:40 am
- Location: Melbourne, Australia
- Contact:
I'm guessing that as this post's in the "Artists & Content Creators" section you're not really interested in the technical details of how splatting (or whatever you want to call it) happens, you just want some tool (or "arty" type mechanism
) that allows you to paint your landscape from high up in that air and which then automatically applies details to it as you get closer. Yes?
There was a really impressive terrain engine knocking around a while back. But they (http://www.gscape.com/) seem to have disappeared. This had an editor that did, I think, exactly what you're after. You painted on it with big thick brushes roughly what type of textures you wanted where and the engine applied the necessary details to make it look nice close up.
Unfortunately I don't think such a tool exists (yet) for Ogre. But I haven't looked at the PLSM lately, so I could be wrong.
There was a really impressive terrain engine knocking around a while back. But they (http://www.gscape.com/) seem to have disappeared. This had an editor that did, I think, exactly what you're after. You painted on it with big thick brushes roughly what type of textures you wanted where and the engine applied the necessary details to make it look nice close up.
Unfortunately I don't think such a tool exists (yet) for Ogre. But I haven't looked at the PLSM lately, so I could be wrong.
-
Dorkula
- Gnoblar
- Posts: 22
- Joined: Tue May 18, 2004 6:08 am
- Location: Portland, Oregon
- Contact:
- RyanN
- Halfling
- Posts: 82
- Joined: Thu Aug 19, 2004 6:41 am
- Location: Victoria, Australia
- Contact:
- semicolon
- Halfling
- Posts: 94
- Joined: Sun Jul 04, 2004 4:42 pm
- Location: Bangkok, Thailand
- Contact:
Yes, Ryan you can do some texture blend on top of the other. There are 2 ways you can do it. First, with scene_blend operations, you are to blend texture on top of the scene pixels. If you want to create like a tree plain, you have to create a tree texture with an alpha channel.
Second, colour_op or colour_op_ex, you can blend between texture layer but this won't affect the current scene pixels, only inside the texture unit. This you will allow you to blend 2 textures to create some effect that you want.
Code: Select all
material Tree_texture
{
technique
{
pass
{
ambient 0.588235 0.588235 0.588235 1
diffuse 0.588235 0.588235 0.588235 1
specular 0.9 0.9 0.9 1 0
scene_blend alpha_blend
texture_unit
{
tree_texture.png //say tree_texture is a texture with alpha channel
filtering point point point
}
}
}
}
"Nature is the mother of learning"
- RyanN
- Halfling
- Posts: 82
- Joined: Thu Aug 19, 2004 6:41 am
- Location: Victoria, Australia
- Contact:
- tuan kuranes
- OGRE Retired Moderator

- Posts: 2653
- Joined: Wed Sep 24, 2003 8:07 am
- Location: Haute Garonne, France
- x 4
- Contact:
get ogreaddons
loook in paginglandscape media folder.
look for the splatting materials.
here is an excerpt :
The "texture None" are replaced realtime by the engine, loading an alpha only map, that determine if the current texture (snow, rock, etc..) si blended or not.
loook in paginglandscape media folder.
look for the splatting materials.
here is an excerpt :
Code: Select all
material SplattingMaterial
technique
{
lod_index 0
pass
{
// Base Pass
ambient 1.0 1.0 1.0
diffuse 1.0 1.0 1.0
texture_unit
{
// Base Texture
texture none
tex_address_mode clamp
alpha_op_ex source1 src_texture src_texture
colour_op_ex modulate src_current src_texture
}
}
pass
{
// Snow Pass
ambient 1.0 1.0 1.0
diffuse 1.0 1.0 1.0
scene_blend alpha_blend
depth_func equal
texture_unit
{
// Snow Alpha map
texture none
tex_address_mode clamp
alpha_op_ex source1 src_texture src_texture
colour_op_ex source1 src_current src_current
alpha_rejection greater_equal 2
}
texture_unit
{
// Snow Splat
texture splatting_snow.jpg
tex_address_mode mirror
alpha_op_ex source1 src_current src_current
colour_op_ex source2 src_current src_texture
scale 0.01 0.01
}
}
pass
{
// Sand Pass
ambient 1.0 1.0 1.0
diffuse 1.0 1.0 1.0
scene_blend alpha_blend
depth_func equal
texture_unit
{
// Sand Alpha map
texture none
tex_address_mode clamp
alpha_op_ex source1 src_texture src_texture
colour_op_ex source1 src_current src_current
alpha_rejection greater_equal 2
}
texture_unit
{
// Sand Splat
texture splatting_sand.jpg
tex_address_mode mirror
alpha_op_ex source1 src_current src_current
colour_op_ex source2 src_current src_texture
scale 0.01 0.01
}
}
pass
{
// Grass Pass
ambient 1.0 1.0 1.0
diffuse 1.0 1.0 1.0
scene_blend alpha_blend
depth_func equal
texture_unit
{
// Grass Alpha map
texture none
tex_address_mode clamp
alpha_op_ex source1 src_texture src_texture
colour_op_ex source1 src_current src_current
alpha_rejection greater_equal 2
}
texture_unit
{
// Grass Splat
texture splatting_grass.jpg
tex_address_mode mirror
alpha_op_ex source1 src_current src_current
colour_op_ex source2 src_current src_texture
scale 0.01 0.01
}
}
pass
{
ambient 1.0 1.0 1.0
diffuse 1.0 1.0 1.0
scene_blend alpha_blend
depth_func equal
texture_unit
{
// Rock Alpha map
texture none
tex_address_mode clamp
alpha_op_ex source1 src_texture src_texture
colour_op_ex source1 src_current src_current
alpha_rejection greater_equal 2
}
texture_unit
{
// Rock Splat
texture splatting_rock.jpg
tex_address_mode mirror
alpha_op_ex source1 src_current src_current
colour_op_ex source2 src_current src_texture
scale 0.01 0.01
}
}
}
technique
{
lod_index 1
pass
{
ambient 1.0 1.0 1.0
diffuse 1.0 1.0 1.0
texture_unit
{
// Base Texture
texture none
tex_address_mode clamp
}
}
}
}- RyanN
- Halfling
- Posts: 82
- Joined: Thu Aug 19, 2004 6:41 am
- Location: Victoria, Australia
- Contact:
- PeterNewman
- Greenskin
- Posts: 128
- Joined: Mon Jun 21, 2004 2:34 am
- Location: Victoria, Australia
- Contact:
-
rmmt
- Gnoblar
- Posts: 23
- Joined: Sun Apr 03, 2005 7:14 am
- Location: Philippines
- Contact:
- tuan kuranes
- OGRE Retired Moderator

- Posts: 2653
- Joined: Wed Sep 24, 2003 8:07 am
- Location: Haute Garonne, France
- x 4
- Contact:
- jacmoe
- OGRE Retired Moderator

- Posts: 20570
- Joined: Thu Jan 22, 2004 10:13 am
- Location: Denmark
- x 179
- Contact:
From the Ogre site:
Community Add-on Projects
Community Add-on Projects
/* Less noise. More signal. */
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.
Ogitor Scenebuilder - powered by Ogre, presented by Qt, fueled by Passion.
OgreAddons - the Ogre code suppository.