[Top] [Prev] [Next] [Bottom]

2.1 Object Oriented Graphics

The idea behind object oriented graphics (OOG) is to supply the user with classes of geometric objects and graph objects which are completely independent of the underlying graphics engine, making it unnecessary for the user to have to learn details of low level interfaces to graphics. Most users do not wish to be bothered with the low-level and often arcane methods of dealing with a graphics engine, let alone having to know the properties of more than one graphics engine, since typically they differ so radically from one another. We believe that the typical user would like to do something like the following: take the results of some calculations and use them to specify geometric objects; hand the geometric objects to graph objects; ask the graph objects to plot themselves.

Unfortunately the goal of a set of high-level graphics objects which are independent of the underlying graphics engines is difficult (nearly impossible) to reach. This is particularly true of the two graphics engines, Gist and Narcisse, which currently underlie the OOG. Gist has far more and better capabilitiues for 2-D graphics than does Narcisse. This means that to supply relatively equivalent 2-D graphics with Narcisse, it would be necessary to write a Python or C wrapper for Narcisse which does the necessary computations. Likewise, although there is considerable overlap, each engine supplies some 3-D capabilities that the other does not, so wrappers supplying extensions to each must be written. At the time of the writing of this manual, only a small part of this work has been done, but we hope to proceed with this work in the future.

Another intrinsic difficulty is that Narcisse is much slower than Gist, so, in particular, real-time animations involving complex figures are simply not feasible in Narcisse. Part of this slowness is due to the fact that the user program and Narcisse (a separate process) communicate data back and forth via sockets, and part is simply that Narcisse internal computations, for whatever reasons, are very slow.

A third problem is that plotting solely to a file is impossible in Narcisse; it is designed to be used interactively. Narcisse plots can be sent to either a binary or ascii file in addition to being sent to a window, but these files are in a format peculiar to Narcisse. A particular Narcisse plot can be sent to a PostScript file only by clicking a button in the Narcisse GUI currently displaying that plot. On the other hand, Gist plots can be sent to an arbitrary choice of windows, PostScript files, and CGM files without interctive intervention.

The tables below indicate to the user which capabilities are available in PyGist and PyNarcisse currently, and what types of devices can be plotted to. We use the term ``not yet'' for features which will someday be implemented, and ``never'' for those which are essentially impossible.

TABLE 1. Geometry Capabilities of PyGist and PyNarcisse



PyGist


PyNarcisse


curves, including multiple


yes


yes


multiple disjoint lines


yes


not yet


quadrilateral mesh--line plot


yes


not yet


quadrilateral mesh--contour plot


yes


not yet


quadrilateral mesh--filled contour plot


not yet


yes


region plots


yes


not yet


filled polygons


yes


not yet


cell arrays


yes


not yet


2-D animation, real time


yes


never


color bar


yes


yes


axes in 3d plots


gnomon1 only


yes


surfaces--wire mesh, monochrome


yes


yes


surfaces--wire mesh, colored by data


never


yes


surfaces--flat (color filled cells)


yes


yes


surfaces--contours, filled contours


not yet


yes


surfaces--shaded by light source


yes


not yet


3-D mesh--complete cells


never


yes


3-D mesh--isosurface and plane slices


yes


yes


3-D mesh--isosurface and plane slices, split palette


yes


not yet


3-D realtime animation--moving light source


yes


maybe someday


3-D realtime animation--rotation


yes


yes (slow)

1

The gnomon is a small representation of the coordinate axes at the lower left of the picture. The name of an axis is reverse video if it points into the plane of the graph.

TABLE 2. Device Capabilities of PyGist and PyNarcisse



PyGist


PyNarcisse


Xwindow


yes


yes


multiple Xwindows


yes


yes


Xwindow on remote machine


yes


yes


file(s) only, no Xwindow


yes


never


CGM file(s)


yes


never


PostScript file(s)


yes


only from GUI


multiple files


yes


never


file in self-specific format


no


yes



[Top] [Prev] [Next] [Bottom]

support@icf.llnl.gov
Copyright © 1997,Regents of the University of California. All rights reserved.