Skip to content

Instantly share code, notes, and snippets.

@nasser
Created September 24, 2013 23:33
Show Gist options
  • Select an option

  • Save nasser/6692829 to your computer and use it in GitHub Desktop.

Select an option

Save nasser/6692829 to your computer and use it in GitHub Desktop.
JSONObject data;
void setup() {
data = loadJSONObject("http://api.openweathermap.org/data/2.5/weather?q=London,uk");
size(500,500);
}
void draw() {
float temprature = data.getJSONObject("main").getFloat("temp");
rectMode(CENTER);
rect(width/2, height/2, temprature, temprature);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment