Chapter 2 inventor Component Library
Objectives of this Chapter
After reading this chapter, we will be able to do the following:
L construct, create, and useSoxtrenderarea
L use inventor tool functions for initialization and window management
L rendering a simple graphic scenario in Overlay planes mode.
L construct and create inventor components and manage these components as XT Widgets
L directly attaches components to graphic scenarios and transmits component data to applications.
L use the callback function to pass data from the component to the application.
L add Custom button controls for the inventor standard Viewer window
L use the inventor clipboard to copy and paste scenario data
This chapter discusses the inventor Component Library, which includes tool functions, rendering areas, and a set of XT components. A component is a reusable module. This module generally has a built-in user interface for interactively modifying graphical scenarios. To integrate components into our applications more easily, each component is built on the Motif-style XT widgets, which can be used independently or in combination with other XT widgets. The most important concepts described in this chapter include: two types of components-Editor(Editors) AndObserver(Viewers),StructureAndCreateComponent steps and components are managed as XT widgets. Because all components are interactive and can be used to edit objects in 3D scenarios, this chapter also describes how different types of components transmit data to the response program.
(This chapter mainly discusses the inventor component library in the Unix XT window system. However, because inventor is platform-independent, all the content discussed in this chapter is applicable to Microsoft Windows operating systems, you can simply convert xt to win to Microsoft Windows. For exampleSoxtrenderareaChangeSowinrenderarea. Translator's note)
Component Introduction
The inventor component library consists of three parts:
L XT tool functions used for initialization and window management.
L XT rendering area (The so-called static display means that there is no interaction, and users cannot use the mouse to change the observation position of the scene. Translator's note).
L a group of XT components with their own rendering areas and a user interface for modifying scene display.
For the complete translation of this chapter, please download the following link:
The inventor mentorOriginal English version. Download
The inventor mentorChinese translation. Download
The inventor mentorSample Code. Download