0.1.7 • Published 7 years ago

lib3d v0.1.7

Weekly downloads
3
License
GPL-2.0
Repository
github
Last release
7 years ago

npm version Codeship Status for Galiaf47/lib3d Document Coverage Status

lib3d

Display 3D library on your webpage

Screenshot

Install

npm install lib3d

Add three.js and lib3d to your index.html:

<script src="/node_modules/three/three.min.js"></script>
<script src="/node_modules/lib3d/dist/lib3d.js"></script>

And add a canvas element to your page

<body>
    <canvas id="LIBRARY"></canvas>

Basic Usage

var env = new lib3d.Environment(document.getElementById("LIBRARY"), 300, 300);

var library = lib3d.factory.createLibrary({
    id: '1', 
    model: 'default'
});
var section = lib3d.factory.createSection({
    id: '1', 
    model: 'default'
});
var book = lib3d.factory.createBook({
    id: '1'
    model: 'default', 
    shelfId: '4', 
    sectionId: '1'
});

library.addSection(section);
library.addBook(book);
env.library = library;

section.move(new THREE.Vector3(-0.3, 0, -2));
book.move(new THREE.Vector3(-0.1, -0.06, -0.046));

Documentation

API reference

Contribution

Star this repository or let me know in any other way that you use or going to use this library.

0.1.7

7 years ago

0.1.6

7 years ago

0.1.5

7 years ago

0.1.4

7 years ago

0.1.3

7 years ago

0.1.2

7 years ago

0.1.1

8 years ago

0.1.0

8 years ago

0.0.5

8 years ago

0.0.4

8 years ago

0.0.3

8 years ago

0.0.2

8 years ago

0.0.1

8 years ago

0.0.0

8 years ago