7.5. Finishing the Complete Open Inventor Scene

The three elements of the scene — applicator, interaction and anatomical image, preferably grouped, now have to be combined to result in one Open Inventor scene.

  1. First, connect all three groups to the same SoExaminerViewer. Make sure that the applicator and its interaction sphere are connected via a separator.

    Figure 7.16. Combining the Groups

    Combining the Groups

    [Note]Note

    Because the scene with the anatomical image can be rendered with transparencies, add it right-most to the viewer so it is rendered last.

    Figure 7.17. Combined Graphic Elements

    Combined Graphic Elements

  2. A look at the viewer tells us that the relative sizes of the graphic elements need to be aligned. This can be done by adding the scaling module SoScale, either to the applicator or the image. In our case, we will add it to the applicator, that means to the SoSeparator module. A scale factor of 10 in all directions is sufficient.

    Figure 7.18. Adding the Applicator Scaling

    Adding the Applicator Scaling

  3. Then take the applicator and move it to the body to point at whatever spot you want to point at.

    Looking at the result, it might not be the best idea to have the applicator tip at the edge of the sphere which is always aligned by its center. It may be sensible to place the tip into the sphere's center instead.

  4. Add another SoTranslation module. It needs to have an effect on the applicator, so it needs to be added to the applicator's SoGroup module.

    Figure 7.19. Improved Applicator/Interaction Arrangement

    Improved Applicator/Interaction Arrangement

This is the end of this example. The full network is delivered with the demos of MeVisLab (available via HelpWelcomemore...ApplicatorExample.mlab).

[Tip]Tip

In the chapter Chapter 10, Developing a Macro Module for an Applicator, the applicator modules will be used as the starting point for programming a Python macro.