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
Shader | |
layout (location = 0) in vec3 inPos; | |
layout (location = 1) in vec3 inColor; | |
layout (location = 2) in vec3 inPosB; | |
layout (location = 3) in vec3 inColorB; | |
... | |
Application |
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
#include <stdio.h> | |
#include <stdlib.h> | |
#include <clang-c/Index.h> | |
enum CXChildVisitResult | |
onVisitCursor(CXCursor cursor, CXCursor parent, CXClientData client_data) | |
{ | |
if (clang_getCursorKind(cursor) == CXCursor_InclusionDirective) { | |
CXFile file = clang_getIncludedFile(cursor); |
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 reblaze(vals, fn) { | |
if (typeof fn !== 'function') | |
throw new TypeError('fn should be a function'); | |
// V8 will automatically throw if vals is not an object. | |
var keys = Object.keys(vals); | |
var regexp; | |
var fn_name = fn.name; |
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
// WASAPI : Rendering a Stream | |
// http://msdn.microsoft.com/en-us/library/dd316756%28v=VS.85%29.aspx | |
#define _USE_MATH_DEFINES | |
#define WIN32_LEAN_AND_MEAN | |
#include <windows.h> | |
#include <stdio.h> | |
#include <mmdeviceapi.h> | |
#include <audioclient.h> |
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 buttons = []; | |
var rows = 1; | |
var columns = 1; | |
var distanceBetween = 20; | |
var borderH = 1; | |
var borderW = 2; | |
var w = rows*distanceBetween + borderW | |
var h = columns*distanceBetween + borderH |
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
console.log("loading bagu"); | |
var bagu = require("./build/Release/bagu"); | |
console.log("bagu loaded"); | |
console.log(bagu); |
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
THREE.Vector3.prototype.lerp = function ( a, t ) { | |
return this.clone().addSelf( a.clone().subSelf( this ).multiplyScalar( t ) ); | |
}; | |
THREE.Vertex.prototype.interpolate = function( other, t ) { | |
var v = new THREE.Vertex( this.position.lerp( other.position, t ) ); | |
v.normal = this.normal.clone(); | |
return v; | |
}; |