Wednesday, August 5, 2015

WegGL Trial with Dartlang clear screen

Dartlang has very comfortable programming environment.Dart x Eclipse 's strong auto-complete function is excellent.  So, I have started to study WebGL with dartlang.

First time. I create a clear screen sample.

import 'dart:html' as html;
import 'dart:web_gl' as gl;

void main() {
  var canvas = new html.CanvasElement(width: 500, height: 500);

  gl.RenderingContext GL = canvas.getContext3d();
  double r = 0.6;
  double g = 0.2;
  double b = 0.2;
  double a = 1.0;
  GL.clearColor(r, g, b, a);


Kyorohiro work

No comments:

Post a Comment