This file contains hidden or 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
from SimpleCV import Image, Display, Color | |
from multiprocessing import Process, Queue | |
import numpy as np | |
import cv2 | |
import copy | |
import sys | |
# caclulate the value of a row | |
# using the integral image | |
def idxToSum(x1,x2,y,integral): | |
# assume x2 > x1 |
This file contains hidden or 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
def is_firefly(rgba): | |
if (any(rgba) == 1.0) and (sum(rgba) > 3.8): | |
return True | |
""" found coordinates to look at """ | |
pixels_of_interest = [[28,764]] | |
#[ [424,706], [178,864], [67,68], [58,110], | |
# [16,123], [21,169], [81,218], [49,422], | |
# [56,603], [29,637], [60,643], [31,686], |
This file contains hidden or 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 | |
D = bpy.data | |
test_file = 'firefly_test_pattern_2.tga' | |
# my test image is 24 px wide and 7 px heigh | |
# download here if you want to test along. | |
#alias if you can | |
img = D.images[test_file] |
This file contains hidden or 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
# https://blender.stackexchange.com/q/57306/3710 | |
bl_info = { | |
"name": "Add-on Template", | |
"description": "", | |
"author": "p2or", | |
"version": (0, 0, 3), | |
"blender": (2, 80, 0), | |
"location": "3D View > Tools", | |
"warning": "", # used for warning icon and text in addons panel |
This file contains hidden or 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
using UnityEngine; | |
public class DistanceJoint3D : MonoBehaviour { | |
public Transform ConnectedRigidbody; | |
public bool DetermineDistanceOnStart = true; | |
public float Distance; | |
public float Spring = 0.1f; | |
public float Damper = 5f; |
This file contains hidden or 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
using UnityEngine; | |
using UnityEditor; | |
using System.IO; | |
using System.Collections; | |
using System.Collections.Generic; | |
public class CleanUpWindow : EditorWindow | |
{ | |
bool groupEnabled = true; | |
List<string> usedAssets = new List<string>(); |
This file contains hidden or 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
#!/usr/bin/env python | |
# Will split a png cubemap/skymap image produced by blender into 6 separated image files for use in a skybox within unity | |
# Requires Python Imaging Library > http://www.pythonware.com/products/pil/ | |
# The author takes no responsibility for any damage this script might cause, | |
# feel free to use, change and or share this script. | |
# 2013-07, CanOfColliders, [email protected] | |
from PIL import Image |
This file contains hidden or 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
Windows Registry Editor Version 5.00 | |
; | |
; Adds 'Open in Atom' to context menu (when you right click) in Windows Explorer. | |
; | |
; Based on https://github.com/Zren/atom-windows-context-menu. It didn't work | |
; https://github.com/Zren/atom-windows-context-menu/issues/1. | |
; | |
; Save this file to disk with a .reg extension. Replace C:\\Atom\\atom.exe with | |
; the path to the atom executable on your machine. |
This file contains hidden or 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
<?php | |
$base_dir = __DIR__; // Absolute path to your installation, ex: /var/www/mywebsite | |
$doc_root = preg_replace("!${_SERVER['SCRIPT_NAME']}$!", '', $_SERVER['SCRIPT_FILENAME']); # ex: /var/www | |
$base_url = preg_replace("!^${doc_root}!", '', $base_dir); # ex: '' or '/mywebsite' | |
$protocol = empty($_SERVER['HTTPS']) ? 'http' : 'https'; | |
$port = $_SERVER['SERVER_PORT']; | |
$disp_port = ($protocol == 'http' && $port == 80 || $protocol == 'https' && $port == 443) ? '' : ":$port"; | |
$domain = $_SERVER['SERVER_NAME']; | |
$full_url = "${protocol}://${domain}${disp_port}${base_url}"; # Ex: 'http://example.com', 'https://example.com/mywebsite', etc. |
This file contains hidden or 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
/* | |
extended javascript for | |
Adobe Indesign 5.5 | |
by | |
PDXIII | |
http://about.me/PDXIII | |
Honestly: It's from fabiantheblind, but I typed it ;-) | |
*/ |