Skip to content

Instantly share code, notes, and snippets.

View PeterDrakeNichols's full-sized avatar

Pete PeterDrakeNichols

View GitHub Profile
@Onefabis
Onefabis / AutoRibbon
Last active October 31, 2025 15:59
Create ribbon from selection
'''
1. Launch the script with the command:
import ribb_on
ribb_on.makeRibbSurface()
This will create NURBS surface which goes through all selected objects that need to be snapped to that surface.
After that you will be able to correct the shape of this surface by rotating the profile curve (or maybe scale it). After that you can delete both curves (profile and path)
2. Launch the second script:
import ribb_on
ribb_on.ribbMake( 3, 'parent', 1, 0 )
Where:
"""
Warning: The mirror functionnality of OMTK is in alpha stage. Use it at your own risk!
Usage example:
# Step 1: Add attributes
for obj in pymel.selected():
add_mirror_attr(obj)
# Step 2: Manually configure attributes
# python api2.0 setWeights(),setWeight()
# http://ueta.hateblo.jp/entry/2015/08/24/102937
import time
import maya.api.OpenMaya as OpenMaya2
import maya.api.OpenMayaAnim as OpenMayaAnim2
#_time = time.time
_time = time.clock
@mclavan
mclavan / rr_wrap.py
Last active September 26, 2023 05:35
Ryan Roberts - Wrap Deformer
'''
Ryan Roberts - Wrap Deformer
rr_wrap.py
Description:
Ryan Robers created a simple function to create a wrap deformer.
The wrap deformer needs a little more than the deform command to get working.
Michael Clavan
I wanted to have the function also return the deformer to the user. So, my contributions are pretty minor.
I converted the wrap deformer into a pynode object type pm.nt.Wrap.
@mclavan
mclavan / connecting.py
Last active May 17, 2024 06:08
Connecting Nodes with pymel.
'''
This script will create an attribute called joint_vis on the first selected and then connect it to the visibility to the second selected.
You wll need to have two object in your scene selected to make this example work.
Mainly this script is a demo of connecting and disconecting attributes using pymel.
'''
import pymel.core as pm
selected = pm.ls(selection=True)
@icaoberg
icaoberg / remove.sh
Created March 6, 2013 21:32
[Git] Remove all *.pyc files from your git repository
#!/bin/bash
find . -name "*.pyc" -exec git rm {} \;
git commit -m "Removed compiled python files in distribution left after last commit"