style cleanup: pep8, also quiet compiler warning.
This commit is contained in:
@@ -131,7 +131,7 @@ def handle_args():
|
|||||||
dest="sphinx_theme",
|
dest="sphinx_theme",
|
||||||
type=str,
|
type=str,
|
||||||
default='default',
|
default='default',
|
||||||
help =
|
help=
|
||||||
# see SPHINX_THEMES below
|
# see SPHINX_THEMES below
|
||||||
"Sphinx theme (default='default')\n"
|
"Sphinx theme (default='default')\n"
|
||||||
"Available themes\n"
|
"Available themes\n"
|
||||||
|
@@ -100,7 +100,7 @@ class MeshMirrorUV(Operator):
|
|||||||
vidxs[i] = tuple(sorted(l.vertex_index
|
vidxs[i] = tuple(sorted(l.vertex_index
|
||||||
for l in loops[lstart:lend]))
|
for l in loops[lstart:lend]))
|
||||||
# As we have no poly.center yet...
|
# As we have no poly.center yet...
|
||||||
pcents[i] = tuple(map(lambda x : x / p.loop_total,
|
pcents[i] = tuple(map(lambda x: x / p.loop_total,
|
||||||
map(sum, zip(*(verts[idx].co
|
map(sum, zip(*(verts[idx].co
|
||||||
for idx in vidxs[i])))))
|
for idx in vidxs[i])))))
|
||||||
# Preparing next step finding matching polys.
|
# Preparing next step finding matching polys.
|
||||||
|
@@ -294,21 +294,22 @@ class AddPresetCloth(AddPresetBase, Operator):
|
|||||||
|
|
||||||
preset_subdir = "cloth"
|
preset_subdir = "cloth"
|
||||||
|
|
||||||
|
|
||||||
class AddPresetFluid(AddPresetBase, Operator):
|
class AddPresetFluid(AddPresetBase, Operator):
|
||||||
'''Add a Fluid Preset'''
|
'''Add a Fluid Preset'''
|
||||||
bl_idname = "fluid.preset_add"
|
bl_idname = "fluid.preset_add"
|
||||||
bl_label = "Add Fluid Preset"
|
bl_label = "Add Fluid Preset"
|
||||||
preset_menu = "FLUID_MT_presets"
|
preset_menu = "FLUID_MT_presets"
|
||||||
|
|
||||||
preset_defines = [
|
preset_defines = [
|
||||||
"fluid = bpy.context.fluid"
|
"fluid = bpy.context.fluid"
|
||||||
]
|
]
|
||||||
|
|
||||||
preset_values = [
|
preset_values = [
|
||||||
"fluid.settings.viscosity_base",
|
"fluid.settings.viscosity_base",
|
||||||
"fluid.settings.viscosity_exponent",
|
"fluid.settings.viscosity_exponent",
|
||||||
]
|
]
|
||||||
|
|
||||||
preset_subdir = "fluid"
|
preset_subdir = "fluid"
|
||||||
|
|
||||||
|
|
||||||
|
@@ -166,7 +166,7 @@ class PHYSICS_PT_game_physics(PhysicsButtonsPanel, Panel):
|
|||||||
subsub.active = game.use_anisotropic_friction
|
subsub.active = game.use_anisotropic_friction
|
||||||
subsub.prop(game, "friction_coefficients", text="", slider=True)
|
subsub.prop(game, "friction_coefficients", text="", slider=True)
|
||||||
|
|
||||||
elif physics_type =='SENSOR':
|
elif physics_type == 'SENSOR':
|
||||||
col = layout.column()
|
col = layout.column()
|
||||||
col.prop(game, "use_actor", text="Detect Actors")
|
col.prop(game, "use_actor", text="Detect Actors")
|
||||||
col.prop(ob, "hide_render", text="Invisible")
|
col.prop(ob, "hide_render", text="Invisible")
|
||||||
|
@@ -1185,7 +1185,7 @@ class PARTICLE_PT_vertexgroups(ParticleButtonsPanel, Panel):
|
|||||||
psys = context.particle_system
|
psys = context.particle_system
|
||||||
|
|
||||||
split = layout.split(percentage=0.85)
|
split = layout.split(percentage=0.85)
|
||||||
|
|
||||||
col = split.column()
|
col = split.column()
|
||||||
col.label(text="Vertex Group:")
|
col.label(text="Vertex Group:")
|
||||||
col.prop_search(psys, "vertex_group_density", ob, "vertex_groups", text="Density")
|
col.prop_search(psys, "vertex_group_density", ob, "vertex_groups", text="Density")
|
||||||
@@ -1195,7 +1195,7 @@ class PARTICLE_PT_vertexgroups(ParticleButtonsPanel, Panel):
|
|||||||
col.prop_search(psys, "vertex_group_roughness_1", ob, "vertex_groups", text="Roughness 1")
|
col.prop_search(psys, "vertex_group_roughness_1", ob, "vertex_groups", text="Roughness 1")
|
||||||
col.prop_search(psys, "vertex_group_roughness_2", ob, "vertex_groups", text="Roughness 2")
|
col.prop_search(psys, "vertex_group_roughness_2", ob, "vertex_groups", text="Roughness 2")
|
||||||
col.prop_search(psys, "vertex_group_roughness_end", ob, "vertex_groups", text="Roughness End")
|
col.prop_search(psys, "vertex_group_roughness_end", ob, "vertex_groups", text="Roughness End")
|
||||||
|
|
||||||
col = split.column()
|
col = split.column()
|
||||||
col.label(text="Negate:")
|
col.label(text="Negate:")
|
||||||
col.alignment = 'RIGHT'
|
col.alignment = 'RIGHT'
|
||||||
@@ -1206,7 +1206,7 @@ class PARTICLE_PT_vertexgroups(ParticleButtonsPanel, Panel):
|
|||||||
col.prop(psys, "invert_vertex_group_roughness_1", text="")
|
col.prop(psys, "invert_vertex_group_roughness_1", text="")
|
||||||
col.prop(psys, "invert_vertex_group_roughness_2", text="")
|
col.prop(psys, "invert_vertex_group_roughness_2", text="")
|
||||||
col.prop(psys, "invert_vertex_group_roughness_end", text="")
|
col.prop(psys, "invert_vertex_group_roughness_end", text="")
|
||||||
|
|
||||||
# Commented out vertex groups don't work and are still waiting for better implementation
|
# Commented out vertex groups don't work and are still waiting for better implementation
|
||||||
# row = layout.row()
|
# row = layout.row()
|
||||||
# row.prop_search(psys, "vertex_group_velocity", ob, "vertex_groups", text="Velocity")
|
# row.prop_search(psys, "vertex_group_velocity", ob, "vertex_groups", text="Velocity")
|
||||||
|
@@ -20,6 +20,7 @@
|
|||||||
import bpy
|
import bpy
|
||||||
from bpy.types import Panel, Menu
|
from bpy.types import Panel, Menu
|
||||||
|
|
||||||
|
|
||||||
class FLUID_MT_presets(Menu):
|
class FLUID_MT_presets(Menu):
|
||||||
bl_label = "Fluid Presets"
|
bl_label = "Fluid Presets"
|
||||||
preset_subdir = "fluid"
|
preset_subdir = "fluid"
|
||||||
@@ -232,7 +233,7 @@ class PHYSICS_PT_domain_gravity(PhysicButtonsPanel, Panel):
|
|||||||
sub.menu("FLUID_MT_presets", text=bpy.types.FLUID_MT_presets.bl_label)
|
sub.menu("FLUID_MT_presets", text=bpy.types.FLUID_MT_presets.bl_label)
|
||||||
sub.operator("fluid.preset_add", text="", icon='ZOOMIN')
|
sub.operator("fluid.preset_add", text="", icon='ZOOMIN')
|
||||||
sub.operator("fluid.preset_add", text="", icon='ZOOMOUT').remove_active = True
|
sub.operator("fluid.preset_add", text="", icon='ZOOMOUT').remove_active = True
|
||||||
|
|
||||||
subsub = col.column(align=True)
|
subsub = col.column(align=True)
|
||||||
subsub.prop(fluid, "viscosity_base", text="Base")
|
subsub.prop(fluid, "viscosity_base", text="Base")
|
||||||
subsub.prop(fluid, "viscosity_exponent", text="Exponent", slider=True)
|
subsub.prop(fluid, "viscosity_exponent", text="Exponent", slider=True)
|
||||||
|
@@ -228,10 +228,10 @@ static EdgeLoopPair *edbm_ripsel_looptag_helper(BMesh *bm)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
e_first = e;
|
|
||||||
|
|
||||||
/* initialize */
|
/* initialize */
|
||||||
|
e_first = e;
|
||||||
v_step = e_first->v1;
|
v_step = e_first->v1;
|
||||||
|
e_step = NULL; /* quiet warning, will never remain this value */
|
||||||
|
|
||||||
uid_start = uid;
|
uid_start = uid;
|
||||||
while ((e = edbm_ripsel_edge_mark_step(v_step, uid))) {
|
while ((e = edbm_ripsel_edge_mark_step(v_step, uid))) {
|
||||||
|
Reference in New Issue
Block a user