1、for Information Systems - Computer Graphics - Graphical Kernel System (GKS Functional Description I ANSIINCITS 124-1985 (R2002) (includes ANSI INCITS 124.1-1985 formerly ANSI X3.124.1-1985) Developed by Where IT all begins ANSI X3.124- 1985 (incldS ANSI X3.124.1-1985) American National Standard for
2、Information Systems - Computer Graphics - Graphical Kernel System (GKS) Functional Descript ion Secretariat Computer and Business Equipment Manufacturers Association Approved June 24, 1985 American National Standards Institute, I nc Abstract The graphical kernel system (GKS) is a set of basic functi
3、ons for computer graphics program- ming useable by many graphics producing applications. This standard (1) allows graphics appli- cation programs to be easily transported between installations, (2) aids graphics applications programmers in understanding and using graphics methods, and (3) guides dev
4、ice manufacturers on useful graphics capabilities. This standard defines an application level programming interface to a graphics system. Hence, it contains functions for (1) outputting graphical primitives, (2) controlling the appearance of graphical primitives with attributes, (3) controlling grap
5、hical workstations, (4) controlling trans- formations and coordinate systems, (5) generating and controlling groups of primitives called segments, (6) obtaining graphical input, (7) manipulating groups of device-independent instruc- tions called metafiles, (8) inquiring the capabilities and states o
6、f the graphics system, and (9) handling errors. Twelve upwardly compatible levels of conformance are defined, addressing the most common classes of equipment and applications. Approval of an American National Standard requires review by ANSI that the requirements for due process, consensus, and othe
7、r criteria for approval have been met by the standards developer. Consensus is established when, in the judgment of the ANSI Board of Standards Review, substantial agreement has been reached by directly and materially affected interests. Substantial agreement means much more than a simple majority,
8、but not necessarily unanimity. Consensus requires that all views and objections be considered, and that a concerted effort be made toward their resolution. The use of American National Standards is completely voluntary; their existence does not in any respect preclude anyone, whether he has approved
9、 the standards or not, from manufacturing, marketing, purchasing, or using products, processes, or procedures not conforming to the standards. The American National Standards Institute does not develop standards and will in no circumstances give an interpretation of any American National Standard. M
10、oreover, no person shall have the right or authority to issue an interpretation of an American National Standard in the name of the American National Standards Institute. Requests for interpretations should be addressed to the secretariat or sponsor whose name appears on the title page of this stand
11、ard. CAUTION NOTICE: This American National Standard may be revised or withdrawn at any time. The procedures of the American National Standards Institute require that action be taken periodically to reaffirm, revise, or withdraw this standard. Purchasers of American National Standards may receive cu
12、rrent information on all standards by calling or writing the American National Standards Institute. American National Published by American National Standards Institute 11 West 42nd Street, New York, New York 10036 Copyright O1 985 by Information Technology Industry Council (ITI) All rights reserved
13、. No part of this publication may be reproduced in any form, in an electronic retrieval system or otherwise, without prior written permission of ITI, 1250 Eye Street NW, Washington, DC 20005. Printed in the United States of America (This Foreword is not part of American National Standard X3.124-1985
14、.) Foreword This American National Standard provides a set of basic functions for computer graphics programming These functions taken as a whole are called the graphical kernel system (GKS) The design of this standard is based on the work of many groups. Much of the early design methodology was deve
15、loped at the Wcrkshop on Graphics Standards Meth- odology held in May 1976 in Seillac, France, under IFIP WG5.2 sponsorship. GKS itself was originally developed by Deutsches Institut fur Normung (DIN), the West German standardization institute, in 1978 and was subsequently refined extensively betwee
16、n 1980 and 1982 by Working Group 2 of the Subcommittee on Programming Languages of the Technical Committee on Information Processing of the International Organization for Standardization (IS0 TC 97/SC5/WG2). The resulting International Standard (Informa- tion Processing - Computer Graphics - Graphic
17、al Kernel System (GKS) Functional Description, IS0 7942-1985) was the basis for this American National Standard. The de- velopment of the GKS was heavily influenced by the work of the Graphic Standards Planning Committee of the Special Interest Group on Computer Graphics of the Associa- tion for Com
18、puting Machinery (ACM SIGGRAPH GSPC). This work, known as the Core System Proposal, was published and widely distributed in 1977 and again (in a revised version) in 1979. This American National Standard on GKS is identical to IS0 7942-1985 (GKS) in almost all areas. All functional capabilities of IS
19、0 GKS are found in the ANSI GKS . The ANSI GKS does, however, differ in the following ways. (1) A new minimal output level (denoted m) is defined. (2) A new section defining a conforming program and a conforming implementation replaces a more restrictive conformance statement found in the body of th
20、e IS0 GKS standard document (3) Several of the Annexes in the IS0 GKS document have been modified. Also, the word ?Annex? has been changed to ?Appendix.? (4) The default for ASFs is INDIVIDUAL. (5) The data records for INPUT have been defined. Appendix G contains a detailed list of all the differenc
21、es betwen ANSI X3.124-1985 and IS0 7942-1 985. This standard is supplemented by a derivative standard, American National Standard for Information Systems - Computer Graphics - Graphical Kernel System (GKS) FORTRAN Binding, ANSI X3.124.1-1985 ANSI X3.124-1985 corresponds to IS0 7942-1985 in that it r
22、epresents the functional aspects of GKS. ANSI X3 124.1-1985 contains specifica- tions not present in this standard, namely, the syntax for using GKS functions and data types from American National Standard Programming Language FORTRAN, ANSI X3.9- 1978, colloquially known as FORTRAN ?77 Three additio
23、nal language bindings of GKS are under development by Technical Committee X3H3. Pascal, Ada, and C. These stan- dards, when approved by X3 and ANSI, will be published as ANSI X3.124.2, X3.124 3, and X3.124.4, respectively. Internationally, these language bindings of GKS will be pub- lished as parts
24、of a multipart IS0 standard, currently known as ISO/DP 8651-1984. This standard was developed by Technical Committee X3H3 of Accredited Standards Committee X3 under two projects authorized by X3; namely, project 268D and project 362D. More specifically, GKS, as a whole, meets the goals of project 26
25、8D, while the minimal output level m found in this American National Standard, but not present in IS0 7942-1985, meets the goals of project 362D. This standard was approved as an American National Standard by the American National Standards Institute on June 24, 1985. Suggestions for improvement of
26、this standard will be welcome. They should be sent to the Computer and Business Equipment Manufacturers Association, 31 1 First Street, NW, Suite 500, Washington, DC 20001. This standard was processed and approved for submittal to ANSI by Accredited Standards Committee on Information Processing Syst
27、ems, X3. Committee approval of the standard does not necessarily imply that all committee members voted for its approval. At the time it approved this standard, the X3 Committee had the following members. Edward Lohse, Chair Catherine A Kachurik, Administrative Secretary Organ iza tion Represented N
28、ame of Representative American Library Association. Paul Peters American Nuclear Society Geraldine C. Main D. R Vondy (Alt) . Patrick E. Lannan AMP Incorporated . Edward Kelly (Alt) Association of American Railroads . R. A. Petrash Association for Computing Machinery Kenneth Mage1 Jon A. Meads (Alt)
29、 Computer Professionals Thomas M. Kurihara Ardyn E. Dubnow (Alt) AT b) to aid the understanding and use of graphics methods by application programmers; c) to serve manufacturers of graphics equipment as a guideline in providing useful combins tions of graphics capabilities in a device. In order to r
30、each these main objectives, the GKS design was based on the following require- ments: d) GKS should include all the capabilities that are essential for a broad spectrum of graph- ics, from simple passive output to highly interactive applications. e) The whole range of graphics devices, including vec
31、tor and raster devices, microfilm recorders, storage tube displays, refresh displays and colour displays should be controllable by GKS in a uniform way. f) GIG should provide all the capabilities required by a majority of applications without becoming unduly large. These requirements were used to fo
32、rmulate a number of principles that were used to judge specific design alternatives. Thus it was possible to contribute to the overall design goais while focussing on certain aspects. Five design aspects were identified, each having a group of princi- ples g) Design goals: The following principles s
33、hould not be violated by any technical design: 1) consistency: the mandatory requirements of GKS should not be mutually contradic- tory; 2) compatibility: other standards or commonly accepted rules of practice should not be violated; 3) orthogonality: the functions or modules of GKS should be indepe
34、ndent of each other, or the dependency should be structured and well defined. i) completeness: all functions that a majority of applications want to use on a given levei of functionality should be included; h) Functional capabilities: The following principles were used to define the extent of GKS: P
35、age 1 2) minimality: functions that are unnecessary for applications of a given level of func- tionality should not be provided; 3) compactness: an application should be able to achieve a desired result by a set of functions and parameters that is as small as possible; 4) richness: a rich set of fun
36、ctions offers an extensive range of facilities that stretches beyoad the basic functions and includes higher order capabilities. It is obvious that there is a trade off between the principles in this group. Therefore, the func- tions of GKS are organized in twelve levels. An implementation of GKS pr
37、ovides at least the functions of one of these levels. While the lowest level contains only a minimal set of func- tions, higher levels are allowed to extend beyond the basic needs towards greater richness. i) User interface design: The following principles were used to define the user interface de s
38、ign : 1) user friendliness: GKS should allow the design of a desirable user interface; 2) clarity: the concepts and functiond capabilities of GKS should be easily understasd- able, especially by the application programmer; 3) error handling: failure of system functions or modules, caused by errors o
39、f the system itself or by the application program, should be treated in such a way that the error reac- tion is clearly understandable and informative to the application programmer and that the impact on the system and the application program is as small as possible. Clarity and sound error handling
40、 are essential parts of user friendliness. Error handling is an integral part of GKS. To aid clarity, the system and its state can be presented to the user in an easily comprehensible manner. Clarity applies not only to the system design but also to the system description. To this end, the GKS speci
41、fication is divided into a general description, a description of the underlying logical data structures representing the state of the system, and a description of the func- tions and their effects on these data structures. j) Graphics devices: The following principles are associated with the range o
42、f graphics dev- ices that can be addressed by GKS: 1) device independence: GKS functions should be designed to allow an application pro- gram, using these functions, to address facilities of quite different graphics output and input devices without modification of the program structure; 2) device ri
43、chness: the full capabilities of a wide range of different graphics output and input devices should be accessible from the functions of GKS. These principles led to a fundamental concept underlying the GKS architecture: the concept of multiple independent graphical workstations connected to and driv
44、en by GKS. The appli- cation program can inquire the capabilities of every workstation. The GKS design includes escape functions that are easily identifiable within an application program and can be used to access special facilities of a particular device. k) Implementation: The last group of princi
45、ples is related to the implementation of GKS: 1) implementability: it should be possible to support the GKS functions in most host languages, on most operating systems and with most graphics devices; 2) language independence: it should be possible to access the standard facilities of GKS from all IS
46、0 standard programming languages; 3) efficiency: GKS should be capable of being implemented without time consuming algorithms; 4) robustness: the operator and application programmer should be protected in the best possible way from hardware or software failure of the system. Page 2 The five groups o
47、f principles are interconnected. For example, design goals and functional capabilities both con tribute to user friendliness. Efficiency is also important when considering response time in an interactive environment. Some principles may be conflicting, such as rich- ness versus minimality, comprehen
48、sive error handling versus efficiency, and compactness versus device richness. Compromises needed to be made to achieve the overall design objec- tive: GKS should have an easily comprehensible structure and a set of functions that enables a vast majority of computer graphics users to design portable
49、, device independent application pro- grams addressing the whole range of computer graphics equipment. 0.1 Conformance An implementation conforms to a specific level of this standard if it provides, at least, ail the functions specified in that level, but not all the functions of the next higher level. Any func- tion specified by the standard that is provided by an implementation must execute according to the semantics specified in this standard. In addition, an implementation may provide functions not specified in any level of this standard as long as these extensions do not cause standard