Previous Thread  Next Thread

chat icon Determining shading type from python console

Envenge

Posted: Fri Nov 02, 2012 3:56 am
Joined: 02 Nov 2012
Posts: 2
I'm fairly new to using the python console in blender. I'm wondering, is there any way to determine which shading method, meaning flat or smooth, is being used on a specific object from the console? Thanks.
Reply with quote


CoDEmanX

Posted: Fri Nov 02, 2012 8:48 am
Joined: 05 Apr 2009
Posts: 684
smooth or flat shading is set per face, so you need to check a certain polygon.

bpy.context.object.data.polygons[0].use_smooth
_________________
I'm sitting, waiting, wishing, building Blender in superstition...
Reply with quote


Envenge

Posted: Fri Nov 02, 2012 4:51 pm
Joined: 02 Nov 2012
Posts: 2
Awesome, thank you!
Reply with quote


 
Jump to:  
Powered by phpBB © 2001, 2005 phpBB Group