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
var http = require( 'http' ); | |
var url = require( 'url' ); | |
var fs = require( 'fs' ); | |
var path = require( 'path' ); | |
var gzip = require( './lib/gzip' ); | |
var VERBOSE = false; | |
var cache = {}, count = 0; |
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
var texture = THREE.ImageUtils.loadTexture( 'nonPOT.png', new THREE.UVMapping(), function () { | |
var nextPOT = function ( value ) { var pot = 1; while ( pot < value ) pot <<= 1; return pot; }; | |
var canvas = document.createElement( 'canvas' ); | |
canvas.width = nextPOT( texture.image.width ); | |
canvas.height = nextPOT( texture.image.height ); | |
canvas.getContext( '2d' ).drawImage( texture.image, 0, 0, texture.image.width, texture.image.height, 0, 0, canvas.width, canvas.height ); |
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
function logGraph( object, depth ) { | |
var depth = depth || 0, pad = ''; | |
for ( var i = 0; i < depth; i ++ ) pad += ' '; | |
console.log( pad + object.name, object ); | |
for ( var i = 0; i < object.children.length; i ++ ) { |
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
<html> | |
<body> | |
<script> | |
var video = document.createElement( 'video' ); | |
video.autoplay = true; | |
video.addEventListener( 'loadedmetadata', function ( event ) { | |
var scale = 0.5; | |
var width = video.videoWidth * scale; |
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
gptsync |
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
ffmpeg -f x11grab -b 1M -bt 2M -r 30 -s 512x512 -i :0.0+1,53 -an kinect.webm |
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
/* | |
* This file is part of the OpenKinect Project. http://www.openkinect.org | |
* | |
* Copyright (c) 2010 individual OpenKinect contributors. See the CONTRIB file | |
* for details. | |
* | |
* This code is licensed to you under the terms of the Apache License, version | |
* 2.0, or, at your option, the terms of the GNU General Public License, | |
* version 2.0. See the APACHE20 and GPL2 files for the text of the licenses, | |
* or the following URLs: |
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
for ( var i = 0, l = geometry.faceVertexUvs[ 0 ].length; i < l; i ++ ) { | |
for ( var j = 0, jl = geometry.faceVertexUvs[ 0 ][ i ].length; j < jl; j ++ ) { | |
var uv = geometry.faceVertexUvs[ 0 ][ i ][ j ]; | |
var a = uv.v * Math.PI - Math.PI / 2; | |
a = Math.sin(a); | |
uv.v = Math.log( ( 1 + a ) / ( 1 - a ) ) / ( 4 * Math.PI ); | |
uv.v += 0.5; |
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
[Desktop Entry] | |
Version=2.0 | |
Name=Sublime Text | |
Exec=bash -c "~/Downloads/Sublime\ Text\ 2/sublime_text %f" | |
Icon=Sublime | |
Terminal=false | |
Type=Application | |
Categories=Motif;Utility;TextTools; | |
GenericName=Text editor | |
GenericName[en]=Text editor |
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
var texture = THREE.ImageUtils.loadTexture( file ); | |
texture.wrapS = THREE.ClampToEdgeWrapping; | |
texture.wrapT = THREE.ClampToEdgeWrapping; | |
texture.magFilter = THREE.NearestFilter; | |
texture.minFilter = THREE.LinearMipMapLinearFilter; |