Roads

更新时间:
复制 MD 格式

Roads are a basemap layer in 3D City Builder that define the style of roads in a procedurally generated city. You can configure the data precision to L1 or L2. This topic uses L2 precision as an example to explain the style and data configurations for roads, including shadows, environment map intensity coefficients, and surface types.

In the Layers list in the navigation pane on the left of the scene editor, click the Roads layer. In the configuration panel, you can configure the style and data for the Roads layer.

Note

If the layer list does not contain Road, this indicates that the Road layer has not been added. To add the layer, see Add a sub-widget.

Style panelimage.png

  • General: Configure the general parameters for the roads.

    Parameter

    Description

    Shadow

    Sets the shadow style for the roads. Turn the Cast Shadow switch on or off to control the shadow effect. This parameter is configurable only when data precision is set to L2.

    Light Effect

    Drag the slider to set the luminous intensity coefficient for the roads. The value ranges from 0 to 1.

  • Graphics: Configure the graphic style for the roads.

    Parameter

    Description

    Sidewalk

    Sets the graphic style of the sidewalks. This parameter is configurable only when data precision is set to L2. You can adjust the UV tile values on the x-axis and y-axis, color, base color map style, roughness value, roughness map style, metalness value, metalness map style, normal map style, ambient occlusion map intensity value, ambient occlusion map style, emissive color, and emissive map style.

    Note

    Textures must be in PNG or JPG format.

    Road Segment Top

    Sets the graphic style of the road segment tops. You can adjust the UV tile values on the x-axis and y-axis, base color, base color map style, roughness value, roughness map style, metalness value, metalness map style, normal map style, ambient occlusion map intensity value, ambient occlusion map style, emissive color, and emissive map style.

    Note

    The supported image formats for textures are PNG and JPG.

    Intersection Top

    Sets the graphic style of the intersection tops. You can adjust the UV tile values on the x-axis and y-axis, base color, base color map style, roughness value, roughness map style, metalness value, metalness map style, normal map style, ambient occlusion map intensity value, ambient occlusion map style, emissive color, and emissive map style.

    Note

    Textures support only PNG or JPG images.

    Side

    Sets the graphic style of the road sides. You can adjust the UV tile values on the x-axis and y-axis, base color, base color map style, roughness value, roughness map style, metalness value, metalness map style, normal map style, ambient occlusion map intensity value, ambient occlusion map style, emissive color, and emissive map style.

    Note

    Textures must be in PNG or JPG format.

  • Road Decorations: Configure the model style for road decorations. This parameter is configurable only when data precision is set to L2.

    Parameter

    Description

    Model Mapping

    Click the Add icon or Delete icon icon to the right of Model Mapping to add or delete a model mapping. Click the Arrange horizontally icon or Arrange vertically icon icon to configure the arrangement of multiple model mappings. Click the Copy icon icon to copy the currently selected model mapping and add a new one with the same configuration.

    • Type: The type of the model mapping.

    • Model Resource Link: The resource URL of the model mapping.

    • Scaling Size: Set the scaling ratios of the model mapping on the x-axis, y-axis, and z-axis. The value ranges from 0.01 to 100.

  • Interaction: Configure the interaction style for the roads.

    Parameter

    Description

    Click Interaction

    Turn the Click Interaction switch on or off. This controls whether the roads can be picked when clicked.

Data panelimage.png

Reselect Data: In the data panel, click Reselect Data at the bottom to open the Select Scope dialog box. In the dialog box, you can reselect the data range for the road layer. For more information about selecting a scene scope area, see Create a scene using official base data.

Refresh Data: Refreshes the data that has been added to the data panel.

Blueprint interaction

  1. In the scene editor, click the Export to Blueprint Editor icon to the right of the Road layer in the layer list.

  2. Click the 蓝图图标 icon in the upper-left corner of the page.

  3. On the blueprint editor configuration page, click the Roads layer in the import node bar. The blueprint editor configuration parameters for the roads appear on the canvas, as shown in the following figure.

    • Events

      Event

      Description

      When Data Request Is Completed

      An event that is triggered after a data API request is returned and processed by a filter. The event also returns the processed data in JSON format. For a data example, see the Data Response area on the Data tab in the widget's configuration panel to the right of the canvas editor.

      Rendering Completed

      An event that is triggered when the road widget finishes rendering. The event also returns data of the object type.

      Left-click

      A left-click event returns data as an object.

    • Actions

      Action

      Description

      Request data API

      Sends a new request for server-side data. Data from input data processing nodes or layer nodes is passed as parameters. For example, an ingest endpoint has an API data source set to https://api.test. If the data passed to the Request data API action is { id: '1'}, the final API request is https://api.test?id=1.

      Import data API

      Processes data into the component's drawing format. The data is then imported and the component is redrawn. This action does not send a new request for server-side data. For data examples, see the Data Response area on the Data tab of the component's configuration panel in the canvas editor.

      Show component

      Shows the component. No parameters are required.

      Hide component

      Hides the component. No parameters are required.