Code Monkey home page Code Monkey logo

sparkpreviewer's Introduction

Enjoy SparkViewer, an HTML5 and WebGL based runtime model viewer, now with nearly total support to brand new .obj models, yeaaah.

If you want to check for update you only need click on this link: http://www.quartaibvisintin.altervista.org/Canvas%20Examples/webgl_previewer/index.html

To use SparkPreviewer libs folder and SparkViewer.js has to stay togheter so

  1. You MUST have "SparkPreviewer.js" file and "core" folder in the same location of the filesystem otherwhise the previewer is not going to work.

  2. do NOT DELETE the "SparkPreviewer.js" file NOR the "core" folder otherwhise the previewer is not going to work.

  3. you have to copy and paste the following lines of HTML code where you want the previewer to appear and also replace the "src" string to match your "SparkPreviewer.js" file location:

<!--replace the path with a correct one-->
<script src= "path/to/SparkPreviewer.js"></script>
<script src= "path/to/JRV.js"></script>
       <canvas id = "sparkViewer" width = "800" height = "600">
              You have to update your broswer to use the SparkViewer viewer
       </canvas>
  1. additionally if you want to use the default style of the editor you also have to add the following lines of code:

NOTE: remember to add the following lines in the web.config file, otherwise you may get a 404 error from broswer when trying to load files such .obj

<system.webServer>
       <staticContent>
              <mimeMap fileExtension=".obj" mimeType="text/plain"/>
              <mimeMap fileExtension=".tga" mimeType="application/tga"/>
              <mimeMap fileExtension=".mtl" mimeType="text/plain"/>
       </staticContent>
</system.webServer>

sparkpreviewer's People

Contributors

ruggerovisintin avatar

Watchers

 avatar

Forkers

lucailgrande

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.