1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
|
.\"
.\" $XConsortium: p003,v 5.2 94/04/17 20:54:13 rws Exp $
.\"
.\"
$XMCOPY
.\" Copyright (c) 1990, 1991 by Sun Microsystems, Inc. and the X Consortium.
.\"
.\" All Rights Reserved
.\"
.\" Permission to use, copy, modify, and distribute this software and its
.\" documentation for any purpose and without fee is hereby granted,
.\" provided that the above copyright notice appear in all copies and that
.\" both that copyright notice and this permission notice appear in
.\" supporting documentation, and that the names of Sun Microsystems,
.\" and the X Consortium not be used in advertising or publicity
.\" pertaining to distribution of the software without specific, written
.\" prior permission.
.\"
.\" SUN MICROSYSTEMS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
.\" INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
.\" EVENT SHALL SUN MICROSYSTEMS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
.\" CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
.\" USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
.\" OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
.\" PERFORMANCE OF THIS SOFTWARE.
.TH "ANNOTATION TEXT RELATIVE 3" 3P "29 February 1991"
.SH NAME
ANNOTATION TEXT RELATIVE 3 \- create structure element specifying \s-2\&3D\s+2 annotation text primitive
.IX "Primitives, Text Primitives" "ANNOTATION TEXT RELATIVE 3"
.IX "Text Primitives" "ANNOTATION TEXT RELATIVE 3"
.SH SYNOPSIS
.SS C Syntax
.ft B
.ta 1.25i 3i
.nf
void
panno_text_rel3 ( ref_pt, anno_offset, text )
Ppoint3 *ref_pt; \fIreference point\fP
Pvec3 *anno_offset; \fIannotation offset\fP
char *text; \fIannotation text string\fP
.fi
.ft R
.SS Required PHIGS Operating States
(PHOP, *, STOP, *)
.SH DESCRIPTION
.SS Purpose
The
\s-2ANNOTATION TEXT RELATIVE 3\s+2
subroutine puts a structure element
containing the full specification of a three-dimensional
\s-2ANNOTATION TEXT RELATIVE 3\s+2
primitive into the currently open structure.
.LP
The
\s-2ANNOTATION TEXT RELATIVE 3\s+2
primitive is a character
string. The location of the string in the display is controlled by the
\fIreference point\fP and \fIannotation offset\fP subroutine
parameters.
\s-2ANNOTATION TEXT RELATIVE 3\s+2
primitives differ from
\s-2TEXT 3\s+2
primitives in that the reference point is
specified in Modelling Coordinates (\s-2MC\s+2), and the plane upon which the
characters are generated will always be parallel to the display surface
and in the Normalized Projection Coordinate (\s-2NPC\s+2) Space.
Aspects of the text display,
such as the font, colour, spacing, height, and alignment, are controlled
by the current values of the primitive attributes listed below.
.LP
If the current edit mode is \s-2INSERT\s+2, the structure element
created by the
\s-2ANNOTATION TEXT RELATIVE 3\s+2
subroutine is inserted into the open structure after the element pointed to
by the current \fIelement pointer\fP. If the current edit mode is
\s-2REPLACE\s+2, the new
\s-2ANNOTATION TEXT RELATIVE 3\s+2
element replaces the element in the structure pointed to by the
element pointer.
In either case, the element pointer
is updated to point to the new
\s-2ANNOTATION TEXT RELATIVE 3\s+2
element.
.SS C Input Parameters
.IP \fIref_pt\fP
A pointer to a Ppoint3 structure containing the \fIx\fP, \fIy\fP, and \fIz\fP
\s-2MC\s+2 that locate the annotation text.
The Ppoint3 structure is defined in phigs.h as follows:
.sp .4
.ta .5i +\w'Pfloat 'u +\w'x; 'u
.nf
typedef struct {
.sp .2
Pfloat x; /* x coordinate */
Pfloat y; /* y coordinate */
Pfloat z; /* z coordinate */
.sp .2
} Ppoint3;
.sp
.fi
.IP \fIanno_offset\fP
A pointer to a Pvec3 structure containing the \fIx\fP, \fIy\fP,
and \fIz\fP coordinates of the offset of the text string from the transformed
reference point. The annotation offset specifies an offset in
\s-2NPC\s+2.
The Pvec3 structure is defined in phigs.h as follows:
.sp .4
.ta .5i +\w'Pfloat 'u +\w'delta_x; 'u
.nf
typedef struct {
.sp .2
Pfloat delta_x; /* x magnitude */
Pfloat delta_y; /* y magnitude */
Pfloat delta_z; /* z magnitude */
.sp .2
} Pvec3;
.sp
.fi
.IP \fItext\fP
A pointer to the character string to be written into the display.
.SS Execution
When the structure is traversed, the
\s-2ANNOTATION TEXT RELATIVE 3\s+2
element draws the
specified character string on the plane in the \s-2NPC\s+2
System defined by reference point and the annotation offset.
These parameters define a Text Local Coordinate (\s-2TLC\s+2) System in
the \s-2NPC\s+2 System.
The annotation offset added to the transformed reference point
defines the origin of this \s-2TLC\s+2 System.
The \fIx\fP and \fIy\fP axes of the \s-2TLC\s+2 System are
parallel to and have the same direction as the \fIx\fP and \fIy\fP
axes of the \s-2NPC\s+2 System.
.LP
The precise position of the text is defined in relation to this plane by
the current values of the text primitive attributes
\s-2ANNOTATION TEXT CHARACTER UP VECTOR\s+2, \s-2ANNOTATION TEXT CHARACTER\s+2,
\s-2BASE VECTOR\s+2, \s-2ANNOTATION TEXT PATH\s+2, and \s-2ANNOTATION TEXT ALIGNMENT\s+2.
The reference point is subject to the current transformations in the
transformation pipeline from the \s-2MC\s+2 System to the workstation display.
The text itself is only subject to the transformations in the transformation
pipeline from the \s-2NPC\s+2 System to the workstation display.
.LP
Other aspects of the appearance of the text are controlled by the
attributes \s-2TEXT FONT\s+2, \s-2TEXT PRECISION\s+2, \s-2ANNOTATION STYLE\s+2,
\s-2ANNOTATION TEXT CHARACTER HEIGHT\s+2, \s-2ANNOTATION TEXT CHARACTER WIDTH\s+2,
\s-2CHARACTER EXPANSION FACTOR\s+2, \s-2CHARACTER SPACING\s+2, and
\s-2TEXT COLOUR INDEX\s+2.
.LP
\s-2ANNOTATION TEXT CHARACTER WIDTH\s+2 and \s-2ANNOTATION TEXT BASE VECTOR\s+2
are implicit attributes derived from \s-2ANNOTATION TEXT CHARACTER HEIGHT\s+2
and \s-2ANNOTATION TEXT UP VECTOR\s+2, respectively.
.SS Attributes Applied
The attributes listed below are used to display the
\s-2ANNOTATION TEXT RELATIVE 3\s+2 primitive when the structure is traversed.
The Aspect Source
Flags (\s-2ASF\s+2s) tell where to access the output display attributes.
These attributes can come directly from the traversal state list,
or they can be accessed indirectly, using the appropriate index
in the traversal state list and the corresponding bundled
representation in the \s-2PHIGS\s+2 workstation state list.
.RS
.nf
.ta .5i +\w'back interior reflectance equation 'u
.sp
text font text font \s-2ASF\s+2
text precision text precision \s-2ASF\s+2
character expansion factor character expansion factor \s-2ASF\s+2
character spacing character spacing \s-2ASF\s+2
text colour text colour index \s-2ASF\s+2
annotation character height
annotation character up vector
annotation text path
annotation text alignment
annotation style
text index
depth cue index
name set
.fi
.RE
.sp .2
.SH ERRORS
.IP 005
Ignoring function, function requires state (\s-2PHOP\s+2, *, \s-2STOP\s+2, *)
.SH SEE ALSO
.nf
.IP
.ta 0.5i
.SM "TEXT 3 (3P)"
.fi
|