Skip to content

Commit

Permalink
Agregado model de color RGB
Browse files Browse the repository at this point in the history
  • Loading branch information
monsieurBelbo committed Dec 11, 2012
1 parent 0d6b29d commit f8fbeb7
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
@@ -1,3 +1,4 @@
*.ipr
*.iws
*.iml
*.DS_Store
8 changes: 8 additions & 0 deletions public/assets/js/MapManager.js
Expand Up @@ -121,6 +121,14 @@ var MapManager = function MapManager(options) {
}
}

this._computeRGBColorModel = function(n) {
var r = Math.floor((255*n)/100);
var g = Math.floor((255*(100-n))/100);
var b = 0;

return "rgb(" + r + "," + g + "," + b + ")";
}

this._coordinatesToLatLng = function(coordinates) {
var array = [];
for (var i=0; i<coordinates.length; i++) {
Expand Down

0 comments on commit f8fbeb7

Please sign in to comment.