diff options
author | Tamito Kajiyama <rd6t-kjym@asahi-net.or.jp> | 2014-05-03 13:51:53 +0400 |
---|---|---|
committer | Tamito Kajiyama <rd6t-kjym@asahi-net.or.jp> | 2014-05-03 13:54:59 +0400 |
commit | b7f085d9c128f31d576c732c6439b5a71e8922ee (patch) | |
tree | 8a1fdc2e95470f61d9121b18b125dc272e87d536 /release/scripts/startup/bl_ui/properties_texture.py | |
parent | 6ec2d72eca618be05e9bf0723886b10e6d5efa46 (diff) |
Patch D246: Texture Marks for freestyle strokes, written and contributed by Paolo Acampora.
Reviewers: brecht, kjym3, #freestyle
Reviewed By: brecht, kjym3
Differential Revision: https://developer.blender.org/D246
Diffstat (limited to 'release/scripts/startup/bl_ui/properties_texture.py')
-rw-r--r-- | release/scripts/startup/bl_ui/properties_texture.py | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/release/scripts/startup/bl_ui/properties_texture.py b/release/scripts/startup/bl_ui/properties_texture.py index 009309479ec..9aa137ca9ea 100644 --- a/release/scripts/startup/bl_ui/properties_texture.py +++ b/release/scripts/startup/bl_ui/properties_texture.py @@ -25,6 +25,7 @@ from bpy.types import (Brush, Material, Object, ParticleSettings, + FreestyleLineStyle, Texture, World) @@ -94,6 +95,10 @@ def context_tex_datablock(context): if idblock: return idblock + idblock = context.line_style + if idblock: + return idblock + if context.particle_system: idblock = context.particle_system.settings @@ -134,6 +139,7 @@ class TEXTURE_PT_context_texture(TextureButtonsPanel, Panel): context.world or context.lamp or context.texture or + context.line_style or context.particle_system or isinstance(context.space_data.pin_id, ParticleSettings) or context.texture_user) and @@ -952,11 +958,28 @@ class TEXTURE_PT_mapping(TextureSlotPanel, Panel): split.label(text="Object:") split.prop(tex, "object", text="") + elif tex.texture_coords == 'ALONG_STROKE': + split = layout.split(percentage=0.3) + split.label(text="Use Tips:") + split.prop(tex, "use_tips", text="") + if isinstance(idblock, Brush): if context.sculpt_object or context.image_paint_object: brush_texture_settings(layout, idblock, context.sculpt_object) else: - if isinstance(idblock, Material): + if isinstance(idblock, FreestyleLineStyle): + split = layout.split(percentage=0.3) + split.label(text="Projection:") + split.prop(tex, "mapping", text="") + + split = layout.split(percentage=0.3) + split.separator() + row = split.row() + row.prop(tex, "mapping_x", text="") + row.prop(tex, "mapping_y", text="") + row.prop(tex, "mapping_z", text="") + + elif isinstance(idblock, Material): split = layout.split(percentage=0.3) split.label(text="Projection:") split.prop(tex, "mapping", text="") @@ -1129,6 +1152,15 @@ class TEXTURE_PT_influence(TextureSlotPanel, Panel): factor_but(col, "use_map_kink", "kink_factor", "Kink") factor_but(col, "use_map_rough", "rough_factor", "Rough") + elif isinstance(idblock, FreestyleLineStyle): + split = layout.split() + + col = split.column() + factor_but(col, "use_map_color_diffuse", "diffuse_color_factor", "Color") + col = split.column() + factor_but(col, "use_map_alpha", "alpha_factor", "Alpha") + + layout.separator() if not isinstance(idblock, ParticleSettings): |