[Addon] Wazou's Pie Menus

Hi,

I made my own Pie menus, it’s mossely the same as the official, except that I added some tools and pies.

You can see my video of the pie Menus.

The ghitub link > https://github.com/pitiwazou/Scripts-Blender/blob/Older-Scripts/Wazou_Pie_Menus

Some pictures.




For some pie menus like the Object/Edit mode, you can choose directly the component you want, no need to enter in edit mode and then choose the component.
Same for the snapping pie etc.

For the join Area button, you just need to drag the mouse on his direction, don’t clic on the button.

The shortcuts are :

  • Object/Edit mode > Tab
  • Views > Space
  • Brosses Sculpt > w et alt + W
  • Cursor/Origin > Shift + S
  • Manipulators > Ctrl + Space
  • Snapping > Ctrl + Shift + Tab
  • Orientation > Alt + Space
  • Retopo > Shift + Clic Droit
  • Shading > Z
  • Views Ortho > Q
  • Pivot > Alt + Q
  • Proportionnal Editing > ;

Hope you like it :wink:

You can test my RMB Pie Menu > https://github.com/pitiwazou/Scripts-Blender/blob/master/Wazou_RMB_Pie_Menu

6 Likes

Hey Céd,

First off let me say thanks for this lovely pie cooking!!

Just last night night I was going through your script and the screenshots you posted in the other PM thread and was thinking how it would be nice to have All the screenshots in one post. Now that you’ve officially released this as an addon, I think the first thread could use having a screenshot of all the PMs. This could also help if there’s some bugs so people can see if there’s any discrepancies. I feel it’s just quicker than going through the video.

Which brings me to a couple of bugs I’ve experienced that I was able to track comparing to the screenshots in your old PM thread. I’ve downloaded the latest version of the addon from the link and it’s still the same.

It’s in the Retopo Pie. Basically 2 of the slices were not present.
By default I did not get the GStretch (#4) and setup.retopomesh+object.automirror(#1)
http://edge-loop.com/images/blender/wazouPie/wazPie_retopo_01.jpg
For #4, I had to change the pie.operator to (“mesh.looptools_gstretch”, text=“GStretch”, icon=‘GREASEPENCIL’)
http://edge-loop.com/images/blender/wazouPie/wazPie_retopo_02.jpg
Any idea why this is so on my system and what I could do to get #1 in ?

I love the TAB Pie, this is really well crafted. The operators to go directly into desired subobject are great. It’s a welcome click-saver.

Thanks again! Time to set some custom hotkeys on these babies :slight_smile:

Thx for the Gstretch, I will fix that :wink:

For the retopo Pie, you need iceking tool and auto mirror. I put them in my retopology Tab Addon.
http://www.blenderartists.org/forum/showthread.php?344060-Retopology-Tools

I mixed some great addons in one Tab.

I wanted to make this pie Off and if people want include it, just press the button in the preference editor.
I will find how to do that.

There is all the pies I have in this Addon.

http://uppix.3dvf.com/images/htjOc.jpg

Ok, it’s fixed !

I will Add a part of the code of the automirror in the script to not have to install it.
I will check with my friend for that.

Thanks!

Not a problem to install it. I just wasn’t aware of it.
I actually do have the Sculpting:Iceking’s Tools active, must be an older version I got then. I’ll grab the one from the link you provided.

I will try to make this pie optional in the addon tab.

@pitiwazou
if i want to select multiple component " vertex, edge, face " with shift it activated the droid pie retopo menu really annoying

@pitiwazou
wen in texture paint mode " w, alt+w " show the sculpt pie menu it suppose to be relate to paint brush did i say thanks for those nice pie

Hum, I sould change the shortcup for the sculpt pie I Think.

Ok, for the pie retopo, you use the Right clic for selection, I use the left mouse button for selection.
Hum, I should fine another shortcut too :confused:

If someone have an idea of shortcut for those pies :wink:

I wouldn’t worry about hotkeys really, as long as it works for you. You’ll never be able to make it perfect for everyone. The least we can do is remap the hotkeys to our personal liking. That at least is pretty straight forward.

I’ll see if I can reverse engnineer your script and hack a Proportional Editing Pie based on your Snapping Pie. Also see if we can have the Sculpt Brushes appear only in SculptMode. I’ll post here if I get it going.

Edit:
Here’s an edit to your script if you want to restrict the two Sculpt Pies to the Sculpt Mode:


#Sculpt Pie Menu
        km = wm.keyconfigs.addon.keymaps.new(name='Sculpt')
        kmi = km.keymap_items.new('wm.call_menu_pie', 'W', 'PRESS').properties.name = "pie.sculpt"
        
        #Sculpt Pie Menu 2
        km = wm.keyconfigs.addon.keymaps.new(name='Sculpt')
        kmi = km.keymap_items.new('wm.call_menu_pie', 'W', 'PRESS', alt=True).properties.name = "pie.sculpttwo"
 

Thx OrangE :wink:

I will make the proportionnal editing pie !

I hope you don’t mind me posting in your thread.

I managed to hack the Proportional Editing Pie. But because I’ve already edited your script a bit, I think it’s easier if I post just the relevant sections.
This is in hope you haven’t already completed it, so you can just copy/paste this stuff in relevant sections.

This is how it looks
http://edge-loop.com/images/blender/wazouPie/WazouProportionalEdit.jpg

Edit:



###############################
#      Proportional Edit      #               
###############################
class ProportionalEdit(bpy.types.Operator):
    bl_idname = "proportional.active"
    bl_label = "Proportional Edit"
    
    def execute(self, context):
        layout = self.layout 
        
        if bpy.context.scene.tool_settings.use_proportional_edit_objects == (True):
            bpy.context.scene.tool_settings.use_proportional_edit_objects = False
            
        elif bpy.context.scene.tool_settings.use_proportional_edit_objects == (False) :
             bpy.context.scene.tool_settings.use_proportional_edit_objects = True

        return {'FINISHED'}


class ProportionalSmooth(bpy.types.Operator):
    bl_idname = "proportional.smooth"
    bl_label = "Proportional Smooth"
    
    def execute(self, context):
        layout = self.layout
        if bpy.context.scene.tool_settings.use_proportional_edit_objects == (False) : 
            bpy.context.scene.tool_settings.use_proportional_edit_objects = True
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'SMOOTH'
            
        if bpy.context.scene.tool_settings.proportional_edit_falloff != 'SMOOTH': 
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'SMOOTH' 
        return {'FINISHED'}    

class ProportionalSphere(bpy.types.Operator):
    bl_idname = "proportional.sphere"
    bl_label = "Proportional Sphere"
    
    def execute(self, context):
        layout = self.layout
        if bpy.context.scene.tool_settings.use_proportional_edit_objects == (False) : 
            bpy.context.scene.tool_settings.use_proportional_edit_objects = True
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'SPHERE'
            
        if bpy.context.scene.tool_settings.proportional_edit_falloff != 'SPHERE': 
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'SPHERE' 
        return {'FINISHED'}    

class ProportionalRoot(bpy.types.Operator):
    bl_idname = "proportional.root"
    bl_label = "Proportional Root"
    
    def execute(self, context):
        layout = self.layout
        if bpy.context.scene.tool_settings.use_proportional_edit_objects == (False) : 
            bpy.context.scene.tool_settings.use_proportional_edit_objects = True
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'ROOT'
            
        if bpy.context.scene.tool_settings.proportional_edit_falloff != 'ROOT': 
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'ROOT' 
        return {'FINISHED'}
    
class ProportionalSharp(bpy.types.Operator):
    bl_idname = "proportional.sharp"
    bl_label = "Proportional Sharp"
    
    def execute(self, context):
        layout = self.layout
        if bpy.context.scene.tool_settings.use_proportional_edit_objects == (False) : 
            bpy.context.scene.tool_settings.use_proportional_edit_objects = True
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'SHARP'
            
        if bpy.context.scene.tool_settings.proportional_edit_falloff != 'SHARP': 
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'SHARP' 
        return {'FINISHED'}
    
class ProportionalLinear(bpy.types.Operator):
    bl_idname = "proportional.linear"
    bl_label = "Proportional Linear"
    
    def execute(self, context):
        layout = self.layout
        if bpy.context.scene.tool_settings.use_proportional_edit_objects == (False) : 
            bpy.context.scene.tool_settings.use_proportional_edit_objects = True
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'LINEAR'
            
        if bpy.context.scene.tool_settings.proportional_edit_falloff != 'LINEAR': 
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'LINEAR' 
        return {'FINISHED'}  

class ProportionalConstant(bpy.types.Operator):
    bl_idname = "proportional.constant"
    bl_label = "Proportional Constant"
    
    def execute(self, context):
        layout = self.layout
        if bpy.context.scene.tool_settings.use_proportional_edit_objects == (False) : 
            bpy.context.scene.tool_settings.use_proportional_edit_objects = True
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'CONSTANT'
            
        if bpy.context.scene.tool_settings.proportional_edit_falloff != 'CONSTANT': 
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'CONSTANT'
        return {'FINISHED'}  

class ProportionalRandom(bpy.types.Operator):
    bl_idname = "proportional.random"
    bl_label = "Proportional Random"

    def execute(self, context):
        layout = self.layout
        if bpy.context.scene.tool_settings.use_proportional_edit_objects == (False) : 
            bpy.context.scene.tool_settings.use_proportional_edit_objects = True
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'RANDOM'
            
        if bpy.context.scene.tool_settings.proportional_edit_falloff != 'RANDOM': 
            bpy.context.scene.tool_settings.proportional_edit_falloff = 'RANDOM'
        return {'FINISHED'} 


#Pie ProportionalEdit
class PieProportional(Menu):
    bl_idname = "pie.proportional"
    bl_label = "Pie ProportionalEdit"

    def draw(self, context):
        layout = self.layout
        
        pie = layout.menu_pie()
        #4 - LEFT
        pie.operator("proportional.sphere", text="Sphere", icon='SPHERECURVE')
        #6 - RIGHT
        pie.operator("proportional.root", text="Root", icon='ROOTCURVE')
        #2 - BOTTOM
        pie.operator("proportional.smooth", text="Smooth", icon='SMOOTHCURVE')
        #8 - TOP
        pie.operator("proportional.active", text="Proportional On/Off", icon='PROP_ON')
        #7 - TOP - LEFT 
        pie.operator("proportional.linear", text="Linear", icon='LINCURVE')
        #9 - TOP - RIGHT
        pie.operator("proportional.sharp", text="Sharp", icon='SHARPCURVE')
        #1 - BOTTOM - LEFT
        pie.operator("proportional.constant", text="Constant", icon='NOCURVE')
        #3 - BOTTOM - RIGHT
        pie.operator("proportional.random", text="Random", icon='RNDCURVE')
           
addon_keymaps = []

def register():
    # ProportionalEdit
    bpy.utils.register_class(PieProportional)
    bpy.utils.register_class(ProportionalEdit)
    bpy.utils.register_class(ProportionalSmooth)
    bpy.utils.register_class(ProportionalSphere)
    bpy.utils.register_class(ProportionalRoot)
    bpy.utils.register_class(ProportionalSharp)
    bpy.utils.register_class(ProportionalLinear)
    bpy.utils.register_class(ProportionalConstant)
    bpy.utils.register_class(ProportionalRandom)
    
# Keympa Config 

    wm = bpy.context.window_manager

    if wm.keyconfigs.addon:
        #ProportionalEdit
        km = wm.keyconfigs.addon.keymaps.new(name = '3D View Generic', space_type = 'VIEW_3D')
        kmi = km.keymap_items.new('wm.call_menu_pie', 'O', 'PRESS').properties.name = "pie.proportional"

        addon_keymaps.append(km)

# Register / Unregister Classes
def unregister():
    # ProportionalEdit
    bpy.utils.unregister_class(PieProportional)
    bpy.utils.unregister_class(ProportionalEdit)
    bpy.utils.unregister_class(ProportionalSmooth)
    bpy.utils.unregister_class(ProportionalSphere)
    bpy.utils.unregister_class(ProportionalRoot)
    bpy.utils.unregister_class(ProportionalSharp)
    bpy.utils.unregister_class(ProportionalLinear)
    bpy.utils.unregister_class(ProportionalConstant)
    bpy.utils.unregister_class(ProportionalRandom)

    wm = bpy.context.window_manager

    if wm.keyconfigs.addon:
        for km in addon_keymaps:
            for kmi in km.keymap_items:
                km.keymap_items.remove(kmi)

            wm.keyconfigs.addon.keymaps.remove(km)

    # clear the list
    del addon_keymaps[:]

if __name__ == "__main__":
    register()

In the same time, I dit it !

Our code are different as you can see ^^


########################
#  Proportionnal Edit  #               
########################


class ProportionnalVariable(bpy.types.Operator):
    bl_idname = "proportionnal.variable"
    bl_label = "Proportionnal Variable"
    variable = bpy.props.StringProperty()


    @classmethod
    def poll(cls, context):
        return True


    def execute(self, context):
        bpy.context.scene.tool_settings.proportional_edit_falloff = self.variable
        return {'FINISHED'} 
    
class UseProportionnal(bpy.types.Operator):
    bl_idname = "use.proportionnal"
    bl_label = "Use Proportionnal"
    
    def execute(self, context):
        ob = context
        if ob.mode == 'OBJECT':
            if bpy.context.scene.tool_settings.use_proportional_edit_objects == (False):
                bpy.context.scene.tool_settings.use_proportional_edit_objects = True
            elif bpy.context.scene.tool_settings.use_proportional_edit_objects == (True):
                bpy.context.scene.tool_settings.use_proportional_edit_objects = False
            return {'FINISHED'}
        
        elif ob.mode == 'EDIT_MESH':
            if bpy.context.scene.tool_settings.proportional_edit == ('DISABLED'):
                bpy.context.scene.tool_settings.proportional_edit = 'ENABLED'
            elif bpy.context.scene.tool_settings.proportional_edit == ('ENABLED'):
                bpy.context.scene.tool_settings.proportional_edit = 'DISABLED'
            return {'FINISHED'}



#Pie Proportionnal       
class PieProportionnalEditing(Menu):
    bl_idname = "pie.proportionnalediting"
    bl_label = "Pie Proportionnal Editing"


    def draw(self, context):
        layout = self.layout
        
        pie = layout.menu_pie()
        #4 - LEFT
        pie.operator("proportionnal.variable", text="CONSTANT", icon='NOCURVE').variable = 'CONSTANT'
        #6 - RIGHT
        pie.operator("proportionnal.variable", text="Sphere", icon='SPHERECURVE').variable = 'SPHERE'
        #2 - BOTTOM
        pie.operator("proportionnal.variable", text="Sharp", icon='SHARPCURVE').variable = 'SHARP'
        #8 - TOP
        pie.operator("use.proportionnal", text="proportional Editing", icon='PROP_ON')
        #7 - TOP - LEFT 
        pie.operator("proportionnal.variable", text="Random", icon='RNDCURVE').variable = 'RANDOM'
        #9 - TOP - RIGHT
        pie.operator("proportionnal.variable", text="Smooth", icon='SMOOTHCURVE').variable = 'SMOOTH'
        #1 - BOTTOM - LEFT
        pie.operator("proportionnal.variable", text="Linear", icon='LINCURVE').variable = 'LINEAR'
        #3 - BOTTOM - RIGHT 
        pie.operator("proportionnal.variable", text="Root", icon='ROOTCURVE').variable = 'ROOT'  


I don’t manage to use the O button for this one :frowning: So I put the ‘;’

I put the snapping shortcut to Shift + Tab, it’s easier than Ctrl+Shift+Tab ^^

For the proportionnal Editing, if I use the ‘O’ button, my pie don’t popup.

In the Object Mode it works. For the Edit Mode, you have to disable the default (proportionalEdit) hotkey.

Weird, not on my computer, Object and Edit gives the same result.

hi, I think remapping existing features to new keys is not good as it could be.
For snapping Shift/S if your piefieing a exsisting menu, why not just use Shift/S for consistancy?
An example of this is the w key specials in edit mode, to big for pies but a pie could be made with nice tools & mapped to Alt w.
this way pies can replace menu’s where they already exist or map to a similar key or ‘Key extension’ (adding Alt in this case).
this will make the user experience much better.

I’m trying to keep the original shortcuts, shift+S for the cursor and Shift+Tab for the snapping.
After, if peoples install a pie menu addon, I think it’s for using the sames tools with the same shortcuts.

Little update for the shade Smooth and shader Flat, it’s work watever the mod, Edit or Object.

http://uppix.3dvf.com/images/wu5F.gif

Installed and when I enabled in User Preferences, I get an error at line 1417 in register kmi.properties.name = ‘pie.objectitmode’ ‘OperatorProperties’ object has no attribute ‘name’ - MAC OS X Blender 2.71

Weird, I don’t have Mac Os, so it will be difficult for me to test.

I just uploaded the code and reinstall it on my Blender and it work fine.

I just added this menu in the Addon panel too.