aws-samples / aws-iot-twinmaker-samples

Apache License 2.0
97 stars 77 forks source link

Adding the @iot-twinmaker/scene-utils lib #85

Closed hwandersman closed 1 year ago

hwandersman commented 1 year ago

Adding @iot-twinmaker/scene-utils lib to enable automated scene creation. Sample command line scripts are provided to create and delete the CookieFactory scene.

Issue #, if available:

Description of changes: Introducing a programmatic interface for constructing scenes and preparing 3D assets for TwinMaker. This library enables customers to manage 3D models that are uploaded to S3 and applied to the scene hierarchy as interactive nodes. A scene node can be a 3D mesh or a built-in augmentation like a tag or motion indicator. You can set the 3D transform of the node and apply a data binding with an entity, component, and property path of a time stream data connector. This SDK also supports adding scene rules to dynamically change an icon or mesh color when data is applied to the scene viewer on your IoT TwinMaker application.

Security This lib uses the AWS JS SDK to connect to IoT TwinMaker and S3. Customers will use temporary AWS credentials to authenticate into the AWS SDK.

Scripts Summary of sample command line scripts:

Cookie Factory Sample Use the 3D models in this repo's scenes directory to build the CookieFactory.json scene with the SDK. This sample is meant as a starting point for users with local 3D models they want to add to a scene with all scene features (tags, motion indicator, data binding, rules, etc.).

Delete your scene Example to clean up nodes in your scene or delete it from your workspace.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.