gss / engine

GSS engine
http://gss.github.io
MIT License
2.86k stars 105 forks source link

Simple example not working here #135

Closed HendrikRoth closed 9 years ago

HendrikRoth commented 9 years ago

https://github.com/henn1nk/gss-test

Any idea, what i missed out? Tested under OSX and Chrome browser.

http://codepen.io/paulyoung/pen/Dyegf works here.

HendrikRoth commented 9 years ago
<script>
  GSS_CONFIG = {
    worker: "//rawgit.com/the-gss/engine/36a663b403373ea36ea60a2ff966d987e3512fa3/dist/worker.js",
    useWorker: false, // was necessary for me.
    fractionalPixels: false
  }
</script>
paulyoung commented 9 years ago

Hi @henn1nk

If I open the HTML file in Chrome I see these errors in the console:

Uncaught SecurityError: Failed to construct 'Worker': Script at 'file:///Users/paulyoung/git/henn1nk/gss-test/bower_components/gss/dist/worker.js' cannot be accessed from origin 'null'.
gss.js:22118
Uncaught SecurityError: Failed to construct 'Worker': Script at 'file:///Users/paulyoung/git/henn1nk/gss-test/bower_components/gss/dist/worker.js' cannot be accessed from origin 'null'.

This is because I'm not using a web server.

If I run python -m SimpleHTTPServer on the command line at the root of the project and then browse to http://localhost:8000 everything works.

paulyoung commented 9 years ago

That's also an option!

HendrikRoth commented 9 years ago

Thanks for your explanation!