

# Creating and editing AWS IoT TwinMaker scenes
Creating AWS IoT TwinMaker scenes

Scenes are three-dimensional visualizations of your digital twin. They're the primary way for you to edit your digital twin. Learn how to add alarms, time series data, color overlays, tags, and visual rules to your scene to align your digital twin visualizations with your real-world use case.

This section covers the following topics:
+ [Before you create your first scene](scenes-before-starting.md)
+ [Upload resources to the AWS IoT TwinMaker Resource Library](scenes-using-resource-library.md)
+ [Create your scenes](scenes-creation.md)
+ [Add fixed cameras to entities](scenes-camera.md)
+ [Scene enhanced editing](scenes-ee.md)
+ [Edit your scenes](scenes-editing.md)
+ [3D Tiles model format](3d-tiles-model-format.md)
+ [Dynamic scenes](dynamic-scenes.md)

# Before you create your first scene
Before creating scenes

 Scenes rely on resources to represent your digital twin. These resources are made up of 3D models, data, or texture files. The size and complexity of your resources, elements in the scene such as lighting, and your computer hardware, impact the performance of AWS IoT TwinMaker scenes. Use the information in this topic to reduce lag, loading times, and improve the frame rate of your scenes.

## Optimize your resources before importing them into AWS IoT TwinMaker


You can use AWS IoT TwinMaker to interact with your digital twin in real time. For the best experience with your scenes, we recommend optimizing your resources for use in a real-time environment.

Your 3D models can have a significant impact on performance. Complex model geometry and meshes can reduce performance. For example, industrial CAD models have a high level of detail. We recommend compressing these model's meshes and reducing their polygon count before using them in AWS IoT TwinMaker scenes. If you're creating new 3D models for AWS IoT TwinMaker, you should establish a level of detail and maintain it across all your models. Remove details from models that don’t affect the visualization or interpretation of your use case..

To compress models and reduce the file size, use open source mesh compression tools, such as [DRACO 3D data compression](https://google.github.io/draco/).

Unoptimized textures can also impact performance. If you don’t require any transparency in your textures, considering choosing the PEG image format over the PNG format. You can compress your texture files by using open source texture compression tools, such as [Basis Universal texture compression](https://www.khronos.org/blog/google-and-binomial-contribute-basis-universal-texture-format-to-khronos-gltf-3d-transmission-open-standard).

## Best practices for performance in AWS IoT TwinMaker


For the best performance with AWS IoT TwinMaker, note the following limitations and best practices.
+ AWS IoT TwinMaker scene rendering performance is hardware dependent. Performance varies across different computer hardware configurations.
+ We recommend a total polygon count of under 1 million across all your objects in your AWS IoT TwinMaker.
+ We recommend a total of 200 objects per scene. Increasing the number of objects in a scene beyond 200 can decrease your scene frame rate.
+ We recommend the that total size of all unique 3D assets in your scene does not exceed 100 megabytes. Otherwise, you may encounter slow loading times or degraded performance depending on your browser and hardware.
+ Scenes have ambient lighting by default. You can add extra lights into a scene to bring certain objects into focus, or cast shadows on objects. We recommend using one light per scene. Use lights where needed, and avoid replicating real-world lights within a scene.

## Learn more


Use these resources to learn more about optimization techniques that you can use to improve performance in your scenes.
+ [How to convert and compress OBJ models to GLTF for use with AWS IoT TwinMaker](https://aws.amazon.com/blogs/iot/how-to-convert-and-compress-obj-models-to-glb-gltf-for-use-with-aws-iot-twinmaker/)
+ [Optimize your 3D models for web content](https://medium.com/@michael.andrew/6-things-you-havent-optimised-in-your-webvr-content-272d74d541f0)
+ [Optimizing scenes for better WebGL performance](https://www.soft8soft.com/docs/manual/en/introduction/Optimizing-WebGL-performance.html)

# Upload resources to the AWS IoT TwinMaker Resource Library
Uploading resources in AWS IoT TwinMaker

You can use the Resource Library to control and manage any resource you want to place into scenes for your digital twin application. To make AWS IoT TwinMaker aware of the resources, upload them using the Resource Library console page.

## Upload files to the Resource Library using the console


**Follow these steps to add files to the Resource Library using the AWS IoT TwinMaker console.**

1. In the left navigation menu, under **Workspaces**, select **Resource Library**.

1. Select **Add resources** and choose the files you want to upload.   
![\[The Resource Library console page with a list of files that can be selected for upload.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/scenes-resource-lib-upload.png)

# Create your scenes


In this section, you'll set up a scene so that you can edit your digital twin. You can import a 3D model that was uploaded to the [resource library](scenes-using-resource-library.md), then add widgets and bind property data to objects to complete your digital twin. Scene objects can include an entire building or space, or individual pieces of equipment positioned in their physical location. 

**Note**  
Before you create a scene, you must create a workspace.

Use the following procedure to create your scene in AWS IoT TwinMaker.

1. To open the scene pane, in the left navigation of your workspace, choose **Scenes**.

1. Choose **Create scene**. The new scene creation pane opens.

1. In the scene creation pane, enter a name and description for your new scene. If you have a standard or tiered bundle pricing plan, you can select your scene type. It is recommended to use a [dynamic scene](dynamic-scenes.md).

1. When you're ready to create the scene, choose **Create scene**. The new scene opens and is ready for you to work with it.  
![\[An empty scene canvas ready to be worked on.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/scenes-fresh-scene.png)

## Use 3D navigation in your AWS IoT TwinMaker in scenes


The AWS IoT TwinMaker scene has a set of navigation controls that you can use to navigate efficiently through your scene's 3D space. To interact with the 3D space and objects represented by your scene, you use the following widgets and menu options.
+ **Inspector**: Use the Inspector window to view and edit properties and settings of a selected entity or component in your hierarchy.
+ **Scene Canvas**: The Scene Canvas is the 3D space where you can position and orient any 3D resources you want to use.
+ **Scene Graph Hierarchy**: You can use this panel to see all of the entities present in your scene. It appears on the left side of the window.
+ **Object gizmo**: Use this gizmo to move objects around the canvas. It appears at the center of a selected 3D object in the Scene Canvas. 
+ **Edit Camera gizmo**: Use the Edit Camera gizmo to quickly view the scene view camera’s current orientation and modify the viewing angle. You can find this gizmo in the lower-right corner of the scene view.
+ **Zoom controls**: To navigate on the Scene Canvas, use right click and drag in the direction you want to move. To rotate , left click and drag to rotate. To zoom, use the scroll wheel on your mouse, or pinch and move your fingers apart on the track pad of your laptop.

![\[A scene canvas with a newly added object gizmo.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/scenes-nav-layout.png)


The scene buttons on the hierarchy pane have the following functions listed, in order of the buttons' layout:
+ **Undo**: Undo your last change in the scene.
+ **Redo**: Redo your last change in the scene.
+ **Plus (\$1)**: Use this button to gain access to the following actions: **Add empty node**, **Add 3D model**, **Add tag**, **Add light**, and **Add model shader**.
+ **Change navigation method**: Gain access to the scene camera navigation options, **Orbit** and **Pan**.
+ **Trashcan (delete)**: Use this button to delete a selected object in your scene.
+ **Object manipulation tools**: Use this button to translate, rotate, and scale the selected object.

# Add fixed cameras to entities
Add fixed cameras

You can attach fixed camera views to your entities within your AWS IoT TwinMaker scenes. These cameras provide a fixed perspective on a 3d model, allowing you to quickly and easily shift your perspective in a scene to a targeted entity. 

1. Navigate to your scene in the [AWS IoT TwinMaker console](https://console.aws.amazon.com/iottwinmaker/).

1. In the scene hierarchy menu, select the entity you want to attach the camera to.

1. Press the **\$1** button, and from the drop down options select **Add camera from current view**. To apply a camera with the current perspective to the entity.

1. In the inspector, you can configure your camera and adjust the following settings:
   + A camera **Name**
   + The camera **position** and **rotation**
   + The camera **focal length**
   + The **zoom level**
   + **Near** and **Far** clipping planes

1. To access your camera after you have placed it. Select the entity you added the camera to in the hierarchy. Look for the camera name listed under the entity.

1. Once you select the placed camera from your entity, the scenes camera view will snap to the set perspective of the placed camera.

# Scene enhanced editing
Enhanced editing

AWS IoT TwinMaker scenes feature a set of tools for enhanced and editing and manipulation of resources present in your scene.

The following topics teach you how to used the enhanced editing features in your AWS IoT TwinMaker scenes.
+ [Targeted placement of scene objects](#scenes-ee-placement)
+ [Submodel selection](#scenes-ee-submodel)
+ [Edit entities in the scene hierarchy](#scenes-ee-hierarchy)

## Targeted placement of scene objects


AWS IoT TwinMaker allows you to precisely place and add objects into your scene. This enhanced editing feature gives you greater control of where you're placing tags, entities lights and models in your scene.

1. Navigate to your scene in the [AWS IoT TwinMaker console](https://console.aws.amazon.com/iottwinmaker/).

1. Press the **\$1** button, and from the drop down options select one of the options. This could be a model, a light, a tag, or anything from the **\$1** menu.

   When you move your cursor in the 3d space of your scene you should see a target around your cursor .

1. Use the target to precisely place elements in your scene.

## Submodel selection


AWS IoT TwinMaker lets you select submodels of 3d models in scenes and apply standard properties to them, such as tags, lights, or rules.

3d model file formats contain metadata that can specify sub areas of the model as submodels within the larger model. For example a model could be a filtration system, individual parts of the system like tanks, pipes, or a motor are marked as submodels of the filtration's 3d model.

**Supported 3D file formats in scenes**: GLB, and GLTF.

1. Navigate to your scene in the [AWS IoT TwinMaker console](https://console.aws.amazon.com/iottwinmaker/).

1. If you have no models in your scene, make sure to add one by selecting the option from the **\$1** menu.

1. Select model listed in your scene hierarchy, once selected the hierarchy should display any submodels beneath the model.
**Note**  
If you do not see any submodels listed then it is likely the model was not configured to have any submodels.

1. To toggle the visibility of a submodel, press the eye icon, located to the right of the submodel's name in the hierarchy.

1. To edit submodel data, such as its name or position, the scene inspector will open when a submodel is selected. Use the inspector menu to update or change submodel data.

1. To add tags, lights, rules, or other properties to submodels, press the **\$1**, while the submodel is selected in the hierarchy.

## Edit entities in the scene hierarchy


AWS IoT TwinMaker scenes let you directly edit properties of entities within the hierarchy table. The following procedure shows you which actions you can perform on an entity through the hierarchy menu.

1. Navigate to your scene in the [AWS IoT TwinMaker console](https://console.aws.amazon.com/iottwinmaker/).

1. Open the scene hierarchy, and select a sub element of an entity you wish to manipulate.

1. Once the element is selected, press the **\$1** button, and from the drop down select one of the options:
   + **Add empty node**
   + **Add 3D model**
   + **Add light**
   + **Add camera from current view**
   + **Add tag**
   + **Add model shader**
   + **Add motion indicator**

1. After selecting one of the options from the drop down, the selection will be applied to the scene as child of the selected element from step 2.

1. You can reorder child elements and reparent elements, by selecting a child element and dragging in the hierarchy to a new parent.

## Add annotations to entities


The AWS IoT TwinMaker scene composer lets you annotate any element in your scene hierarchy. The annotation is authored in markdown.

For more information on writing in Markdown, see the official documentation on markdown syntax, [Basic Syntax](https://www.markdownguide.org/basic-syntax/).

**Note**  
AWS IoT TwinMaker annotations and overlay Markdown syntax only and not HTML.

**Add an annotation to an entity**

1. Navigate to your scene in the [AWS IoT TwinMaker console](https://console.aws.amazon.com/iottwinmaker/).

1. Select an element from the scene hierarchy that you want to annotate. If no element in the hierarchy is selected, then you can add annotation to the root.

1. Press the plus **\$1** button and choose the **Add annotation** option.  
![\[A scene canvas page with the plus sign control expanded to show the Add annotation option.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/Scene composer -annotation-menu.png)

1. In the **Inspector** window on the left, scroll down to the **annotation** section. Using Markdown syntax, write the text you want your annotation to display.

   For more information on writing in Markdown, see the official documentation on markdown syntax, [Basic Syntax](https://www.markdownguide.org/basic-syntax/).  
![\[A scene canvas page with the annotation panel's markdown content entry form displayed.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/tm-step4a.png)

1. To bind your AWS IoT TwinMaker scene data to an annotation choose **Add data binding**, add the **Entity Id**, then select the **Component Name** and **Property Name** of the entity you wish to surface data from. You can update the binding name to use it as a Markdown variable, and surface the data in the annotation.  
![\[With the three dots to the right of the annotation pull-down selected, the Add Data Binding button appears.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/tm-step5a1.png)  
![\[When the Add Data Binding button is selected, you can enter the Binding Name, Entity Id, and Component and Property Names.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/tm-step5a2.png)

1. The **Binding Name** is used to represent the annotation's variable.

   Enter a **Binding Name** to surface the latest historical value of an entities time-series in the annotation through AWS IoT TwinMaker's variable syntax: `${variable-name}`

   As an example, this overlay displays the value of the `mixer0alarm`, in the annotation with the syntax `${mixer0alarm}`.  
![\[A completed annotation data binding example.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/tm-step6a.png)

## Add overlays to Tags


You can create overlays for your AWS IoT TwinMaker scenes. Scene overlays are associated with tags and can be used to surface critical data associated with your scene entities. The overlay is authored and rendered in Markdown.

For more information on writing in Markdown, see the official documentation on markdown syntax, [Basic Syntax](https://www.markdownguide.org/basic-syntax/).

**Note**  
By default, an **Overlay** is visible in a scene only when the tag associated with it is selected. You can toggle this in the scene **Settings** so that all **Overlays** are visible at once.

1. Navigate to your scene in the [AWS IoT TwinMaker console](https://console.aws.amazon.com/iottwinmaker/).

1. The AWS IoT TwinMaker **overlay** is associated with a tag scene, you can update an existing tag or add a new one.

   Press the plus **\$1** button and choose the **Add tag** option.  
![\[A scene in which the plus button was selected and with the Add tag option highlighted.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/Scene composer-overlay-add-tag.png)

1. In the **Inspector** panel on the right, select the **\$1** (plus symbol) button then select **Add overlay**.  
![\[The Inspector panel with the plus button selected and Add overlay highlighted.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/tm-step4b.png)

1. In Markdown syntax, write the text you want your overlay to display.

   For more information on writing in Markdown, see the official documentation on markdown syntax, [Basic Syntax](https://www.markdownguide.org/basic-syntax/).

1. To bind your AWS IoT TwinMaker scene data to an overlay, select **Add data binding**.  
![\[The Inspector panel with the three dots selected and Add data binding highlighted.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/tm-step6b.png)

   Add the **Binding name** and **Entity Id**, then select the **Component Name** and **Property Name** of the entity you wish to surface data from.

1. You can surface the latest historical value of an entities time-series data in the overlay through AWS IoT TwinMaker's variable syntax: `${variable-name}`.

   As an example, this overlay displays the value of the `mixer0alarm`, in the overlay with the syntax `${mixer0alarm}`.  
![\[The Inspector panel with alarm status information entered in the Markdown content entry box.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/tm-step7b.png)

1. To enable **Overlay** visibility, open the **Settings** tab in the top left, and make sure the toggle for **Overlay** is switched on so that all **Overlays** are visible at once.
**Note**  
By default, an **Overlay** is visible in a scene only when the tag associated with it is selected.  
![\[The Settings tab showing the Overlay toggle switched off.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/scene-setting.png)

# Edit your scenes


After you've created a scene, you can add entities, components, and configure augmented widgets into your scene. Use entity components and widgets to model your digital twin and provide functionality that matches your use case.

**Topics**
+ [

# Add models to your scenes
](scenes-editing-add-models.md)
+ [

# Add model shader augmented UI widgets to your scene
](scenes-editing-add-color-widget.md)
+ [

# Creating tags for your scenes
](scenes-editing-add-tags.md)

# Add models to your scenes
Add models

To add models to your scene, use the following procedure.

**Note**  
To add models in your scene, you must first upload the models to the AWS IoT TwinMaker Resource Library. For more information, see [Upload resources to the AWS IoT TwinMaker Resource Library](scenes-using-resource-library.md).

1. On the scene composer page, choose the plus (**\$1**) sign, and then choose **Add 3D model**.

1. On the **Add resource from resource library** window, choose the **CookieFactorMixer.glb** file, and then choose **Add**. Scene composer opens.

1. **Optional**: Choose the plus (**\$1**) sign, and then choose **Add light**.

1. Choose each light option to see how they affect the scene.  
![\[A scene canvas with the "Light type" and "Color" controls displayed for the selected cookie mixer.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/CookieMixerInScene.png)
**Note**  
Scenes have default ambient lighting. To avoid frame rate loss, consider limiting the number of additional lights placed in your scene.

# Add model shader augmented UI widgets to your scene
Add widgets

Model shader widgets can change the color of an object under conditions that you define. For example, you can create a color widget that changes the color of a cookie mixer in your scene based on the mixer's temperature data.

Use the following procedure to add model shader widgets to a selected object.

1. Select an object in the hierarchy that you want to add a widget to. Press the **\$1** button and then choose **Model Shader**. 

1. To add a new visual rule group, first follow the instructions below to create the ColorRule, then in the Inspector panel for the object of the Rule ID, choose **ColorRule**.

1. Select the entityID, ComponentName, and PropertyName you want to bind the model shader to.

## Create visual rules for your scenes


You can use visual rule maps to specify the data driven conditions that change the visual appearance of an augmented UI widget, such as a tag or a model shader. There are sample rules provided, but you can also create your own. The following example shows a visual rule.

![\[Example visual rules with temperature based expressions that activate error, warning, and info icons.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/scene-topic-temp-sample-rule.png)


The image above shows a rule for when a previously defined data property with ID 'temperature' is checked against a certain value. For example, if the 'temperature' is greater than or equal to 40, the state will change the appearance of the tag to a red circle. The **target**, when chosen in the Grafana dashboard, populates a detail panel that is configured to use the same data source.

The following procedure shows you how to add a new visual rule group for the mesh colorization augmented UI layer.

1. Under the rules tab in the console, enter a name such as ColorRule in the text field and choose **Add New Rule Group**.  
![\[The "Rules" tab with the New Rule Map name entered above the "Add New Rule Group" button.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/scenes-new-vis-rule-create.png)

1. Define a new rule for your use case. For example, you can create one based on the data property 'temperature', where the reported value is less than 20. Use the following syntax for rule expressions: Less than is **<**, greater than is **>**, less than or equal is **<=**, greater than or equal is **>=**, and equal is **==**. (For more information, see the [Apache Commons JEXL syntax](https://commons.apache.org/proper/commons-jexl/reference/syntax.html).) 

1. Set the target to a color. To define a color, such as `#fcba03`, use hex values. (For more information about hex values, see [Hexadecimal](https://en.wikipedia.org/wiki/Hexadecimal).)

# Creating tags for your scenes
Adding tags

A tag is an annotation added to a specific `x,y,z` coordinate position of a scene. The tag uses an entity property to connect a scene part to the knowledge graph. You can use a tag to configure the behavior or visual appearance of an item in the scene, such as an alarm.

**Note**  
To add functionality to tags, you apply visual rules to them.

Use the following procedure to add tags to your scene.

1. Select an object in the hierarchy, choose the **\$1** button, and then choose **Add Tag**.

1. Name the tag. Then, to apply a visual rule, select a visual group Id.

1. In the dropdown lists, choose the EntityID, ComponentName, and PropertyName.

1. To populate the Data Path field, choose **Create DataFrameLabel**.

# 3D Tiles model format
Optimize your 3D model

## Using 3D Tiles in your scene


If you experience long wait times when you load 3D scenes in AWS IoT TwinMaker or have poor rendering performance when you navigate a complex 3D model, then you may want to convert your models to 3D tiles. This section describes the 3D tiles format and available third-party tools. Read on to decide if 3D Tiles are right for your use case and for help getting started.

### Complex model use case


A 3D model in your AWS IoT TwinMaker scene may cause performance issues like slow loading times and lagging navigation if the model is:
+ **Large**: its file size is larger than 100MB.
+ **Dense**: it is made up of hundreds or thousands of distinct meshes.
+ **Complex**: mesh geometry has millions of triangles to form complex shapes.

### 3D Tiles format


[The 3D Tiles format](https://www.ogc.org/standard/3dtiles/) is a solution for streaming model geometry and improving 3D rendering performance. It enables instantaneous loading of 3D models in an AWS IoT TwinMaker scene, and optimizes 3D interactions by loading in chunks of a model based on what is visible in the camera view. 

The 3D Tiles format was created by [Cesium](https://cesium.com/). Cesium has a managed service to convert 3D models to 3D Tiles called [Cesium Ion](https://cesium.com/platform/cesium-ion/). This is currently the best solution for creating 3D Tiles, and we recommend this for your complex models in the [ supported formats](https://cesium.com/learn/3d-tiling/tiler-data-formats/#supported-data-formats). You can register Cesium and choose the appropriate subscription plan based on your business requirements on [ Cesium's pricing page](https://cesium.com/platform/cesium-ion/pricing/).

To prepare a 3D Tiles model that you can add to an AWS IoT TwinMaker scene, follow the instructions documented by Cesium Ion:
+ [Import a model to Cesium Ion](https://cesium.com/learn/3d-tiling/tiler-data-formats/)

### Upload Cesium 3D tiles to AWS


Once your model has been converted to 3D Tiles, download the model files then upload them to your AWS IoT TwinMaker workspace Amazon S3 bucket:

1. [ Create and download your 3D Tiles model archive](https://cesium.com/learn/ion/cesium-ion-archives-and-exports/#create-and-download-an-asset-archive).

1. Unzip the archive into a folder.

1. Upload the entire 3D Tiles folder into the Amazon S3 bucket associated with your AWS IoT TwinMaker workspace. (See [ Uploading objects](https://docs.aws.amazon.com/AmazonS3/latest/userguide/upload-objects.html) in the Amazon S3 User Guide.)

1. If your 3D Tiles model was uploaded successfully, you will see an Amazon S3 folder path in your AWS IoT TwinMaker [Resource Library](scenes-using-resource-library.md) with type `Tiles3D`.

**Note**  
The AWS IoT TwinMaker Resource Library doesn't support directly uploading 3D Tiles models.

### Using 3D Tiles in AWS IoT TwinMaker


AWS IoT TwinMaker is aware of any 3D Tiles model uploaded to your workspace S3 bucket. The model must have a `tileset.json` and all dependent files (.gltf, .b3dm, .i3dm, .cmpt, .pnts) available in the same Amazon S3 directory. The Amazon S3 directory path will appear in the Resource Library with the type `Tiles3D`.

To add the 3D Tiles model to your scene, follow these steps:

1. On the scene composer page, choose the plus (**\$1**) sign, and then choose **Add 3D model**.

1. On the **Add resource from resource library** window, choose the path to your 3D Tiles model with the type `Tiles3D`, and then choose **Add**.

1. Click on the canvas to place the model in your scene.

#### 3D Tiles differences


3D Tiles does not currently support geometric and semantic metadata, which means that the mesh hierarchy of the original model is not available for the sub-model selection feature. You can still add widgets to your 3D Tiles model, but you cannot use features fine-tuned to sub-models: model shader, separated 3D transformations, or entity binding for a sub-model mesh. 

It is recommended to use the 3D Tiles conversion for large assets that serve as context for the background of a scene. If you want a sub-model to be further broken down and annotated then it should be extracted as a separate glTF/glb asset and added directly to the scene. This can be done with free and common 3D tools like [Blender](https://www.blender.org/). 

**Example use case:**
+ You have a 1GB model of a factory with detailed machine rooms and floors, electrical boxes, and plumbing pipes. The electrical boxes and pipes need to glow red when associated property data cross a threshold.
+ You isolate the box and pipe meshes in the model and export it into a separate glTF using Blender.
+ You convert the factory without electrical and plumbing elements into a 3D Tiles model and upload it to S3.
+ You add both the 3D Tiles model and glTF model to an AWS IoT TwinMaker scene at the origin (0,0,0).
+ You add model shader components to the electrical box and pipe sub-models of the glTF to make the meshes red based on property rules.

# Dynamic scenes


AWS IoT TwinMaker scenes unlock the power of the [knowledge graph](tm-knowledge-graph.md) by storing scene nodes and settings in an entity component. Use the AWS IoT TwinMaker console to create **dynamic scenes** to more easily manage, build, and render 3D scenes.

**Key features:**
+ All 3D scene node objects, settings, and data bindings are rendered "dynamically" based on knowledge graph queries.
+ If you use the read-only Scene Viewer in a Grafana or custom application, you can get updates to your scenes on a 30 second interval.

## Static versus dynamic scenes


**Static scenes** are composed of a scene JSON file stored in S3 that has details of all scene nodes and settings. Any change to the scene must be made to the JSON document and saved to S3. A static scene is the only option if you have a [basic pricing plan](https://aws.amazon.com/iot-twinmaker/pricing/).

**Dynamic scenes** are composed of a scene JSON file that has global settings for the scene, while all other scene nodes and node settings are stored as entity components in the knowledge graph. Dynamic scenes are only supported in standard and tiered bundle pricing plans. See [Switch AWS IoT TwinMaker pricing modes](tm-pricing-mode.md) for information on how to upgrade your pricing plan).

You can convert an existing static scene to a dynamic scene by following these steps:
+ Navigate to your scene in the [AWS IoT TwinMaker console](https://console.aws.amazon.com/iottwinmaker/).
+ On the left hand panel, click the **Settings** tab.
+ Expand the **Convert scene** section at the bottom of the panel.
+ Click the **Convert scene** button, then click **Confirm**.

**Warning**  
 The conversion from a static to dynamic scene is irreversible. 

![\[3D modeling interface with grid and a robotic arm model in the center.\]](http://docs.aws.amazon.com/iot-twinmaker/latest/guide/images/convert-scene.png)


## Scene component types and entities


In order to create scene-specific entity components, the following 1P component types are supported:
+ **com.amazon.iottwinmaker.3d.component.camera** A component type that stores the settings of a [camera widget](scenes-camera.md).
+ **com.amazon.iottwinmaker.3d.component.dataoverlay** A component type that stores the settings for an [ overlay](scenes-ee.md#scenes-ee-overlay) of an annotation or tag widget.
+ **com.amazon.iottwinmaker.3d.component.light** A component type that stores the settings of a light widget.
+ **com.amazon.iottwinmaker.3d.component.modelref** A component type that stores the settings and S3 location of a 3D model used in a scene.
+ **com.amazon.iottwinmaker.3d.component.modelshader** A component type that stores the settings of a [ model shader](scenes-editing-add-color-widget.md) on a 3D model.
+ **com.amazon.iottwinmaker.3d.component.motionindicator** A component type that stores the settings of a motion indicator widget.
+ **com.amazon.iottwinmaker.3d.component.submodelref** A component type that stores the settings of a [ submodel](scenes-ee.md#scenes-ee-submodel) of a 3D model.
+ **com.amazon.iottwinmaker.3d.component.tag** A component type that stores the settings of a [ tag widget](scenes-editing-add-tags.md).
+ **com.amazon.iottwinmaker.3d.node** A component type that stores the basic settings of a scene node like its 3D transform, name, and generic properties.

## Dynamic scene concepts


Dynamic scene entities are stored under a global entity labelled `$SCENES`. Each scene is made up of a root entity and a hierarchy of children entities that match the scene node hierarchy. Each scene node under the root has a **com.amazon.iottwinmaker.3d.node** component and a component for the type of node (3D model, widget, and so on).

**Warning**  
Do not manually delete any scene entities or your scene may be in a broken state. If you want to partially or fully delete a scene, use the scene composer page to add and delete scene nodes, and use the scenes page to select and delete a scene.