Go to file
Thomas FORGIONE f64a861936 Finished tutorial, corrected bug, and fixed TutoCamera collision (a
little)
2015-05-28 10:43:58 +02:00
controllers Correct bug 2015-05-27 10:44:31 +02:00
js Finished tutorial, corrected bug, and fixed TutoCamera collision (a 2015-05-28 10:43:58 +02:00
lib Corrected mistake : swapped controllers.js and posts.js 2015-05-19 18:09:46 +02:00
my_modules Initial commit of nodejs 2015-05-05 11:56:35 +02:00
posts Added hovered events 2015-05-21 15:35:40 +02:00
sql A lot of cleaning, and compilation of the js code 2015-05-22 16:59:33 +02:00
static A lot of cleaning, and compilation of the js code 2015-05-22 16:59:33 +02:00
views Added begining of tutorial 2015-05-26 11:49:24 +02:00
.gitignore Added sql init 2015-05-18 09:52:04 +02:00
README.md Update README.md 2015-05-22 18:05:58 +02:00
package.json Removed useless dependency 2015-05-19 10:15:51 +02:00
server.js Test changes and removed useless function stuff 2015-05-22 17:14:09 +02:00
urls.js Added begining of tutorial 2015-05-26 11:49:24 +02:00

README.md

3D Interface

A prototype for a user-friendly 3D interface allowing to browse 3D scenes / models written with Node.js.

It is hosted by OpenShift at 3dinterface.no-ip.org.

To run a local server

Database setup

First you need to configure the database. You can create a postgres database where you want, and you can initialize it by running the script sql/backup.pgsql.

Nodejs configuration

Then, you have to set up nodejs to access to your database. Basically, you have to create a file private.js at the root of the repository looking like this :

module.exports.url = ... // the url to connect to your database

module.exports.secret = ... // A secret string used to hash stuff

Compiling the static js files

Once this is done, you have to generate the static javascript files. To do this, you should go to the directory js at the root and run make. You will need to haveclosure-compiler on your machine.

If it doesn't work, check in the Makefile that the path to closure-compiler.jar is correct.

This will generate lots of *.min.js in static/js.

Running the server

As usual with NodeJS, it's quite easy to test. Just ensure you have node installed on your machine, clone this repo somewhere, and then, in the repo do

npm install
node server.js

You should be able to go to localhost:4000 and see the result.