Skip to content

Instantly share code, notes, and snippets.

@noboko
noboko / app.js
Created April 14, 2012 14:17
Learning WebGL for Plask Lesson 15
//Learning WebGL for Plask Lesson14
//Learing WebGL : http://learningwebgl.com/blog/?page_id=1217
//Github : https://github.com/gpjt/webgl-lessons (this script use 'earth.jpg' and 'earth-specular.gif')
//
//KeyMap
//zoom : qe,
//lighting : t,
//colorMap : y
//useColorMap : u,
//reset : r,
@noboko
noboko / app.js
Created April 24, 2012 17:07
Learning WebGL for Plask Lesson 16
//Learning WebGL for Plask Lesson16
//Learing WebGL : http://learningwebgl.com/blog/?page_id=1217
//Github : https://github.com/gpjt/webgl-lessons (this script use 'earth.jpg' , 'crate.gif' and 'macbook.json')
//
//Plask : http://www.plask.org/
//
//俺俺でMat3とMat4.toInverseMat3()あたりを追記したものを使ってやりました。
//元のplask.jsと区別つけるために同一フォルダから読み込むようにしてます。
//尚、binary版とgithubの最新版で微妙にplask.jsの変更があるみたいなので、
//plask_.js binary版用、plask.js github用としてます。
@noboko
noboko / app.fshader
Created January 31, 2013 16:37
npmでtimbreインストールした後、Plaskからtimbre使ってみるテスト。 別にそれぞれ連動させたわけじゃなくて、timbreのサンプルをplaskのサンプルに書き足しただけ。
#ifdef GL_ES
precision highp float;
#endif
varying vec4 vColor;
void main(void) {
gl_FragColor = vColor;
}
@noboko
noboko / _app.js
Created March 4, 2013 14:09
Plaskでunderscore.js使ってみるテスト
//npm install underscore
var plask = require('plask');
_ = require('underscore');
plask.simpleWindow({
init: function() {
this.framerate(60);
this.paint.setFill(); // Fill is the default, so this is just for clarity.
this.paint.setAntiAlias(true);
},