Thanks to visit codestin.com
Credit goes to github.com

Skip to content

johnmeade/hypercube-gl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hypercube

This project implements the necessary logic to display and rotate cubes of any dimension. A demonstration is included through main.js and index.html which uses THREE js to display the cubes.

The logic for creating the rotation matrices and vertices, and for finding the pairs of vertices which correspond to an edge, is written in Elm and can be found in src/Hypercube.elm. The file elm-hypercube.js is just the compiled file that gets imported into HTML.

To glue this logic to WebGL, I've used my simulation library, sim-shim-js. This simplifies the role of main.js to just having to build the THREE js objects and provide an update function. More details about how it works can be found on the sim-shim-js project page.

A more complete demo is up here.

Build

elm make src/Hypercube.elm --output elm-hypercube.js

About

Visualization of hypercubes using Elm and WebGL

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published