Skip to content

Instantly share code, notes, and snippets.

View chabb's full-sized avatar
🏠
Working from home

Chabbey François chabb

🏠
Working from home
View GitHub Profile
@chabb
chabb / index.html
Last active March 24, 2018 22:17
Spring based on sin
<canvas id="canvas" width="600px" height="400px"></canvas>
<script src="./index.js"></script>
@chabb
chabb / index.html
Last active March 24, 2018 21:10
Exploring matrices and context
<canvas id="canvas" width="700px" height="400px"></canvas>
<script src="./index.js"></script>
@chabb
chabb / index.html
Last active March 22, 2018 23:30
Animated rectangle
<canvas id="canvas" width="900px" height="600px"></canvas>
<script src="./index.js"></script>
@chabb
chabb / index.html
Last active March 22, 2018 16:35
Rectangle disintegration
<canvas id="canvas" width="900px" height="600px"></canvas>
<script src="./index.js"></script>
@chabb
chabb / index.html
Created March 21, 2018 17:01
Simple particle system
<canvas id="canvas" width="600px" height="400px"></canvas>
<script src="./index.js"></script>
@chabb
chabb / index.html
Last active March 9, 2018 05:40
Animation with async/await
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta charset="utf-8" />
<script src="http://d3js.org/d3.v4.min.js" charset="utf-8" type="text/javascript"></script>
</head>
<style>
html,body {
height: 100%;
width: 100%;
margin: 0;
@chabb
chabb / README.md
Last active February 2, 2018 04:43
Farmer market - county line

Hexbin with inner divison

@chabb
chabb / README.md
Last active February 1, 2018 02:37
Elevation model experiment

I was experimenting with PDAL to get different elevation model, and then hillshade them

@chabb
chabb / README.md
Last active January 29, 2018 04:33
California map

Shaded Relief

This is an example of how to create a shaded relief raster with a vector map overlay (using SVG and d3.js). This show how maps are create from digital elevation model.

Step 1 is to grab california shapefiles, reproject them in the projection we want to use

Step 2 is to create the rasters from elevation files that are freely availablr. We use the color-relief.txt file to assign a particular color to a particular altitude range. This generates a raster file that we'll use later

@chabb
chabb / Makefile
Created January 23, 2018 16:45 — forked from mjhoy/Makefile
Costa Rica shaded relief
all: hill-relief.jpg costarica_min_topo.json
# -------------
# Relief raster
# -------------
#
# Notice the `zip` file requirements here have no download.
# You will need to search for them online. They are from the
# SRTM project: http://www2.jpl.nasa.gov/srtm/
# (which appears to have multiple versions of files).