Instantly share code, notes, and snippets.

View AutoHotkey.ahk
; Capslock remapping should be done in the registry to avoid key repeat issues in here
; Capslock::Ctrl
; WheelUp::
; Send {WheelDown}
; Return
; WheelDown::
; Send {WheelUp}
; Return
View log.py
import os
import sys
import bpy
output = None
input = None
info = None
error = None
write = None
View export_beziers.py
import os
import bpy
import math
import mathutils
bl_info = {
'name': 'Export Beziers (.svg)',
'author': 'Tamas Kemenczy',
'version': (0, 1),
'blender': (2, 6, 9),
View plot.py
import bpy
import bmesh
NAME = '(Plot)'
def line(gen):
scene = bpy.context.scene
objects = bpy.data.objects
if NAME in objects:
View AutoHotKey.ahk
; Capslock remapping should be done in the registry to avoid key repeat issues in here
; Capslock::Ctrl
WheelUp::
Send {WheelDown}
Return
WheelDown::
Send {WheelUp}
Return
View light_vertex_colors.py
import bpy
import math
import mathutils
bl_info = {
'name': 'Light Vertex Colors',
'author': 'Tamas Kemenczy',
'version': (0, 1),
'blender': (2, 6, 3),
'location': 'View3D > Specials > Light Vertex Colors',
View light_vertices.py
import bpy
import math
import mathutils
def magnitude(v):
return math.sqrt(v.x ** 2 + v.y ** 2 + v.z ** 2)
COLOR = mathutils.Color((1, 1, 1))
RADIUS = 10
View acronym.py
#!/usr/bin/env python
import sys
last = ''
punc = ','
while True:
c = sys.stdin.read(1)
if c:
View vector2.js
Vector2.prototype = {
init: function(x, y) {
this.x = x;
this.y = y;
},
copy: function() {
return new Vector2(this.x, this.y);
},
View gist:3859647
$('.art').each(function() {
var el, im, width, height, paper;
width = $(this).data('width');
if (width)
width += 'px';
height = $(this).data('height');
if (height)
height += 'px';
if (window.Raphael && (Raphael.svg || Raphael.vml)) {
el = $('<div>').addClass('svg');