tutorial: 3d network visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3d network... ·...

52
1 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets you create three-dimensional animations based on topology information, node relationships, performance statistics, and terrain data. You can, for example, use 3DNV to visualize network characteristics such as node placement, line-of-sight restrictions, transmission quality, throughput, delay, and message status information. This tutorial provides a quick introduction to 3DNV. It shows how you can use 3DNV to do the following tasks: Prepare a model for 3D animation. View 3D animation of a network model in the Modeler workspace (planning mode). View 3D animation of a simulation in progress (simulation mode). Save and replay a 3D animation.

Upload: others

Post on 21-May-2020

43 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

3D Network Visualizer

Objective

3D Network Visualizer (3DNV) functionality lets you create three-dimensional animations based on topology information, node relationships, performance statistics, and terrain data. You can, for example, use 3DNV to visualize network characteristics such as node placement, line-of-sight restrictions, transmission quality, throughput, delay, and message status information.

This tutorial provides a quick introduction to 3DNV. It shows how you can use 3DNV to do the following tasks:

• Prepare a model for 3D animation.

• View 3D animation of a network model in the Modeler workspace (planning mode).

• View 3D animation of a simulation in progress (simulation mode).

• Save and replay a 3D animation.

1

Page 2: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Before You Begin

To do this tutorial, you must have the following licenses available:

• Modeler

• 3D Network Visualizer GUI

• Terrain Modeling Module

• Wireless

• Discrete Event Simulation

In addition, because OpenFlight terrain is not supported on Linux, you can do this tutorial only on Windows platforms.

You should have the following software and hardware installed on your computer:

• Modeler 14.0 or later

• 3D Network Visualizer 2.1.0

• 3DNV Communications 2.1.0 (must be installed on every computer running either Modeler or 3DNV)

• 128-bit video card with at least 128MB of video memory

2

Page 3: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

This tutorial assumes you have a basic knowledge of how to use Modeler to configure nodes and run simulations.

Note—If you have problems with any of the 3DNV programs during this tutorial, read the Troubleshooting section at the end of this tutorial.

Configuring Modeler

Before beginning this tutorial, you must configure Modeler by setting three preference values.

1 Start Modeler.

2 Choose Edit > Preferences…

➥ The Preferences dialog box opens.

3 The 3DNV tutorial network uses custom icons. Set the Icon Databases preference to specify their location, as follows:

3.1 Go to the Icon Databases preference and click in its Value cell.

➥ The Icon Databases dialog box opens.

3

Page 4: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

3.2 Click the Insert button, type wireless_corps, and press <Enter> to accept the value.

3.3 Click OK to accept the changes and close the Icon Databases dialog box.

4 The 3DNV tutorial uses custom node models. Set Modeler to recompile models by removing any references to existing model repositories:

4.1 Go to the Network Simulation Repositories preference.

4.2 If the preference value is not (), click in the Value cell, delete all repository names, and close the Network Simulation Repositories dialog box.

5 The 3DNV tutorial uses the same terrain database in Modeler and the 3D Network Visualizer. To ensure that 3D positions are in synch between the two programs, Modeler needs to use an ellipsoid representation of Earth similar to the one used in the 3D Network Visualizer. This replaces the default spherical model (which is faster to compute):

4

Page 5: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

5.1 Go to the Earth Geocentric Model preference.

5.2 If the preference value is not ellipsoid, click in the Value cell and choose ellipsoid.

6 Click OK to close the Preferences dialog box.

➥ A dialog box appears indicating that the Earth Geocentric Model and Icon Databases preferences require the tool to be restarted for the changes to be taken into account. Click OK to dismiss this dialog box.

7 Quit and restart Modeler to make the icons available and to use the ellipsoid earth model.

Using Multiple Computers

The 3DNV module can be installed on the computer running Modeler or on a different computer. A different computer (as shown in the following figure) is recommended for best performance.

Running Modeler and 3DNV on Separate Computers

3D NetworkVisualizer

OPNET GUI or simulation

3DNV Communications

5

Page 6: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

If Modeler and 3DNV are installed on different computers, you must configure the installation in two ways. (If they are on the same computer, skip these steps and go to the Introduction.) First, edit the rid.mtl file on both computers:

1 Use the installation CD to install 3DNV_RTI_2.1.0 (the 3DNV Communications program) on the computer running Modeler.

Note—The RTI was installed on the 3DNV computer as part of the 3DNV installation.

2 On one computer, use a text editor to open the file <install_dir>\3DNV\2.1.0\configs\rid.mtl, where <install_dir> is the path to the software (for example, C:\Program Files\<install_dir>).

3 Confirm that the file contains the following line:

(setqb RTI_tcpForwarderAddr "<ip_addr>")

where <ip_addr> is the IP address of the computer on which the 3DNV Communications program will be run.

4 Save the file (if you needed to add the line).

5 Repeat steps 2–4 for the other computer.

6

Page 7: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Next, you must copy a terrain directory to make it available to Modeler.

1 On the Modeler computer, create the following directories in the <install_dir>\3DNV\2.1.0 directory:

\3d_visualizer\data

\terrain\Monterey

\Monterey

2 Copy the contents of the <install_dir>\3DNV\2.1.0\3d_visualizer\data\terrain\Monterey directory from the 3DNV computer to the same location on the Modeler computer.

When this tutorial asks you to run 3DNV programs (for example, 3DNV Communications and 3D Network Visualizer), run them on one computer and Modeler on the other.

7

Page 8: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Introduction

The 3DNV_Tutorial network consists of 20 mobile MANET nodes located in the vicinity of Monterey, California. These nodes are clustered in four groups representing tanks, troop carriers, airplanes, and helicopters.

3DNV_Tutorial Network

During the course of a simulation, each group of nodes follows a trajectory across the terrain, converging on a point near the center of the map. As they move, the nodes communicate with each other—initially with other nodes of the same group and then with other groups as they get closer.

F-16 Falcon airplanes

M1A2 Abrams tanks

M-113 armored personnel carriers

UH-60A Black Hawk helicopters

8

Page 9: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

3D Animation Architecture

Modeler and 3DNV work together as members of an HLA federation. HLA (High-Level Architecture) is a protocol that allows two or more programs to exchange data and run in time-step together.

Sample 3D Animation Federation

There are three parts to the federation used to display 3D animation.

Parts of a 3D Animation Federation

3DNV and Modeler work together as members of an HLA federation.

Part Purpose Program

Data generator

Produce animation data Modeler GUI,simulation process, Multi-Federate Logger for 3DNV

Run-time infrastructure (RTI)

Moderate communications within the federation

3DNV Communications

One or more data receivers

Display or record the animation data

3D Network Visualizer, Multi-Federate Logger for 3DNV

Data Generator RTI Data

Receiver

9

Page 10: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Preparing a Model for 3D Animation

Before you can view 3D animation of a network model, you must configure the model to work with 3DNV. There are two basic requirements:

• The network model must have a terrain database specified.

• The nodes to be animated must be mapped to specific shapes (called entities in 3DNV) using a 3DNV mapping library.

(In this tutorial, we use the default mapping library, which relies on the 3DNV Mapping attribute definition discussed later.)

Typically, you will also assign trajectories to mobile nodes, so that their movement can be visualized. This is not a requirement for using 3DNV, however.

Animation with 3DNV requires a network model with a terrain database and nodes mapped to 3DNV entities.

10

Page 11: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

You’ll begin this tutorial by modifying a sample network model to specify a terrain database, add the necessary attribute, and map the nodes to the appropriate 3DNV entities.

1 Start Modeler, if it is not already running.

2 Choose File > Open…

3 In the file browser, go to the <install_dir>\<release>\ models\std\tutorial_req\module\3dnv directory, where <install_dir> is the path to the software (for example, C:\Program Files\<install_dir>). Then open the 3dnv_tutorial file.

➥ The 3dnv_tutorial network (baseline scenario) opens in the Project Editor.

4 Choose File > Save As… and save the project in your default model directory as <your_initials>_3dnv_tutorial.

11

Page 12: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

The network model uses an elevation map of the Monterey region. A matching terrain database must be specified. You will specify a terrain database in OpenFlight format, which is the preferred type for 3DNV.

1 Choose Topology > Terrain > Specify Terrain Data Directory…

➥ The Terrain Data Directory Preferences dialog box opens.

2 In the Format pull-down menu, select OpenFlight.

3 Click the Browse… button and use the file browser to choose the file <install_dir>\3DNV\2.1.0\3d_visualizer\data\terrain\Monterey\Monterey\N36_45_0W121_30_0.flt.

4 Click OK to close the dialog box.

12

Page 13: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

To display sites (nodes and subnets) properly in 3D Network Visualizer, Modeler must know how to map each one to a 3D entity model that 3D Network Visualizer can display. This is done by assigning a value to the 3DNV Mapping attribute on each site to be animated. 3DNV ships with a default mapping library that uses the value of this attribute to determine how to map node and subnet instances to 3D entities.

In most cases, you will need to add the 3DNV Mapping attribute to each site to be displayed. A public attribute definition named 3DNV_Mapping ships with Modeler. You can use this definition to add the 3DNV Mapping attribute to most node models and to node and subnet instances.

You will now add a 3DNV Mapping extended attribute to each of the mobile nodes in the model. You could do this by modifying the underlying node model, but this requires OPNET Modeler and the ability to freely change node models that might be shared by many users. Also, although a single node model is used in this tutorial, it is much simpler to add an extended attribute to a set of nodes without having to modify all of their models.

13

Page 14: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Add and configure the 3DNV Mapping extended attribute on each mobile node:

1 Choose 3DNV > Manage 3DNV Entities…

➥ The Manage 3DNV Entities and Associated Visualizations dialog box opens.

Manage 3DNV Entities and Associated Visualizations Dialog Box

14

Page 15: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

2 Click the + for the Monterey subnet.

➥ The tree expands to show all nodes in the subnet. Each node has a corresponding row in the table to the right. Because none of the nodes have a 3DNV Mapping attribute yet, no values are shown in the table.

3 Select the five Abrams_tank nodes in the tree.

4 On the Set 3DNV Mapping Attribute page, choose Land - Vehicle - M1A2 Abrams from the Type pull-down menu.

5 Click the Apply to Selected Nodes button.

➥ A 3DNV Mapping extended attribute is added to each of the selected nodes, with values based on the selected fields on the Set 3DNV Mapping Attribute page.

15

Page 16: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Tanks with 3DNV Mapping Attribute Added

The Abrams tank nodes will now look like Abrams tanks in the 3DNV animation. Repeat the preceding steps 3–5 to set the mapping of the remaining nodes, as follows:

• Black Hawk nodes – set Type to Air - Helicopter - UH-60A Black Hawk

• F16 nodes – set Type to Air - Plane - F-16 Falcon

• M113 nodes – set Type to Land - Vehicle - M113 Armored Personnel Carrier

1 Click OK to commit the changes to the modified nodes.

16

Page 17: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

The network model is now configured for use with 3D Network Visualizer. Save it and continue with the tutorial.

1 Choose File > Save.

17

Page 18: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Viewing 3D Animation in Planning Mode

When you have a network model that is configured for 3D animation, you can use 3DNV to examine the placement of nodes in the surrounding terrain and to visualize movement along trajectories. The mode in which you view animations of the GUI workspace is called planning mode.

Planning mode lets you visualize node placement and movement from the workspace, without running a simulation.

Viewing Node Placement

First, open a project and scenario that has been configured for 3D animation.

1 If necessary, open the project <your_initials>_3dnv_tutorial. Make sure the current scenario is baseline.

18

Page 19: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Next, start the 3D animation software, select a terrain database for the animation background, and start communications between Modeler and 3DNV.

1 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 2.1.0 > 3DNV Communications 2.1.0.

➥ 3DNV Communications is the RTI that controls the transfer of data from Modeler to 3DNV. It starts with an empty command window (minimized).

2 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 2.1.0 > OPNET 3D Network Visualizer 2.1.0.

➥ After a short delay, the 3D Network Visualizer window opens. At first, no terrain or objects are displayed, as shown in the following figure.

19

Page 20: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Initial 3D Network Visualizer Window

3 From the 3D Network Visualizer menu bar, choose File > Open Database…

➥ A file browser opens with a list of available terrain configuration (.mtl) files. These files specify various types of information needed by 3D Network Visualizer, including a reference to an OpenFlight terrain database.

4 Select monterey.mtl and click Open.

➥ This configuration file references the same terrain database specified earlier in Modeler. 3D Network Visualizer displays the terrain.

20

Page 21: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

5 In Modeler, choose 3DNV > Display 3D Network View.

➥ A checkmark appears in front of the Display 3D Network View menu item, showing that it is enabled. Modeler establishes communications with 3D Network Visualizer.

Now you can select the node you want to watch in the animation. For this tutorial, we’ll follow one of the Black Hawk helicopters.

1 In the 3D Network Visualizer window, click on the Objects tab.

➥ You will see a treeview listing all of the nodes in the connected model.

Objects Treeview

Objects tab

Black Hawks

Attach button

21

Page 22: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

2 Double-click on the second Black Hawk object in the treeview (Black_Hawk4) and examine the displayed information. You can use this information to identify particular nodes in the list. Click Close when finished.

3 Click on Black_Hawk4 in the treeview to select it as the object to follow.

4 Click the Attach button.

➥ Black_Hawk4 is attached for viewing and is displayed in the 3D Network Visualizer window. The node name and view mode are listed in the lower left corner of the window.

This step attached Black_Hawk4 in the default view mode (Compass), which keeps the view constant relative to the attached object. 3D Network Visualizer includes a variety of view modes. For example, you can view the animation from a fixed point in space or view it as if you were riding on the attached object.

You can now see Black_Hawk4 in the 3D Network Visualizer window. It looks like a helicopter, as specified by the DIS Entity Type attribute of the 3DNV Mapping compound attribute (Air - Helicopter - UH-60A Black Hawk).

22

Page 23: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

You can use planning mode to help place nodes at desired points in the terrain. As you move a node in the Modeler workspace, the animation view changes correspondingly.

1 In Modeler, zoom in on the Black Hawk group and some of the surrounding terrain.

2 Find Black_Hawk4 and drag it to a new location in the workspace.

➥ The node moves in the 3D Network Visualizer window and the surrounding landscape changes accordingly.

23

Page 24: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

3 Drag Black_Hawk4 to a position close below Black_Hawk1.

➥ You will see several blue circles near Black_Hawk4. These represent the positions of other nodes in the model. You can move the cursor near or over a circle to display information about that object.

Object Information

24

Page 25: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Viewing Node Movement

Planning mode is also useful for visualizing the trajectories of mobile nodes. 3DNV lets you see the relative positions of multiple nodes as they move.

To see this, you must first add trajectories to the mobile nodes by editing their Trajectory attributes. To save time here, you will use a scenario pre-configured with four different trajectories.

1 In Modeler, choose 3DNV > Display 3D Network View.

➥ This toggles 3D display off. The current scenario is disconnected from 3DNV and all node objects disappear from the 3D Network Visualizer window.

2 Choose Scenarios > Switch To Scenario > configured.

➥ A scenario that has been pre-configured with mobile node trajectories opens.

3 Connect the new scenario to 3DNV: choose 3DNV > Display 3D Network View.

➥ Modeler reconnects to 3DNV.

25

Page 26: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

4 In the 3D Network Visualizer window, select Black_Hawk3 in the Objects treeview, then click Attach.

To move the nodes automatically, you must use the Modeler time controller. This will step through a specified time range, updating the position of each mobile node at each time step.

1 In Modeler, choose View > Show Time Controller (or press Ctrl+Alt+T).

➥ The time controller appears.

Time Controller Dialog Box

In your networks, you will need to set the time range and step size to useful values. In this tutorial, however, the start and stop times have been preset to match the duration of the mobile node trajectories. The time step needs some adjustment, however.

2 Set the time controller for a smaller time step, to produce smoother-looking animation:

26

Page 27: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

2.1 In the time controller, click the Configure… button.

➥ The Time Controller Settings dialog box appears.

Time Controller Settings Dialog Box

2.2 Change the time step value to 5 seconds (0h0m5.000s).

2.3 Notice that the Loop checkbox is selected. This will cause the time controller to loop repeatedly through the specified time range.

2.4 Click OK to close the Time Controller Settings dialog box.

3 In the time controller, click the Play ( ) button.

➥ The time controller steps through its time range. At each time step, node positions are updated in the Modeler workspace and 3D Network Visualizer shows the node movement between positions.

27

Page 28: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

In addition to following a single object, you also can follow the helicopters as a group:

1 From the 3D Network Visualizer menu bar, choose View Mode > Manage Group…

➥ The Manage Groups dialog box opens.

2 Select Black_Hawk1 in the Attachable Entity/Aggregate List and click the –> button.

➥ Black_Hawk1 is added to the Group list.

3 Repeat step 2 to add the remaining Black Hawks (2–5) to the Group list.

4 Click Close.

5 In the 3D Network Visualizer window, click the Navigation tab.

➥ The navigation pane appears.

6 In the Current View Mode pull-down menu, select Group.

➥ The animation window changes to a view including all objects in the group.

If the entire group is not visible, click the bottom of the zoom control until all members of the group can be seen.

28

Page 29: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

7 In the time controller, click the Pause ( ) button to stop the animation.

Changing the Viewpoint

To get a different view of the node movement, you can change the animation window to look down on the terrain.

3DNV uses the concept of an eyepoint to represent the position of the observer in an animation. Using the controls at the top of the Navigation pane, you can move the eyepoint in three-dimensional space and change the direction in which the eyepoint looks.

3DNV lets you view an animation from any location in or around the network terrain.

Navigation ControlsPosition—move eyepoint up, down, left, or right

Zoom—move eyepoint forward or back

Direction—change “look” direction

Reset eyepoint to default position

Increase (+) or decrease (-) navigation step size

29

Page 30: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

1 In the Current View Mode pull-down menu, select Tether, then click the Reset button.

➥ The animation window returns to a close-up view of Black_Hawk3.

2 Click and drag the zoom control up until Black_Hawk3 fills the window, stopping close to where the helicopter disappears from view. (You might need to reduce the navigation speed using the - button to stop at the desired point.)

➥ This moves the eyepoint forward until it is above Black_Hawk3.

3 Click and drag the direction control down until the elevation display in the top right corner of the 3D Network Visualizer window reads –90.

➥ This rotates the look direction until you are looking straight down at Black_Hawk3.

30

Page 31: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

4 Click and drag the position control up until you have a bird’s-eye view of the Black Hawk group. An altitude of about 1500 meters (as shown in the lower right corner of the 3D Network Visualizer window) is good.

➥ This increases the elevation of the eyepoint to give you a wider view of the terrain.

5 In the Modeler time controller, click the Play ( ) button.

➥ The time controller resumes stepping through its time range.

6 Let the animation run for a while, then click the Pause ( ) button to stop the animation.

31

Page 32: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

This overhead view will be useful later. 3D Network Visualizer lets you both capture a view for reuse during the current run and also save sets of captured views for use in later runs. A captured view includes the attached object, view mode, eyepoint location, and look direction.

1 In the Captured Views pane of the 3D Network Visualizer window, click the Capture button.

➥ The view is captured and a default name appears in the Captured Views list.

2 Double-click on the name of the captured view, type Overhead, and press <Enter>.

➥ The view is renamed.

3 From the 3D Network Visualizer menu bar, choose File > Save Views…

➥ A Save As dialog box opens.

Capture button

32

Page 33: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

4 Type <your_initials>_views and click Save.

There are many other ways to view an animation. If you wish, try moving the eyepoint and look direction for different views of the animation. You can also try some shortcuts. For example:

• Shift + left-click on a node makes that node the attached entity. (Press the Reset button to jump to a close-up of it.)

• Shift + left-click on the terrain changes the view mode to Pivot. This puts a pivot point in the terrain that acts as the new reference for the eyepoint.

• Shift + left-drag to scroll around the terrain, moving the pivot point to a new location.

Note—The functions of the navigation controls change in different view modes. If you “lose” the attached node, you can click the Reset control to return to the default view.

One interesting view is to set a pivot in the middle of a group of objects, reset the view, and rotate the look direction 360° to see the nodes all around you.

33

Page 34: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

This ends our look at using 3DNV in planning mode. Disconnect the scenario and quit 3DNV, as follows.

1 In the time controller, click the Close button.

➥ The time controller closes and all nodes return to their starting positions.

2 In Modeler, choose 3DNV > Display 3D Network View to disconnect the scenario.

3 From the 3D Network Visualizer menu bar, choose File > Exit and click Yes in the confirmation dialog box.

4 Right-click on 3DNV Communications 2.1.0 in the Windows task bar and select Close.

34

Page 35: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Viewing 3D Animation in Simulation Mode

In addition to viewing node movement and terrain in 3DNV, you can visualize simulation results while a simulation is running. This is called simulation mode. In simulation mode, you can view the following types of simulation data in 3DNV:

• Packet transmission and reception statistics

• Membership of nodes in specific receiver groups

• Successful and failed transmissions

You can use the APIs in the 3D Network Visualizer Package to create custom visualizations of other types of simulation data as well, such as:

• The effect of terrain on wireless communications

• Individual packet transmissions

• Antenna transmission and reception areas for mobile nodes

• Directional networking antenna patterns

• Interference levels for individual frequencies

Simulation mode lets you view a 3D animation showing data generated by a simulation as the simulation runs.

35

Page 36: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

To use simulation mode, you must first configure the network model for 3D animation, as you did in the first part of this tutorial.

1 If necessary, start Modeler and open the project <initials>_3dnv_tutorial. Make sure the current scenario is configured.

Next, specify the kinds of simulation data to visualize. Modeler provides several utility objects that are pre-configured for certain kinds of simulation data. The utility objects you will use in this tutorial are:

• ovis_anim_comm_lines—generates 3DNV animation visualization of successful and failed packet transmissions by drawing a line between the transmitting and receiving nodes

• ovis_anim_pkstat—generates 3DNV animation visualization of the packet transmission and reception statistics for each node containing transmitters and receivers

• ovis_anim_sim_time_display—generates 3DNV animation visualization of the simulation time

36

Page 37: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

OPNET Modeler users can develop their own utility objects using the 3DNV API, a extensive collection of functions that support custom 3D animation. You can double-click on these utility objects to drill down to the process model and examine the code used to generate the animation (primarily in the enter execs and header block).

Modeler provides utility objects pre-configured to animate specific kinds of simulation data. Developers can modify these or create their own.

Add some animation utility objects to the network model.

1 Click on the Open Object Palette tool button.

➥ The object palette opens.

2 Scroll the palette tree till you see the 3DNV_Animations tree node, then expand that tree to display the content of the palette.

➥ A selection of 3DNV utility objects appear in a Node Models tree sub-node.

37

Page 38: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

3DNV_Animations Object Palette

3 Drag an instance of the ovis_anim_comm_lines object into the workspace near the rx_groups object (the exact location is not important).

4 Right-click on the ovis_anim_comm_lines object, select Edit Attributes, and set the following attribute values:

• name –> comm_lines

• Transmission Line Color –> green

Click OK to close the Attributes dialog box.

5 Drag an instance of the ovis_anim_pkstat object into the workspace and set its attributes as follows:

• name –> pk_stats

38

Page 39: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

• Reception Statistic Color –> white

• Transmission Statistic Color –> white

Click OK to close the Attributes dialog box.

6 Drag an instance of the ovis_anim_sim_time_display object into the workspace and set its attributes as follows:

• name –> sim_time

• Color –> yellow

Click OK to close the Attributes dialog box.

7 Close the object palette.

8 Save your changes to the model.

Next, start the 3D animation software and prepare it to receive animation data from a simulation.

1 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 2.1.0 > 3DNV Communications 2.1.0.

2 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 2.1.0 > OPNET 3D Network Visualizer 2.1.0.

39

Page 40: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

3 From the 3D Network Visualizer menu bar, choose File > Open Database…

4 Select monterey.mtl and click Open.

5 From the 3D Network Visualizer menu bar, verify that Options > Display Remote Graphics has a checkmark next to it. If not, select the menu item to enable the checkmark.

(This step tells 3D Network Visualizer to add the graphics generated by the animation utility objects to its display. This is not necessary when utility objects are not used.)

Now prepare the Modeler simulation to send animation data to 3DNV.

1 In Modeler, choose DES > Configure/Run Discrete Event Simulation (or click the “running man” button).

➥ The Configure/Run DES dialog box appears.

2 In the treeview of the dialog box, select Outputs > Animation > 3D.

➥ The dialog box displays the 3D animation tabbed page.

40

Page 41: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

3 Select the Use 3DNV Module checkbox.

➥ This tells the simulation to generate 3DNV data. The other 3DNV controls become enabled.

One of these controls is Record history in file with an appropriately-named file. All 3DNV data generated by the simulation via Ovis APIs will be recorded in this file for later playback. This is independent of actually sending live 3DNV updates to the 3D Network Visualizer during the simulation. This will allow you to replay the 3DNV visualization afterwards from the graphical environment.

4 Select the Live output via 3DNV Communication checkbox.

➥ This tells the simulation to send generated animation data directly to the 3D Network Visualizer.

5 In the treeview, select Execution > Advanced > Kernel Preferences.

➥ The dialog box displays the Kernel Preferences tabbed page.

41

Page 42: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

6 In the Real-time execution ratio field, enter 5.

➥ This tells the simulation to run at up to five times real-time speed. In other words, the simulation will pace events so that the run takes about 6 minutes of clock time (30 minutes of simulation time divided by the real-time ratio of 5).

Finally, run the simulation and view the animation in 3D Network Visualizer.

Note—If the simulation and 3D Network Visualizer are running on the same computer, they might run quite slowly. Typically, you should either run Modeler and 3D Network Visualizer on different computers or capture the simulation output and replay it in 3D Network Visualizer later (as you will do in the next part of this tutorial).

For best results, quit all programs on your computer except those needed by this tutorial.

1 In the Configure/Run DES dialog box, click the Run button.

➥ The simulation starts up.

42

Page 43: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

After a delay, the simulation connects to 3DNV. (The delay will be longer the first time the simulation is run, while Modeler compiles some of the models.)

2 In the 3D Network Visualizer window, click the Objects tab.

3 After the node list appears, select Black_Hawk3 and click the Attach button.

➥ The selected object appears in the 3D Network Visualizer window. The simulation data you specified also appears, as shown in the following figure.

Visualization Showing Simulation Data

43

Page 44: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Packet statistics for an object appear in white near the object.

Green lines connect transmitting and receiving nodes to show successful communications. Red lines represent failed communications.

The simulation time appears in the lower left corner of the window. This time is updated whenever a packet is transmitted or received.

Note—Updates to the animation display occur only when animation events are generated by the simulation; for example, when packet broadcasts force node position updates. As a result, updates occur at irregular intervals and the animation can appear “choppy” at times.

4 After watching the animation for a while, you can switch to the overhead view you saved; this provides a better view of the communication lines:

4.1 From the 3D Network Visualizer menu bar, choose File > Load Views…

4.2 Select <your_initials>_views.mtl in the file list and click Open.

➥ The saved view appears in the Captured Views list (in the navigation pane).

44

Page 45: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

4.3 Click Overhead in the Captured Views list.

➥ The animation changes to the overhead view you saved earlier, showing Black_Hawk3 and near-by objects.

Visualization Showing Simulation Data - Overhead View

5 When the simulation completes:

5.1 In the Simulation Sequence dialog box, click the Close button.

5.2 In Modeler, choose File > Save.

5.3 From the 3D Network Visualizer menu bar, choose File > Exit and click Yes in the confirmation dialog box.

45

Page 46: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Replaying 3D Animation

During the simulation all the 3DNV outputs were recorded in a 3DNV history file, as well as sent out to the 3D Network Visualizer. The recorded history can be played back later to show part or all of the 3D visualization.

Now you can play back the recorded animation and view it in 3D Network Visualizer.

1 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 2.1.0 > OPNET 3D Network Visualizer 2.1.0.

2 From the 3D Network Visualizer menu bar, choose File > Open Database…

3 Select monterey.mtl and click Open.

4 From the 3D Network Visualizer menu bar, check that Options > Display Remote Graphics is enabled.

5 In the Project Editor, choose 3DNV > Play 3DNV History…

➥ A file browser opens.

46

Page 47: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Choose 3DNV History File

6 Verify that the listed file matches the current scenario and click OK.

➥ The 3DNV History playback dialog box appears.

3DNV History Playback Dialog Box

47

Page 48: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

The treeview shows the Ovis entities and decorations that are defined after all operations taking place during events at simulation time 0 have been applied.

At this point, none of the Ovis entities or decorations have been made known to 3D Network Visualizer. When this happens, any object with a checkmark will be made known.

Unchecking items allows you to reduce the amount of traffic sent to 3D Network Visualizer and focus your attention to the items of interest. In this tutorial, let’s focus on the communications between helicopters.

1 Uncheck all of the Abrams tanks, F-16 planes, and M-113 armored carriers.

2 Click on the Enable RTI button.

➥ This creates appropriate Ovis entities for the five Black Hawk helicopters and their associated entities.

3 In the 3D Network Visualizer window, click the Objects tab.

4 After the node list appears, select Black_Hawk3 and click the Attach button.

48

Page 49: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

5 Click on the Play button.

➥ As the time value increases, the corresponding Ovis changes for checked objects are sent to the 3D Network Visualizer, exactly as happened in simulation mode.

6 At some point, press the Pause button to stop the playback.

Note—After you stop the playback, 3D Network Visualizer will continue to display animation.

7 Close the 3DNV history playback dialog box.

➥ The Ovis entities and decorations disappear from the 3D Network Visualizer.

8 Close the project, 3D Network Visualizer, and 3DNV Communications.

49

Page 50: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Troubleshooting

This section provides solutions to some common problems that can occur when using 3D Network Visualizer.

If you have completed this tutorial successfully, you can skip ahead to the Summary.

Problem: 3D Network Visualizer no longer updates its display when nodes move in Modeler.

Solution:

Communications between Modeler and 3D Network Visualizer time out after a period of disuse. To reestablish communications:

1 Disconnect the current scenario from 3DNV (in Modeler, choose 3DNV > Display 3D Network View).

2 Quit the 3D Network Visualizer and 3DNV Communications programs.

3 Restart the 3DNV programs, as follows:

50

Page 51: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

3.1 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 2.1.0 > 3DNV Communications 2.1.0.

3.2 In Windows, choose Start > Programs > OPNET 3D Network Visualizer 2.1.0 > OPNET 3D Network Visualizer 2.1.0.

3.3 From the 3D Network Visualizer menu bar, choose File > Open Database…

3.4 Select monterey.mtl and click Open.

4 Reconnect the Modeler scenario (choose 3DNV > Display 3D Network View).

5 Attach an object in 3D Network Visualizer.

Problem: While moving the eyepoint, you lose sight of the attached object and can’t find it again.

Solution:

Choose View > Reset from the 3D Network Visualizer menu bar or click the Reset button in the navigation controls.

51

Page 52: Tutorial: 3D Network Visualizer - pudn.comread.pudn.com/downloads166/ebook/760022/3D Network... · 3D Network Visualizer Objective 3D Network Visualizer (3DNV) functionality lets

Summary

This tutorial has presented a quick introduction to 3DNV. You have seen how to:

• Prepare a model for 3D animation.

• View 3D animation of a network model in the workspace (planning mode).

• View 3D animation of a simulation in progress (simulation mode).

• Save and replay a 3D animation.

For more details about using 3D animation in Modeler, refer to Animation Viewers Reference Manual.

52