A modular approach to WebGL programming