Giter VIP home page Giter VIP logo

carto's Introduction

Carto Developer Test

Demo

I've decided to render Fire Company that service the tax lot. As we can find in http://www1.nyc.gov/assets/planning/download/pdf/data-maps/open-data/meta_mappluto.pdf

At the beginning I started splitting the functionality in 3 layers:

  1. Canvas. It's in charge of painting shapes into canvas.
  2. Map. It allows to translate coordinates (geometric ones based in GeoJSON) into actual shapes on the canvas layer.
  3. Data. Right now, it isn't represented by any class. It's in the mix of main file.

I created Polygon which is the shape used in this dataset. I also created Rect for testing purposes. After that, I created Map class which allow me to assign some coeficients to draw GeoJSON geometries in a good scale.

You can follow all my steps through my repo: https://github.com/adelarosab/carto

Future development points:

  1. Use web workers to paint different parts of the canvas.
  2. Do not paint polygons outside of the canvas viewport. Easily calculated thank you to coordinates and offset attribute of the map.
  3. Use css translation and scale to smooth transition between states. In the meantime we can use this time to render another canvas context.

carto's People

Watchers

James Cloos avatar Adrian de la Rosa avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.