Home Try Online Docs GitHub

MorphCharts

MorphCharts is a visualization library for creating rich, immersive, and engaging 2D and 3D data visualizations.

Getting Started

You can Try Online, or install and run locally (see Installation, below).

Try Online page with visualization and specification

There are 2 principal ways to create charts using this library:

  1. Provide a JSON specification based on a subset of the VEGA visualization grammar, with extensions to support 3D visualizations.
  2. Use code to create visualizations directly, with the Core library and a Renderer.

The JSON specification can define data sources and transformations, scales, axes, and visualizations. Data sources can be defined in the following ways:

  1. Using an inline JSON definition.
  2. Linking to an external file via a URL.

The Try Online page also supports using local files.

Rendering

Charts are principally rendered using procedural geometry and path tracing. Supported geometric primitives include rectangles, cuboids, spheres, cylinders, hex prisms, ring segments, and torus segments.

Render pipelines are provided for:

The ray tracer supports rendering the following material types, which can be defined in the JSON specification:

Materials can be rendered in solid color, or textured.

Visualizations can be generated at arbitrary resolutions. Single images can be created, typically up to 4K (3840x2160px) resolution (depending on hardware). For larger resolutions, multiple image tiles can be created, which can be stitched into an arbitrarily large image.

Components

The repo has the following components:

Installation

The project can be installed and run locally using the following steps:

  1. Clone the repo.
  2. npm install to install any required dependencies.
  3. Build the project using npm run build_client.
  4. Start the web site using npm run start_client, which also opens the client.html page in the default web browser.