Giter Site home page Giter Site logo

kitware / vtp-web-viewer Goto Github PK

View Code? Open in Web Editor NEW
2.0 3.0 0.0 9.99 MB

A simple, standalone VTP viewer for the TeleSculptor Multiplex project

Home Page: https://kitware.github.io/vtp-web-viewer/

License: Apache License 2.0

Python 3.92% JavaScript 86.02% CSS 2.69% HTML 7.38%
vtkjs 3d visualization web

vtp-web-viewer's Introduction

vtk.js Standalone VTP Viewer

This is for embedding a VTP file into a standalone HTML web app for 3D viewing with vtk.js

Usage

Please head over to the releases page and download the pre-built HTML file from the latest release notes with the Python script for "injecting" a VTP mesh file into the viewer.

Once you have both files downloaded, point the Python script to both your VTP mesh file and the prebuilt HTML file:

python inject_data.py <path_to_mesh>.vtp index.html

This will ouptut a new HTML file next to the mesh file where you can view that mesh and share the HTML file for anyone to view it (with/without an internet connection and without sharing the original mesh file).

Local Development

Install the app:

npm install

Build the static HTML app:

npm run-script build

Inject your .vtp mesh file into the app:

python inject_data.py <path_to_mesh>.vtp dist/index.html

And then you can share the produced .html file with the same basename as the mesh for 3D viewing anywhere!

Notes

For building source in the HTML file, see DustinJackson/html-webpack-inline-source-plugin#79

Supported VTP File Types

The given mesh file should have a point data array named 'RGB'.

Appended Ascii Binary
None
LZ4
ZLib
LZMA

Of the supported formats, Appended-ZLib has the mallest file size. For one specific mesh, here is a comparison. This should scale:

Appended Ascii Binary
None 27 Mb 48 Mb 35 Mb
ZLib 8.7 Mb 48 Mb 11 Mb

vtp-web-viewer's People

Contributors

banesullivan avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  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.