This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
clear() | |
local keyboardIdentifier = '16BFD3AF' | |
lmc_print_devices() | |
-- assign logical name to macro keyboard | |
if keyboardIdentifier == '0000AAA' then | |
lmc_assign_keyboard('MACROS'); | |
else lmc_device_set_name('MACROS', keyboardIdentifier); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set encoding=utf-8 | |
set fileencoding=utf-8 | |
filetype plugin indent on | |
syntax on | |
set smartindent | |
set expandtab | |
set ignorecase | |
set smartcase |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# quick add pbr texture names to properties | |
# used in grafkit2 | |
for material in bpy.data.materials: | |
for key in ["metalness", "normal", "roughness"]: | |
material["mat_{0}".format(key)] = "pbr_{0}_{1}.jpg".format(material.name, key) | |
# a bit refined version, which add emissive map if emission was set | |
for material in bpy.data.materials: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import bpy | |
def do_bake(scene): | |
""" This thing tries to bake all the object animations | |
and camera movement into a single track | |
Drawback: it eleminates scenegraph hierarchy and flattens everzthing | |
This suposed to be it, but fingers crossed: | |
https://wiki.blender.org/index.php/Dev:2.4/Source/Animation/AnimationBaking |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
env=~/.ssh/agent.env | |
agent_load_env () { test -f "$env" && . "$env" >| /dev/null ; } | |
agent_start () { | |
(umask 077; ssh-agent >| "$env") | |
. "$env" >| /dev/null ; } | |
agent_load_env |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set encoding=utf-8 | |
set fileencoding=utf-8 | |
filetype plugin indent on | |
syntax on | |
set smartindent | |
set expandtab | |
set ignorecase | |
set smartcase |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"name": "Launch Chrome against localhost, with sourcemaps", | |
"type": "chrome", | |
"request": "launch", | |
"url": "http://localhost:3000", | |
"sourceMaps": true, | |
"webRoot": "${workspaceRoot}/src/ts/main.ts" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* forward differencing method for bezier curve */ | |
void BKE_curve_forward_diff_bezier(float q0, float q1, float q2, float q3, float *p, int it, int stride) | |
{ | |
float rt0, rt1, rt2, rt3, f; | |
int a; | |
f = (float)it; | |
rt0 = q0; | |
rt1 = 3.0f * (q1 - q0) / f; | |
f *= f; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
import xml.etree.ElementTree as ET | |
class XMLBuilder(object): | |
def __init__(self, _outfile): | |
self._outfile = _outfile | |
self._outXML = None | |
def __enter__(self): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
IHR stands for interpolated HiRes. | |
This basically interpolates two HiRes images, one in even frames, and the | |
other in odd frames resulting in more colors, and up to 4 colors per 8x8 | |
block. The selection of colors are limited though: they can be a mix of the | |
colors selected for the two source planes. It also limits mixing that if two | |
colors which supposed to make the displayed color are too far from each | |
other, the image will noticably flicker, and will be tiring for the eye to | |
look at it (Mixing black and white would result in 25Hz or 30Hz pratical | |
update rate what is simply miserable). There are several combinations though |