1.1.5 • Published 6 years ago

lowww-core v1.1.5

Weekly downloads
20
License
-
Repository
github
Last release
6 years ago

lowww-core

core functionality for the lowww engine.

Installation

npm install --save lowww-core

Usage

import { Renderer, Scene, cameras, Mesh } from 'lowww-core';
import { Box } from 'lowww-geometries';

let renderer;
let camera;
let scene;
let mesh;

init();
update();

const init = () => {
    renderer = new Renderer();
    renderer.setSize(400, 300);
    document.body.appendChild(renderer.domElement);

    camera = new cameras.Perspective();
    camera.position.set(0, 0, 500);

    scene = new Scene();

    const geometry = new Box(10, 10, 10);
    mesh = new Mesh({ geometry });
    scene.add(mesh);
};

const update = () => {
    mesh.rotation.x += 0.01;
    mesh.rotation.y += 0.01;

    renderer.render(scene, camera);
    requestAnimationFrame(update.bind(this));
};

Hello World

check out this JSFiddle.

License

MIT

1.1.5

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.0.82

6 years ago

1.1.0

6 years ago

1.0.81

6 years ago

1.0.80

6 years ago

1.0.28

6 years ago

1.0.27

6 years ago

1.0.26

6 years ago

1.0.25

6 years ago

1.0.24

6 years ago

1.0.23

6 years ago

1.0.22

6 years ago

1.0.21

6 years ago

1.0.20

6 years ago

1.0.19

6 years ago

1.0.18

6 years ago

1.0.17

6 years ago

1.0.16

6 years ago

1.0.15

6 years ago

1.0.14

6 years ago

1.0.13

6 years ago

1.0.12

6 years ago

1.0.11

7 years ago

1.0.10

7 years ago

1.0.9

7 years ago

1.0.8

7 years ago

1.0.7

7 years ago

1.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago