Skip to content

Instantly share code, notes, and snippets.

@jqtrde
Forked from anonymous/index.html
Last active August 29, 2015 14:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jqtrde/1c2b9132ae4e71b820fc to your computer and use it in GitHub Desktop.
Save jqtrde/1c2b9132ae4e71b820fc to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<title>Foo</title>
<meta charset='utf-8' />
<meta name='viewport' content='width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0' />
<style type='text/css'>
div {
cursor:pointer;
cursor:hand;
position:absolute;
top:0;
left:0;
}
</style>
<script type='text/javascript'>
window.onload = function() {
var s = document.getElementsByTagName('div'), cur = 0, ti;
if (!s) return;
function go(n) {
cur = n;
var i = 1e3, e = s[n], t;
document.body.className = e.dataset.bodyclass || '';
for (var k = 0; k < s.length; k++) s[k].style.display = 'none';
e.style.display = 'inline';
e.style.fontSize = i + 'px';
if (e.firstChild && e.firstChild.nodeName === 'IMG') {
document.body.style.backgroundImage = 'url(' + e.firstChild.src + ')';
e.firstChild.style.display = 'none';
if ('classList' in e) e.classList.add('imageText');
} else {
document.body.style.backgroundImage = '';
document.body.style.backgroundColor = e.style.backgroundColor;
}
if (ti !== undefined) window.clearInterval(ti);
t = parseInt(e.dataset.timeToNext || 0, 10);
if (t > 0) ti = window.setTimeout(fwd, (t * 1000));
while (
e.offsetWidth > window.innerWidth ||
e.offsetHeight > window.innerHeight) {
e.style.fontSize = (i -= 2) + 'px';
if (i < 0) break;
}
e.style.marginTop = ((window.innerHeight - e.offsetHeight) / 2) + 'px';
if (window.location.hash !== n) window.location.hash = n;
document.title = e.textContent || e.innerText;
}
document.onclick = function() { go(++cur % (s.length)); };
function fwd() { go(Math.min(s.length - 1, ++cur)); }
function rev() { go(Math.max(0, --cur)); }
document.onkeydown = function(e) {
if (e.which === 39 || e.which === 34 || e.which === 40) fwd();
if (e.which === 37 || e.which === 33 || e.which === 38) rev();
};
document.ontouchstart = function(e) {
var x0 = e.changedTouches[0].pageX;
document.ontouchend = function(e) {
var x1 = e.changedTouches[0].pageX;
if (x1 - x0 < 0) fwd();
if (x1 - x0 > 0) rev();
};
};
function parse_hash() {
return Math.max(Math.min(
s.length - 1,
parseInt(window.location.hash.substring(1), 10)), 0);
}
if (window.location.hash) cur = parse_hash() || cur;
window.onhashchange = function() {
var c = parse_hash();
if (c !== cur) go(c);
};
go(cur);
};
</script></head><body>
<div><h1 id="landsat-8-gives-you-magical-powers">Landsat 8 gives you magical powers</h1>
</div>
<div><p><img src="https://camo.githubusercontent.com/18ae320c3c7e4f6445a6b41b55c34c055ccb8e60/68747470733a2f2f692e696d6775722e636f6d2f4b306470522e676966" alt=""></p>
</div>
<div><h1 id="fin">Fin</h1>
</div>
<div><p><img src="https://farm8.staticflickr.com/7309/9037121736_735a512d76_o.png" alt=""></p>
</div>
<div><h3 id="7-5-1">7-5-1</h3>
<p><img src="https://farm3.staticflickr.com/2806/9027218111_70b9afb012_o.jpg" alt=""></p>
</div>
<div><h3 id="10-7-3">10-7-3</h3>
<p><img src="https://farm8.staticflickr.com/7355/9034967230_6f1e6a63ac_o.jpg" alt=""></p>
</div>
<div><h3 id="-let-s-find-some-data-http-libra-developmentseed-org-"><a href="http://libra.developmentseed.org/">Let&#39;s find some data</a></h3>
</div>
<div><h3 id="doing-more-than-making-pretty-pictures">Doing more than making pretty pictures</h3>
<p><a href="https://github.com/mapbox/rasterio"><img src="https://i.imgur.com/iz93tys.png" alt=""></a></p>
<ul>
<li><code>brew install gdal</code></li>
<li><code>pip install rasterio</code></li>
</ul>
</div>

Landsat 8 gives you magical powers



Fin



7-5-1


10-7-3



Doing more than making pretty pictures

  • brew install gdal
  • pip install rasterio
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment