GithubHelp home page GithubHelp logo

loualrid / scenejs_on_rails Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 4.66 MB

SceneJS but on Rails! Easier loading for your assets into the scenejs pipeline

License: MIT License

Shell 2.34% Ruby 97.66%

scenejs_on_rails's People

Contributors

loualrid avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

scenejs_on_rails's Issues

Routing problem in basic setup

I'm trying to setup a new rails app with scenejs following the instructions in the readme.

I'm, using Rails 4.0.1,

my application.js includes:

//= require scenejs
//= require scenejs_lib/stats.min
//= require scenejs_extras/gui

and my routes.rb includes:

resources :scenejs, only: [:get_scenejs_plugin]

and I pasted the example earth scene into a script tag on a simple page.

On loading the page a black canvas is injected, it says "Loading plugin 1..." but the console reads "GET http://0.0.0.0:3000/scenejs/get_scenejs_data.js?file=/node/cameras/orbit.js 404 (Not Found)" and rails reports "ActionController::RoutingError (No route matches [GET] "/scenejs/get_scenejs_data.js"):"

So it seems that after following the instructions the /scenejs/get_scenejs_data.js route doesn't appear to work.

I've never used scene.js before, so I'm as the naively following instructions stage.

Edit:
Adding the following code to the start of the script tag makes the demo load, though obviously isn't a solution:

SceneJS.setConfigs({
    pluginPath: "http://www.corsproxy.com/scenejs.org/api/latest/plugins"
});

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.