diff -r a323578ea954 -r 9d968fbcaa2a client/annotviz/app/js/utils.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/client/annotviz/app/js/utils.js Tue Jan 20 12:00:40 2015 +0100 @@ -0,0 +1,17 @@ +/** +* js/utils.js +* +* basic tools +* +*/ + +'use strict'; + +function rgb2hex (r, g, b) { + return "0x" + + ("0" + parseInt(r, 10).toString(16)).slice(-2) + + ("0" + parseInt(g, 10).toString(16)).slice(-2) + + ("0" + parseInt(b, 10).toString(16)).slice(-2); +}; + +module.exports = rgb2hex; \ No newline at end of file