1.6.1 • Published 2 years ago

@viewar/room-planner v1.6.1

Weekly downloads
32
License
MIT
Repository
-
Last release
2 years ago

ViewAR Room Planner

The room planner included in ViewAR's base6 template and sample app. To use this package you need to have the ViewAR API installed (https://www.npmjs.com/package/viewar-api).

For more information visit our developer portal at http://portal.viewar.com or our website at http://www.viewar.com.

Usage

Initialise with:

import viewarApi from 'viewar-api';
import createRoomPlanner from '@viewar/room-planner';

await viewarApi.init({appId: 'com.viewar.sdk'});
export const roomPlanner = createRoomPlanner(window);

Attach to a canvas:

// editor: The editor's div element.
// canvas: The canvas element to draw on.
// 'touchable': The html class that is touchable (for inserting windows or doors).
roomPlanner.attach(window.document, editor, canvas, 'touchable');

Export state to use with ViewAR SDK:

// Get state.
const exportState = roomPlanner.exportStateToCore();

// Create 3d representation.
await viewarApi.roomManager.addRoomToScene(exportState);
1.6.1

2 years ago

1.6.0

2 years ago

1.5.0

4 years ago

1.4.1

4 years ago

1.4.0

4 years ago

1.3.0

4 years ago

1.2.0

4 years ago

1.1.0

4 years ago

1.0.0

4 years ago