Subdivision and You

Tutorial collection, comprehensive listings on main site.

Subdivision and You

Postby Tutorial on Sun Sep 27, 2009 7:27 pm

category
General Half-Life 2/Effects

description
Fine tuning your displacement skills to create nice looking subdivisions.

keywords
displacement, terrain, subdivision, ground, paint alpha, edge, loops, edge loops, cliffs, cliff.

Note: Subdivision by default can look really bad.

However, there's some tricks to it. Were going to practice with a 256^3 cube, converted into a displacement and set to a power of 3:

Image

Right now we could pull this around, make it bulgy, etc. But what if we wanted to round the corners? Well there's a tool called Subdivision. Go ahead and hit that. It probably just turned into this:

Image

This is obviously NOT Ideal. (Unless you like giant random spheres?

So to fix this, we add extra "edgeloops". It's technically a modeling term but it's the same process.

Image

As you can see i've merely selected the cube, gone in 32 units from edge, clipped it and done that for all the edge. Subdivided, it now looks like:

Image

Suddenly, we have rounded corners that don't look horrible, and aren't a ball. If we wanted bigger curves, you could clip in more:

16 unit clips:

Image

64 unit clips:

Image

You get the idea.

Some practical uses:

Image
Image
Image

As you can see, it's not perfect. There's still gonna be texture streaching (That can be fixed with $seamless_scale), and misplaced verts. This can be fixed by not having the edges aligned. It's something you'd have to play around with.

What else can this do?
With the right textures and enough time...
Image

Oh and one other displacement trick: While in Paint Geometry mode, instead of using left/right click to move, you can hold shift and left click which lets your mouse drag up/down determine the move distance.[b]In addition: Alt + left click (and drag) changes the radius size).

Hope this helps someone. =)

(Thanks to Robert Briscoe's blog post about it. I wouldn't have thought about the extra edge loop)

- Lord Ned
- Don't send PM's to this user -
Tutorial
Not A Real User
 
Joined: Sun Mar 06, 2005 11:00 pm

Re: Subdivision and You

Postby Zipfinator on Sun Sep 27, 2009 7:31 pm

Nice tutorial, I've never thought of using edge loops in Hammer for subdivision.
Image
|Pipe Dream|City 17: Episode 1|
User avatar
Zipfinator
Veteran
Veteran
 
Joined: Thu Dec 21, 2006 6:03 pm
Location: California

Re: Subdivision and You

Postby MrTwoVideoCards on Mon Sep 28, 2009 2:11 am

Not a very good tutorial, you use too many extra unneeded displacements. The extra loop works in some cases, but it's still something to worry about based on performance. Displacements don't take up that much anymore thanks to the OB engine, but their spec, and ssbumps can.
User avatar
MrTwoVideoCards
Monothetic
 
Joined: Thu Aug 02, 2007 11:18 am
Location: IN YOUR SOUL

Re: Subdivision and You

Postby Zipfinator on Mon Sep 28, 2009 2:28 am

MrTwoVideoCards wrote:Not a very good tutorial, you use too many extra unneeded displacements. The extra loop works in some cases, but it's still something to worry about based on performance. Displacements don't take up that much anymore thanks to the OB engine, but their spec, and ssbumps can.


Have you seen the EP2 caves displacement set up? A lot more complex than that.

And the amount of faces that the texture is on shouldn't matter, just the area that it covers. Also I thought that SSBumps were less expensive than normal bump maps.
Image
|Pipe Dream|City 17: Episode 1|
User avatar
Zipfinator
Veteran
Veteran
 
Joined: Thu Dec 21, 2006 6:03 pm
Location: California

Re: Subdivision and You

Postby Guessmyname on Mon Sep 28, 2009 10:21 am

MrTwoVideoCards wrote:Not a very good tutorial, you use too many extra unneeded displacements. The extra loop works in some cases, but it's still something to worry about based on performance. Displacements don't take up that much anymore thanks to the OB engine, but their spec, and ssbumps can.


Wouldn't that be a matter of the materials you use then?

And ssbumps are cheaper than ordinary bumpmapping, though they are still somewhat expensive.
User avatar
Guessmyname
1337 p0st3r
1337 p0st3r
 
Joined: Sun Mar 27, 2005 10:38 pm

Re: Subdivision and You

Postby ixin on Mon Sep 28, 2009 2:01 pm

Good tutorial, though somewhat obvious for modelers. But seriously useful for beginners.
User avatar
ixin
Been Here A While
Been Here A While
 
Joined: Mon Jun 12, 2006 1:51 pm

Re: Subdivision and You

Postby MrTwoVideoCards on Mon Sep 28, 2009 2:29 pm

Zipfinator wrote:
MrTwoVideoCards wrote:Not a very good tutorial, you use too many extra unneeded displacements. The extra loop works in some cases, but it's still something to worry about based on performance. Displacements don't take up that much anymore thanks to the OB engine, but their spec, and ssbumps can.


Have you seen the EP2 caves displacement set up? A lot more complex than that.

And the amount of faces that the texture is on shouldn't matter, just the area that it covers. Also I thought that SSBumps were less expensive than normal bump maps.


4 faces, a lot simpler. I Eat caves for dinner.
User avatar
MrTwoVideoCards
Monothetic
 
Joined: Thu Aug 02, 2007 11:18 am
Location: IN YOUR SOUL

Re: Subdivision and You

Postby Lord Ned on Tue Oct 20, 2009 10:32 pm

ixin wrote:Good tutorial, though somewhat obvious for modelers. But seriously useful for beginners.


Except I'm a modeler too and didn't even think about it until Briscoe's post. :P

MrTwoVideoCards wrote:Not a very good tutorial, you use too many extra unneeded displacements. The extra loop works in some cases, but it's still something to worry about based on performance. Displacements don't take up that much anymore thanks to the OB engine, but their spec, and ssbumps can.


I don't see how spec/ssbump is relevant. Besides if you use the same texture repetitively it takes up less vram as it's only loaded once.

And displacements are cheaper to render than brushes.
Resident Source Guru, Competent Level Designer, Talented Artist, Horrible Speller
User avatar
Lord Ned
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Thu Jul 17, 2008 8:42 pm

Re: Subdivision and You

Postby MayheM on Tue Oct 20, 2009 10:37 pm

I have been building a cave system for my L4D campaign and this will help a great deal with that. Much like others have said I never thought to use edge loops... Thanks...
Image
User avatar
MayheM
Veteran
Veteran
 
Joined: Tue Oct 16, 2007 7:46 pm
Location: Lancaster SC

Re: Subdivision and You

Postby Terr on Tue Oct 20, 2009 11:37 pm

MayheM wrote:I have been building a cave system for my L4D campaign and this will help a great deal with that. Much like others have said I never thought to use edge loops... Thanks...

It doesn't work in TF2, apparently, but it may be worth testing whether $seamless_scale could help for that.

Edit: Ah, already mentioned mid-way down the post. My bad.
___________________

I've been floating this idea around a bit: Voxel textures in HL2. Basically, you define a repeating block which is tiled in 3D. Using a "placeholder" texture in Hammer, a pre-processing tool can go through the VMF and find all the displacements surfaces which "cut" through the voxels, and convert the displacement face to use a generated on-the-fly texture.

Probably not worth implementing: blend textures and careful normal texturing do most of it. The main problem it would solve is seamless texturing in cave system ceilings and floors.
Terr
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Mon Oct 12, 2009 11:35 pm

Re: Subdivision and You

Postby FoxerTheMan on Fri Nov 06, 2009 10:45 pm

I didnt understand anything.
FoxerTheMan
Dumpling
Dumpling
 
Joined: Fri Oct 30, 2009 12:02 pm

Re: Subdivision and You

Postby Phott on Sat Nov 07, 2009 7:23 am

FoxerTheMan wrote:I didnt understand anything.

What? You better read some more tutorials then since this tutorial requires knowledge of subdivisions and clipping. For me, I got it just by looking at the pictures.
User avatar
Phott
Veteran
Veteran
 
Joined: Thu Sep 11, 2008 6:34 pm

Re: Subdivision and You

Postby KoyaOneda on Tue Dec 01, 2009 9:40 pm

While I understand the process of clipping, creating displacements, and subdivision in hammer, I have a few questions about edge loops.

When creating terrian using this technique, must all the brushwork be made out of cubes? The image provided in the tut. does not show edge loops like those created in the previous ex. (the cube). Does each quad have edge loops? Also after subdivision, should we eliminate the spheres left inside?
KoyaOneda
Member
Member
 
Joined: Tue Nov 03, 2009 10:38 pm

Re: Subdivision and You

Postby Major Banter on Tue Dec 01, 2009 9:54 pm

KoyaOneda wrote:When creating terrian using this technique, must all the brushwork be made out of cubes? The image provided in the tut. does not show edge loops like those created in the previous ex. (the cube). Does each quad have edge loops? Also after subdivision, should we eliminate the spheres left inside?


From what I'm gathering, you're referring to the fact that the example cliff-face will have displacements on its rear side.

You 'destroy' those or don't make them in the first place; the cube is an example, and bad displacement practice.

As long as every vertex lines up, you can make some impressive pieces very rapidly. For example:

Image
Credits to Robert Briscoe
ImageImageImage
Major Banter
Veteran
Veteran
 
Joined: Tue Apr 01, 2008 10:52 pm
Location: UK

Re: Subdivision and You

Postby KoyaOneda on Tue Dec 01, 2009 10:44 pm

Thanks for the explanation, I might not have understood 100% of it, but I can tinker in hammer until I figure it all out.
KoyaOneda
Member
Member
 
Joined: Tue Nov 03, 2009 10:38 pm
Next

Return to Tutorials

Who is online

Users browsing this forum: No registered users