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
<!DOCTYPE html> | |
<!-- By Jan Wrobel. See it working at: | |
http://mixedbit.org/blog/2013/02/10/random_walk_illustrated_with_d3.html | |
--> | |
<html> | |
<head> | |
<meta http-equiv="Content-Type" content="text/html;charset=utf-8"> | |
<title>Random walk</title> |
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 unittest | |
class Pipe: | |
OUT = object() | |
def __init__(self, val): | |
self._val = val | |
def __call__(self, *args): | |
if not (args): |
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
struct Row { | |
float& operator[](int column) { | |
return coeffs[column]; | |
} | |
typedef std::tr1::unordered_map<int, float> RowData; | |
RowData coeffs; | |
}; | |
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
vec3 lightW = normalize(cameraPosition - vPositionW.xyz); | |
gl_FragColor.rgb = color * max(dot(normalize(vNormalW), lightW), 0.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
#!/bin/sh | |
if [ $# != 1 ]; then | |
echo "usage: $0 path-to-bundle-dir"; | |
exit; | |
fi | |
bundle_dir=${1} | |
echo "Uncompressing files in ${bundle_dir}" |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!-- | |
IIS site configuration file for Shapespark self-hosting bundles. | |
Requires URL rewrite extension: https://www.iis.net/downloads/microsoft/url-rewrite | |
Extract the Shapespark bundle together with this config file to a | |
folder that is configured as a IIS site (<sites> section of | |
the applicationhost.config). | |
--> |
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
<script> | |
(function() { | |
document.getElementById('play-button').src = "https://cdnjs.cloudflare.com/ajax/libs/foundicons/3.0.0/svgs/fi-play-video.svg"; | |
}()); | |
</script> |
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
<script> | |
var viewer = WALK.getViewer(); | |
viewer.onSceneReadyToDisplay(function() { | |
var setMaterialForMeshOriginal = viewer.setMaterialForMesh; | |
viewer.setMaterialForMesh = function(material, mesh) { | |
console.log('Material selected ' + material.name); | |
setMaterialForMeshOriginal.apply(this, [material, mesh]); | |
} | |
}); | |
</script> |
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
<style> | |
#banner { | |
position: absolute; | |
top: 30px; | |
text-align: center; | |
font-size: 3em; | |
width: 100%; | |
z-index: 10; | |
visibility: hidden | |
} |
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
<script> | |
(function() { | |
WALK.CAMERA_WALK_NEAR = 0.03; | |
}()); | |
</script> |
OlderNewer