Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
HP-UX Starbase Device Drivers Manual - Vol1: HP 9000 Series 700 Computers > Chapter 2 HP VMX Device Driver

Device Description

» 

Technical documentation

Complete book in PDF
» Feedback
Content starts here

 » Table of Contents

 » Index

What is HP VMX?

In order to answer the question "What is HP VMX?" let us first examine its name. HP VMX is a shorthand name for the HP Virtual Memory X driver and is derived from its implementation and usage. Briefly, HP VMX offers the capability to render 3D graphics images into Virtual Memory for display in the X11 Windows client-server environment.

While HP VMX is technically a Starbase "device driver" it differs somewhat from the traditional definition. A traditional Starbase device driver implements device-specific code necessary to support the device-independent Starbase graphics library on a particular graphics device (or family of graphics devices). HP VMX, on the other hand, implements the code to support the device-independent Starbase graphics library in an X11 graphics window — independent of the underlying hardware on which the X window resides. HP VMX accomplishes this in two steps:

  1. HP VMX renders graphics images into virtual memory.

  2. HP VMX displays these images in the targeted window using standard X11 protocol.

Because HP VMX uses the X11 protocol to display the images, this targeted window may be local or remote on: HP or non-HP hardware, a workstation, an X terminal, or a PC[4]. The only requirement is that you run to an X11 graphics window. Note, too, that the application is not responsible for displaying the images via X11 protocol; this is handled by the HP VMX driver.

You may recognize similarities between HP VMX and the "Starbase-on-X11" (SOX11) device driver. While the X11-based client-server models are similar, differences do exist in both functionality (HP VMX has a richer set) and performance (differs per functionality). Please see the section "HP VMX vs. SOX11" for an overview comparing and contrasting the two drivers.

How Do You Use HP VMX?

The following example shows the steps necessary to run an application using VMX. This example is intended to give you a feel for the kinds of steps necessary to use VMX, rather than provide a detailed tutorial on all the steps necessary to explain each step. Refer to the sections throughout this chapter, including, "HP VMX Licensing", "To Compile and Link with the Device Driver", and "To Open and Initialize the Device for Output" for details on these steps.

HP VMX Usage Example

In order to run a PowerShade application to an HP700/RX X Station across the network from an HP 735 (running 9.0 HP-UX or later), you need to:

  1. Purchase the "PowerShade for HP700/RX X Stations" license to allow you to run HP VMX to a remote X11 server.

  2. Make sure PowerShade is installed on your server (the HP 735).

  3. Execute an xhost command from your X Station to give the HP 735 permission to access your X Station's local display server. For example,

    xhost hpdspsvr
  4. Create an hpterm window and rlogin to the HP 735 from your X Station.

  5. Set the DISPLAY environment variable to the X Station's DISPLAY in this HP 735 hpterm window. For example, in ksh:

    export DISPLAY=hpxterm:0.0
  6. Run your application from this window.

The application is now executing on the HP 735 (hpdspsvr), and displaying X and Starbase output on the X Station (hpxterm:0.0).

This example illustrates that it is easy to run your Starbase applications across the network in the X11 client-server model using HP VMX.

NOTE: The application in this example did not need to be re-linked, nor were any code changes necessary. This assumes that the application is linked with shared libraries, and the application uses NULL as the driver parameter to gopen.

How Does HP VMX Work?

Now that you have some understanding of what HP VMX is, and how you can use HP VMX, let us take a look at how HP VMX works.

Overview

Instead of rendering Starbase 3D graphics images to a dedicated graphics display subsystem, HP VMX is designed to render these Starbase 3D graphics images to a virtual memory frame buffer and display these images to an X11 window using standard X11 protocol.

Here are the basic steps HP VMX performs:

  1. VM (Virtual Memory) frame buffer allocation — At gopen time, the HP VMX driver allocates virtual memory for use as a frame buffer. This VM frame buffer is allocated using calloc and its size is based upon the size of the X11 window being gopened.

  2. Rendering to the VM frame buffer — After a successful gopen, HP VMX renders Starbase output primitives in the allocated VM frame buffer. The appropriate primitive attributes and device control are applied during rendering.

  3. Display of the VM frame buffer — Upon application request, HP VMX displays the contents of the VM frame buffer. Application requests come in the form of one of the following Starbase calls:

    • make_picture_current

    • flush_buffer

    • dbuffer_switch

    (See the section "Synchronization" for more details.)

    Because HP VMX is always operating in the X11 windows environment, the display of the VM frame buffer to the gopened window is handled through the use of standard X11 protocol.

    These basic HP VMX steps are applicable to both single- and double-buffering. (HP VMX supports only 8/8 double buffering).

HP VMX Configurations

The HP VMX driver supports only 8-bit X11 windows. Attempts to gopen windows with a depth other than 8 will result in a Starbase error.

The HP VMX driver supports the following configurations:

  • 8-bit indexed color (CMAP_NORMAL, CMAP_MONOTONIC), single-buffered, or 8/8 double buffered

  • 8-bit direct color (CMAP_FULL), single-buffered or 8/8 double-buffered



[4] Refer to the "HP VMX Support" section for details on official HP support of HP VMX.

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© 1989 - 1995 Hewlett-Packard Development Company, L.P.