cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

wireframe opacity

wireframe opacity

I really need to turn down wireframe opacity so it’s slightly transparent, especially when im working with lidar scanned sets and matching meshes on plates.

21 Comments
20160926002
Observer

While the feature is documented and available under "Set wireframe transparency," I needed a dedicated tool in my workflow to quickly toggle between 0.25 and 1 alpha. Therefore, I created this Python script, which you may find useful.

import maya.cmds as cmds
import maya.mel as mel

def set_polymesh_dormant_alpha(alpha):
    current_color = cmds.displayRGBColor('polymeshDormant', query=True)
    cmds.displayRGBColor('polymeshDormant', current_color[0], current_color[1], current_color[2], alpha)
    mel.eval("updateColorPrefUI()")

def create_alpha_control_ui():
    if cmds.window("alphaControlWin", exists=True):
        cmds.deleteUI("alphaControlWin")

    cmds.window("alphaControlWin", title="Polygon Alpha Control", widthHeight=(200, 100))
    cmds.columnLayout(adjustableColumn=True)
    
    cmds.button(label="Set Alpha to 1.0", command=lambda _: set_polymesh_dormant_alpha(1.0))
    cmds.button(label="Set Alpha to 0.25", command=lambda _: set_polymesh_dormant_alpha(0.25))

    cmds.showWindow("alphaControlWin")

create_alpha_control_ui()

 

Can't find what you're looking for? Ask the community or share your knowledge.

Submit Idea