Set smooth - in blender - performance cost?

The place for artists, modellers, level designers et al to discuss their approaches for creating content for OGRE.
Post Reply
User avatar
chaosavy
Silver Sponsor
Silver Sponsor
Posts: 578
Joined: Mon Jun 15, 2009 8:29 pm
x 64
Contact:

Set smooth - in blender - performance cost?

Post by chaosavy »

Hey guys, wondering if the "set smooth" option in Blender (and I'm guessing other modeling software) causes a significant performance hit (if any) versus the "set solid" option.

Any info appreciated.

thanks :)
Visit http://www.VoidDestroyer.com to check out my space sim project - Void Destroyer
bstone
OGRE Expert User
OGRE Expert User
Posts: 1920
Joined: Sun Feb 19, 2012 9:24 pm
Location: Russia
x 201

Re: Set smooth - in blender - performance cost?

Post by bstone »

The "set solid" option requires duplicated vertices and normals so it eats more memory but performance should be equal on any modern hardware.
User avatar
duststorm
Minaton
Posts: 921
Joined: Sat Jul 31, 2010 6:29 pm
Location: Belgium
x 80
Contact:

Re: Set smooth - in blender - performance cost?

Post by duststorm »

If anything "set smooth" improves the speed :)
As bstone mentioned, it makes neighbour triangles share the same vertices (as opposed to flat shaded which has 3 vertices for each triangle). So the data needed for your model will decrease with smoothing applied. (and smoohing is generally what you need for 90% of your models I presume)

Don't confuse "set smooth" with subdivision modifiers, though. Those actually add extra faces (at least when you apply them to the mesh before exporting).
Developer @ MakeHuman.org
User avatar
chaosavy
Silver Sponsor
Silver Sponsor
Posts: 578
Joined: Mon Jun 15, 2009 8:29 pm
x 64
Contact:

Re: Set smooth - in blender - performance cost?

Post by chaosavy »

Thanks! Now I have to set smooth everything :)
Visit http://www.VoidDestroyer.com to check out my space sim project - Void Destroyer
User avatar
duststorm
Minaton
Posts: 921
Joined: Sat Jul 31, 2010 6:29 pm
Location: Belgium
x 80
Contact:

Re: Set smooth - in blender - performance cost?

Post by duststorm »

Just go for what looks best, since there really is no difference in performance. I think with blender you can also set some edges sharp and others smooth, if that is what you want.
Developer @ MakeHuman.org
Demarii
Gnoblar
Posts: 18
Joined: Thu Jan 26, 2012 2:58 am
Location: Canada
x 9

Re: Set smooth - in blender - performance cost?

Post by Demarii »

A good page on model optimization you might find interesting.

http://dungeonhack.sourceforge.net/Model_Optimization

It also links to the Vegastrike wiki with some good practices on creating nice bevels and welds.
User avatar
duststorm
Minaton
Posts: 921
Joined: Sat Jul 31, 2010 6:29 pm
Location: Belgium
x 80
Contact:

Re: Set smooth - in blender - performance cost?

Post by duststorm »

Indeed very good tips.
- Checking for wrong facing faces
- Finding and fixing non-manifold vertices
- Using sharp edge modifier
- avoiding intersecting triangles

All very recommendable ;)
Developer @ MakeHuman.org
User avatar
Waruck
Goblin
Posts: 210
Joined: Mon Dec 12, 2011 12:52 pm
Location: Germany
x 34

Re: Set smooth - in blender - performance cost?

Post by Waruck »

Has anyone testet whether the sharp-edge modifier works with the Blender2Ogre exporter?
From a quick search in the script it looks like it only checks the whole faces whether they are set to soft so i guess if this is supported in any way you have to apply the modifier to the mesh but I'm not sure this works at all.

Guess I'll but it on my to-do list for summer vacation.
User avatar
duststorm
Minaton
Posts: 921
Joined: Sat Jul 31, 2010 6:29 pm
Location: Belgium
x 80
Contact:

Re: Set smooth - in blender - performance cost?

Post by duststorm »

Good point. I don't think I've tested it.
Developer @ MakeHuman.org
bstone
OGRE Expert User
OGRE Expert User
Posts: 1920
Joined: Sun Feb 19, 2012 9:24 pm
Location: Russia
x 201

Re: Set smooth - in blender - performance cost?

Post by bstone »

I believe it works because I certainly used it for some models and I don't remember any visual difference when displaying the resulting .mesh in the game.
Post Reply