本文整理汇总了Python中bpy.props.FloatProperty方法的典型用法代码示例。如果您正苦于以下问题:Python props.FloatProperty方法的具体用法?Python props.FloatProperty怎么用?Python props.FloatProperty使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类bpy.props
的用法示例。
在下文中一共展示了props.FloatProperty方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: init_props
# 需要导入模块: from bpy import props [as 别名]
# 或者: from bpy.props import FloatProperty [as 别名]
def init_props(scene):
scene.muv_props = MUV_Properties()
scene.muv_uvbb_cp_size = FloatProperty(
name="Size",
description="Control Point Size",
default=6.0,
min=3.0,
max=100.0)
scene.muv_uvbb_cp_react_size = FloatProperty(
name="React Size",
description="Size event fired",
default=10.0,
min=3.0,
max=100.0)
scene.muv_uvbb_uniform_scaling = BoolProperty(
name="Uniform Scaling",
description="Enable Uniform Scaling",
default=False)
scene.muv_texproj_tex_magnitude = FloatProperty(
name="Magnitude",
description="Texture Magnitude.",
default=0.5,
min=0.0,
max=100.0)
scene.muv_texproj_tex_image = EnumProperty(
name="Image",
description="Texture Image.",
items=get_loaded_texture_name)
scene.muv_texproj_tex_transparency = FloatProperty(
name="Transparency",
description="Texture Transparency.",
default=0.2,
min=0.0,
max=1.0)
示例2: register
# 需要导入模块: from bpy import props [as 别名]
# 或者: from bpy.props import FloatProperty [as 别名]
def register():
Scene.archipack_progress = FloatProperty(
options={'SKIP_SAVE'},
default=-1,
subtype='PERCENTAGE',
precision=1,
min=-1,
soft_min=0,
soft_max=100,
max=101,
update=update)
Scene.archipack_progress_text = StringProperty(
options={'SKIP_SAVE'},
default="Progress",
update=update)
global info_header_draw
info_header_draw = bpy.types.INFO_HT_header.draw
def info_draw(self, context):
global info_header_draw
info_header_draw(self, context)
if (context.scene.archipack_progress > -1 and
context.scene.archipack_progress < 101):
self.layout.separator()
text = context.scene.archipack_progress_text
self.layout.prop(context.scene,
"archipack_progress",
text=text,
slider=True)
bpy.types.INFO_HT_header.draw = info_draw