
var window = window || {};
var self = self || {};


var window = window || {};
var self = self || {};

// High-resulution counter: emulate window.performance.now() for THREE.CLOCK
if( window.performance === undefined ) {

	window.performance = { };

}

if( window.performance.now === undefined ) {

	window.performance.now = function () {

		var time = process.hrtime();
		return ( time[0] + time[1] / 1e9 ) * 1000;

	};

}

Use process.hrtime() for Clock in node.js builds
Use process.hrtime() for Clock in node.js builds

As discussed in #2975.
