From 576e579925d205a44dd347fca3646f5c749a60a6 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Tue, 30 Apr 2013 16:07:52 +0000 Subject: More painting fixes: * 2D image painting with textures that contained alpha did not work correctly, had been broken for a while. * 2D image panels texture (mask) panels showed wrong buttons for texture overlay. * Texture map mode 3D now also uses masking, like Tiled and Stencil the texture does not move along with the brush so it works fine. * 2D image paint View mapping did not work correct, especially noticeable with Rake rotation. * Masking is now disabled for the smear tool, this can't really work because the original image is constantly changing and gave artifacts. --- release/scripts/startup/bl_ui/space_image.py | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) (limited to 'release') diff --git a/release/scripts/startup/bl_ui/space_image.py b/release/scripts/startup/bl_ui/space_image.py index 458266aec46..e4c033d7223 100644 --- a/release/scripts/startup/bl_ui/space_image.py +++ b/release/scripts/startup/bl_ui/space_image.py @@ -728,6 +728,7 @@ class IMAGE_PT_tools_brush_texture(BrushButtonsPanel, Panel): toolsettings = context.tool_settings.image_paint brush = toolsettings.brush + tex_slot = brush.texture_slot col = layout.column() col.template_ID_preview(brush, "texture", new="texture.new", rows=3, cols=8) @@ -740,13 +741,15 @@ class IMAGE_PT_tools_brush_texture(BrushButtonsPanel, Panel): col.label(text="Overlay:") row = col.row() - if brush.use_primary_overlay: - row.prop(brush, "use_primary_overlay", toggle=True, text="", icon='RESTRICT_VIEW_OFF') - else: - row.prop(brush, "use_primary_overlay", toggle=True, text="", icon='RESTRICT_VIEW_ON') + if tex_slot.map_mode != 'STENCIL': + if brush.use_primary_overlay: + row.prop(brush, "use_primary_overlay", toggle=True, text="", icon='RESTRICT_VIEW_OFF') + else: + row.prop(brush, "use_primary_overlay", toggle=True, text="", icon='RESTRICT_VIEW_ON') + sub = row.row() sub.prop(brush, "texture_overlay_alpha", text="Alpha") - sub.prop(brush, "use_cursor_overlay_override", toggle=True, text="", icon='BRUSH_DATA') + sub.prop(brush, "use_primary_overlay_override", toggle=True, text="", icon='BRUSH_DATA') @@ -778,8 +781,8 @@ class IMAGE_PT_tools_mask_texture(BrushButtonsPanel, Panel): row.prop(brush, "use_secondary_overlay", toggle=True, text="", icon='RESTRICT_VIEW_ON') sub = row.row() - sub.prop(brush, "texture_overlay_alpha", text="Alpha") - sub.prop(brush, "use_cursor_overlay_override", toggle=True, text="", icon='BRUSH_DATA') + sub.prop(brush, "mask_overlay_alpha", text="Alpha") + sub.prop(brush, "use_secondary_overlay_override", toggle=True, text="", icon='BRUSH_DATA') class IMAGE_PT_tools_brush_tool(BrushButtonsPanel, Panel): -- cgit v1.2.3