Skip to content

Instantly share code, notes, and snippets.

@keiso
keiso / makeIcon.sh
Last active December 22, 2015 19:59
generate iOS App icons.
#!/bin/sh
#sorce file icon(1024px x 1024px)
ICON1024="Icon1024.png"
sips -Z 512 ${ICON1024} --out icons/iTunesArtwork.png
#sips -Z 1024 ${ICON1024} --out icons/iTunesArtwork@2x.png
#sips -Z 1536 ${ICON1024} --out icons/iTunesArtwork@3x.png
@44kwm20
44kwm20 / 暴れ太鼓.sc
Last active January 24, 2016 14:37
1つ、もしくは2つ以上のサンプルをテンポによって切り分け、それっぽく分解したりエフェクトをかけたりして再生します。
//////////
// 説明
// 1のカッコを実行 > 2にてサンプルのパス、ビートの長さ、音量、確率を入力 >
// 2のカッコを実行 > 3のbpmを設定 > 3のカッコを実行
//
// - 2について -
//・ループさせたいサンプルについて、ビートの長さは4分音符分を"1"とし計算。4/4一小節分は"4"になります。
//・ワンショットで鳴らしたいサンプルについて、ビートの長さを"0"にしてください。
//・確率の部分は「合計して100にする」と言った事は必要ありません。単純に他のサンプルとの比率を記入して下さい。
//
@AngryAnt
AngryAnt / DualDisplay.cs
Last active January 24, 2024 08:26
Example use of the Unity 4.1 AirPlay API - gives a setup with the iOS device as controller of the remote display.
using UnityEngine;
using System.Collections;
/*
Runtime use:
To be available, AirPlay needs to be switched on for the device either via a native AirPlay UI component or
via the global AirPlay mirroring setting. Your options are:
A: Modify your Xcode project to layer a native AirPlay Cocoa control somewhere over your Unity content.
@keiso
keiso / Compile SCSS to CSS.tmCommand
Created October 10, 2012 03:00
TextMate Command "Compile SCSS to CSS"
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>beforeRunningCommand</key>
<string>saveActiveFile</string>
<key>command</key>
<string>#!/bin/sh
SASS_OPTS="-t expanded --scss"
@basuke
basuke / drive.py
Created September 2, 2012 22:49
Create the GPX file from origin and destination using the GoogleMap Direction API. You can use this output for simulate the location apps in Xcode.
#
# python drive.py "origin" ["waypoint" ... ] "destination"
#
# i.e. python drive.py "Union Square, San Francisco" "Ferry Building, San Francisco" 'Bay Bridge' SFO
import sys, json, urllib2, md5, os.path, pprint
from math import radians, sin, cos, atan2, pow, sqrt
from urllib import quote_plus
from xml.sax.saxutils import escape
from optparse import OptionParser