Skip to content

Commit 1b8f85a

Browse files
committed
Resolved #22. Fixed up some typological issues and style issues.
1 parent 0e22809 commit 1b8f85a

26 files changed

+250
-261
lines changed

source/antialias.tex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
%!TEX root = io2d.tex
22
\rSec0 [\iotwod.antialias] {Enum class \tcode{antialias}}
33

4-
\rSec1 [\iotwod.antialias.summary] {\tcode{antialias} Summary}
4+
\rSec1 [\iotwod.antialias.summary] {\tcode{antialias} summary}
55

66
\pnum
77
The antialias enum class specifies the type of anti-aliasing that the rendering
88
system uses for rendering and composing paths. See
99
Table~\ref{tab:\iotwod.antialias.meanings} for the meaning of each
1010
\tcode{antialias} enumerator.
1111

12-
\rSec1 [\iotwod.antialias.synopsis] {\tcode{antialias} Synopsis}
12+
\rSec1 [\iotwod.antialias.synopsis] {\tcode{antialias} synopsis}
1313

1414
\indexlibrary{\idxcode{antialias}}%
1515
\begin{codeblock}
@@ -23,7 +23,7 @@
2323
}
2424
\end{codeblock}
2525

26-
\rSec1 [\iotwod.antialias.enumerators] {\tcode{antialias} Enumerators}
26+
\rSec1 [\iotwod.antialias.enumerators] {\tcode{antialias} enumerators}
2727

2828
\begin{libreqtab2}
2929
{\tcode{antialias} enumerator meanings}

source/arc.tex

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,8 @@
151151
As-if:
152152
\begin{codeblock}
153153
auto lmtx = m;
154-
lmtx.m20(0.0f); lmtx.m21(0.0f); // Eliminate translation.
154+
lmtx.m20(0.0f);
155+
lmtx.m21(0.0f);
155156
auto centerOffset = point_for_angle(two_pi<float> - _Start_angle, _Radius);
156157
centerOffset.y(-centerOffset.y());
157158
return cpt - centerOffset * lmtx;
@@ -170,7 +171,8 @@
170171
\begin{codeblock}
171172
auto lmtx = m;
172173
auto tfrm = matrix_2d::init_rotate(_Start_angle + _Rotation);
173-
lmtx.m20(0.0f); lmtx.m21(0.0f); // Eliminate translation.
174+
lmtx.m20(0.0f);
175+
lmtx.m21(0.0f);
174176
auto pt = (_Radius * tfrm);
175177
pt.y(-pt.y());
176178
return cpt + pt * lmtx;

source/brush-type.tex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
%!TEX root = io2d.tex
22
\rSec0 [\iotwod.brushtype] {Enum class \tcode{brush_type}}
33

4-
\rSec1 [\iotwod.brushtype.summary] {\tcode{brush_type} Summary}
4+
\rSec1 [\iotwod.brushtype.summary] {\tcode{brush_type} summary}
55

66
\pnum
77
The \tcode{brush_type} enum class denotes the type of a \tcode{brush} object.
@@ -10,7 +10,7 @@
1010
See Table~\ref{tab:\iotwod.brushtype.meanings} for the meaning of each
1111
\tcode{brush_type} enumerator.
1212

13-
\rSec1 [\iotwod.brushtype.synopsis] {\tcode{brush_type} Synopsis}
13+
\rSec1 [\iotwod.brushtype.synopsis] {\tcode{brush_type} synopsis}
1414

1515
\begin{codeblock}
1616
namespace std::experimental::io2d::v1 {
@@ -23,7 +23,7 @@
2323
}
2424
\end{codeblock}
2525

26-
\rSec1 [\iotwod.brushtype.enumerators] {\tcode{brush_type} Enumerators}
26+
\rSec1 [\iotwod.brushtype.enumerators] {\tcode{brush_type} enumerators}
2727
\begin{libreqtab2}
2828
{\tcode{brush_type} enumerator meanings}
2929
{tab:\iotwod.brushtype.meanings}

source/brush.tex

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,30 @@
11
%!TEX root = io2d.tex
22
\rSec0 [\iotwod.brush] {Class \tcode{brush}}
33

4-
\rSec1 [\iotwod.brush.intro] {\tcode{brush} Description}
4+
\rSec1 [\iotwod.brush.intro] {\tcode{brush} summary}
55

66
\pnum
77
\indexlibrary{\idxcode{brush}}%
8-
The class \tcode{brush} describes an opaque wrapper for a graphics data graphics resource.
8+
The class \tcode{brush} describes an opaque wrapper for graphics data.
99

1010
\pnum
1111
A \tcode{brush} object is usable with any \tcode{surface} or \tcode{surface}-derived object.
1212

1313
\pnum
14-
A \tcode{brush} object's graphics data is immutable. It is observable only by the effect that it produces when the brush is used as a Source Brush or as a Mask Brush (\ref{\iotwod.surface.rendering.brushes}).
14+
A \tcode{brush} object's graphics data is immutable. It is observable only by the effect that it produces when the brush is used as a \term{
15+
source brush} or as a \term{mask brush} (\ref{\iotwod.surface.rendering.brushes}).
1516

1617
\pnum
1718
A \tcode{brush} object has a brush type of \tcode{brush_type}, which indicates which type of brush it is (Table~\ref{tab:\iotwod.brushtype.meanings}).
1819

1920
\pnum
20-
As a result of technological limitations and considerations, a \tcode{brush} object's graphics data can have less precision than the data from which it was created.
21-
22-
\pnum
23-
\begin{example}
24-
Several graphics and rendering technologies that are currently widely used typically store individual color and alpha channel data as 8-bit unsigned normalized integer values while the \tcode{float} type that is used by the \tcode{rgba_color} class for individual color and alpha is often a 64-bit value. As such, it is possible for a loss of precision when transforming the 64-bit channel data of an \tcode{rgba_color} object to the 8-bit channel data that is commonly used internally in such graphics and rendering technologies.
25-
\end{example}
21+
As a result of technological limitations and considerations, a \tcode{brush} object's graphics data may have less precision than the data from which it was created.
2622

23+
%\pnum
24+
%\begin{example}
25+
%Several graphics and rendering technologies that are currently widely used typically store individual color and alpha channel data as 8-bit unsigned normalized integer values while the \tcode{float} type that is used by the \tcode{rgba_color} class for individual color and alpha is often a 64-bit value. As such, it is possible for a loss of precision when transforming the 64-bit channel data of an \tcode{rgba_color} object to the 8-bit channel data that is commonly used internally in such graphics and rendering technologies.
26+
%\end{example}
27+
%
2728
\rSec1 [\iotwod.brush.synopsis] {\tcode{brush} synopsis}
2829

2930
\begin{codeblock}
@@ -64,22 +65,22 @@
6465
\rSec2 [\iotwod.brush.sampling.color] {Sampling from a solid color brush}
6566

6667
\pnum
67-
When \tcode{b} is a solid color brush, then when sampling from \tcode{b}, the visual data returned shall always be the visual data equivalent \tcode{rgba_color} used to construct \tcode{b}, regardless of the point which is to be sampled and regardless of the return values of Wrap Mode, Filter, and Matrix.
68+
When \tcode{b} is a solid color brush, then when sampling from \tcode{b}, the visual data returned is always the visual data used to construct \tcode{b}, regardless of the point which is to be sampled and regardless of the return values of wrap mode, filter, and brush matrix or mask matrix.
6869

6970
\rSec2 [\iotwod.brush.sampling.linear] {Sampling from a linear gradient brush}
7071

7172
\pnum
72-
When \tcode{b} is a linear gradient brush, when sampling point \tcode{pt}, where \tcode{pt} is the return value of calling the \tcode{transform_point} member function of Matrix using the requested point, from \tcode{b}, the visual data returned shall be as specified by \ref{\iotwod.gradients.linear} and \ref{\iotwod.gradients.sampling}.
73+
When \tcode{b} is a linear gradient brush, when sampling point \tcode{pt}, where \tcode{pt} is the return value of calling the \tcode{transform_point} member function of brush matrix or mask matrix using the requested point, from \tcode{b}, the visual data returned are as specified by \ref{\iotwod.gradients.linear} and \ref{\iotwod.gradients.sampling}.
7374

7475
\rSec2 [\iotwod.brush.sampling.radial] {Sampling from a radial gradient brush}
7576

7677
\pnum
77-
When \tcode{b} is a radial gradient brush, when sampling point \tcode{pt}, where \tcode{pt} is the return value of calling the \tcode{transform_point} member function of Matrix using the requested point, from \tcode{b}, the visual data returned shall be as specified by \ref{\iotwod.gradients.radial} and \ref{\iotwod.gradients.sampling}.
78+
When \tcode{b} is a radial gradient brush, when sampling point \tcode{pt}, where \tcode{pt} is the return value of calling the \tcode{transform_point} member function of brush matrix or mask matrix using the requested point, from \tcode{b}, the visual data are as specified by \ref{\iotwod.gradients.radial} and \ref{\iotwod.gradients.sampling}.
7879

7980
\rSec2 [\iotwod.brush.sampling.surface] {Sampling from a surface brush}
8081

8182
\pnum
82-
When \tcode{b} is a surface brush, when sampling point \tcode{pt}, where \tcode{pt} is the return value of calling the \tcode{transform_point} member function of Matrix using the requested point, from \tcode{b}, the visual data returned shall be from the point \tcode{pt} in the graphics data of the brush, taking into account the values of Wrap Mode and Filter.
83+
When \tcode{b} is a surface brush, when sampling point \tcode{pt}, where \tcode{pt} is the return value of calling the \tcode{transform_point} member function of brush matrix or mask matrix using the requested point, from \tcode{b}, the visual data returned are from the point \tcode{pt} in the graphics data of the brush, taking into account the values of wrap mode and filter.
8384

8485
\rSec1 [\iotwod.brush.cons] {\tcode{brush} constructors and assignment operators}
8586

@@ -96,7 +97,7 @@
9697
The brush's brush type shall be set to the value \tcode{brush_type::solid_color}.
9798

9899
\pnum
99-
The graphics data of the brush shall be created from the value of \tcode{c}. The visual data format of the graphics data shall be as-if it is that specified by \tcode{format::argb}.
100+
The graphics data of the brush are created from the value of \tcode{c}. The visual data format of the graphics data are as-if it is that specified by \tcode{format::argb32}.
100101

101102
\pnum
102103
\remarks
@@ -112,7 +113,7 @@
112113
\begin{itemdescr}
113114
\pnum
114115
\effects
115-
Constructs a linear gradient \tcode{brush} object with a begin point of \tcode{begin}, an end point of \tcode{end}, and a color stop collection containing the values in the range \range{first}{last}.
116+
Constructs a linear gradient \tcode{brush} object with a begin point of \tcode{begin}, an end point of \tcode{end}, and a sequential series of \tcode{color stop} values beginning at {first} and ending at {last - 1}.
116117

117118
\pnum
118119
The brush's brush type is \tcode{brush_type::linear}.
@@ -130,7 +131,7 @@
130131
\begin{itemdescr}
131132
\pnum
132133
\effects
133-
Constructs a linear gradient \tcode{brush} object with a begin point of \tcode{begin}, an end point of \tcode{end}, and a color stop collection containing the \tcode{color_stop} objects in \tcode{il}.
134+
Constructs a linear gradient \tcode{brush} object with a begin point of \tcode{begin}, an end point of \tcode{end}, and the sequential series of \tcode{color stop} values in \tcode{il}.
134135

135136
\pnum
136137
The brush's brush type is \tcode{brush_type::linear}.
@@ -149,7 +150,7 @@
149150
\begin{itemdescr}
150151
\pnum
151152
\effects
152-
Constructs a radial gradient \tcode{brush} object with a start circle of \tcode{start}, an end circle of \tcode{end}, and a color stop collection containing the values in the range \range{first}{last}.
153+
Constructs a radial gradient \tcode{brush} object with a start circle of \tcode{start}, an end circle of \tcode{end}, and a sequential series of \tcode{color stop} values beginning at {first} and ending at {last - 1}.
153154

154155
\pnum
155156
The brush's brush type is \tcode{brush_type::radial}.
@@ -167,7 +168,7 @@
167168
\begin{itemdescr}
168169
\pnum
169170
\effects
170-
Constructs a radial gradient \tcode{brush} object with a start circle of \tcode{start}, an end circle of \tcode{end}, and a color stop collection containing the \tcode{color_stop} objects in \tcode{il}.
171+
Constructs a radial gradient \tcode{brush} object with a start circle of \tcode{start}, an end circle of \tcode{end}, and the sequential series of \tcode{color stop} values in \tcode{il}.
171172

172173
\pnum
173174
The brush's brush type is \tcode{brush_type::radial}.
@@ -191,11 +192,11 @@
191192
The brush's brush type is \tcode{brush_type::surface}.
192193

193194
\pnum
194-
The graphics data of the brush is as-if it is the \underlyingimagesurface of \tcode{img}.
195+
The graphics data of the brush is as-if it is the raster graphics data of \tcode{img}.
195196

196197
\pnum
197198
\remarks
198-
Sampling from this brush shall produce the results specified in \ref{\iotwod.brush.sampling.surface}.
199+
Sampling from this brush produces the results specified in \ref{\iotwod.brush.sampling.surface}.
199200
\end{itemdescr}
200201

201202
\rSec1 [\iotwod.brush.observers]{\tcode{brush} observers}

source/brushes.tex

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,23 +25,22 @@
2525
\end{note}
2626

2727
\pnum
28-
A brush is used either as a Source Brush or a Mask Brush (\ref{\iotwod.surface.rendering.brushes}).
28+
A brush is used either as a \term{source brush} or a \term{mask brush} (\ref{\iotwod.surface.rendering.brushes}).
2929

3030
\pnum
31-
When a brush is used in a rendering and composing operation, if it is used as a Source Brush, it has a \tcode{brush_props} object that describes how the brush is interpreted for purposes of sampling. If it is used as a Mask Brush, it has a \tcode{mask_props} object that describes how the brush is interpreted for purposes of sampling.
31+
When a brush is used in a rendering and composing operation, if it is used as a source brush, it has a \tcode{brush_props} object that describes how the brush is interpreted for purposes of sampling. If it is used as a mask brush, it has a \tcode{mask_props} object that describes how the brush is interpreted for purposes of sampling.
3232

3333
\pnum
34-
The \tcode{brush_props} and \tcode{mask_props} classes both have a Wrap Mode, Filter and Matrix (\ref{\iotwod.brushprops.summary} and \ref{\iotwod.maskprops.summary}). Where necessary, these shall be referenced using those terms without regard to whether the brush is being used as a Source Brush or a Mask Brush.
35-
34+
The \tcode{brush_props} (\ref{\iotwod.brushprops.summary}) and \tcode{mask_props} (\ref{\iotwod.maskprops.summary}) classes each have a \term{wrap mode} and a \term{filter}. The \tcode{brush_props} class also has a \term{brush matrix} and a \term{fill rule}. The \tcode{mask_props} class also has a \tcode{mask matrix}. Where possible, the terms that are common between the two classes are referenced without regard to whether the brush is being used as a source brush or a mask brush.
3635

3736
%\pnum
3837
%A brush has its own coordinate space.
3938
%
4039
%\pnum
41-
%If it is being used as a Source Brush, it is the Brush Coordinate Space (\ref{\iotwod.surface.coordinatespaces}).
40+
%If it is being used as a source brush, it is the Brush Coordinate Space (\ref{\iotwod.surface.coordinatespaces}).
4241
%
4342
%\pnum
44-
%If it is being used as a Mask Brush, it is the Mask Coordinate Space (\ref{\iotwod.surface.coordinatespaces}).
43+
%If it is being used as a mask brush, it is the Mask Coordinate Space (\ref{\iotwod.surface.coordinatespaces}).
4544
%
4645
%\pnum
4746
%It possesses a \tcode{filter} value and a \tcode{wrap_mode} value, which combine to determine the visual data value returned when a composing operation samples a brush.

source/circle.tex

Lines changed: 10 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
%!TEX root = io2d.tex
22
\rSec0 [\iotwod.circle] {Class \tcode{circle}}
33

4-
\rSec1 [\iotwod.circle.intro] {\tcode{circle} Description}
4+
\rSec1 [\iotwod.circle.intro] {\tcode{circle} description}
55

66
\pnum
77
\indexlibrary{\idxcode{circle}}%
88
The class \tcode{circle} describes a circle.
99

1010
\pnum
11-
It has a Center of type \tcode{vector_2d} and a Radius of type \tcode{float}.
11+
It has a \term{center} of type \tcode{vector_2d} and a \term{radius} of type \tcode{float}.
1212

1313
\rSec1 [\iotwod.circle.synopsis] {\tcode{circle} synopsis}
1414

1515
\begin{codeblock}
1616
namespace std::experimental::io2d::v1 {
1717
class circle {
1818
public:
19-
// \ref{\iotwod.circle.cons}, construct/copy/move/destroy:
19+
// \ref{\iotwod.circle.cons}, constructors:
2020
constexpr circle() noexcept;
2121
contexpr circle(const vector_2d& ctr, float rad) noexcept;
2222

@@ -31,7 +31,7 @@
3131
}
3232
\end{codeblock}
3333

34-
\rSec1 [\iotwod.circle.cons] {\tcode{circle} constructors and assignment operators}
34+
\rSec1 [\iotwod.circle.cons] {\tcode{circle} constructors}
3535

3636
\indexlibrary{\idxcode{circle}!constructor}%
3737
\begin{itemdecl}
@@ -40,13 +40,7 @@
4040
\begin{itemdescr}
4141
\pnum
4242
\effects
43-
Constructs an object of type \tcode{circle}.
44-
45-
\pnum
46-
The value of Center is \tcode{vector_2d\{0,0, 0.0f\}}.
47-
48-
\pnum
49-
The value of Radius is \tcode{0.0f}.
43+
Equivalent to: \tcode{circle(\{ 0.0f, 0.0f \}, 0.0f)}.
5044
\end{itemdescr}
5145

5246
\indexlibrary{\idxcode{circle}!constructor}%
@@ -62,10 +56,7 @@
6256
Constructs an object of type \tcode{circle}.
6357

6458
\pnum
65-
The value of Center is \tcode{ctr}.
66-
67-
\pnum
68-
The value of Radius is \tcode{r}.
59+
The center is \tcode{ctr}. The fadius is \tcode{r}.
6960
\end{itemdescr}
7061

7162
\rSec1 [\iotwod.circle.modifiers]{\tcode{circle} modifiers}
@@ -78,7 +69,7 @@
7869
\begin{itemdescr}
7970
\pnum
8071
\effects
81-
The value of Center is \tcode{ctr}.
72+
The center is \tcode{ctr}.
8273
\end{itemdescr}
8374

8475
\indexlibrary{\idxcode{circle}!\idxcode{radius}}%
@@ -91,7 +82,7 @@
9182

9283
\pnum
9384
\effects
94-
The value of Radius is \tcode{r}.
85+
The radius is \tcode{r}.
9586
\end{itemdescr}
9687

9788
\rSec1 [\iotwod.circle.observers]{\tcode{circle} observers}
@@ -103,7 +94,7 @@
10394
\begin{itemdescr}
10495
\pnum
10596
\returns
106-
The value of Center.
97+
The center.
10798
\end{itemdescr}
10899

109100
\indexlibrary{\idxcode{circle}!\idxcode{radius}}%
@@ -113,5 +104,5 @@
113104
\begin{itemdescr}
114105
\pnum
115106
\returns
116-
The value of Radius.
107+
The radius.
117108
\end{itemdescr}

source/color-stop.tex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
\pnum
1111
It has an offset of type \tcode{float} and a color of type \tcode{rgba_color}.
1212

13-
\rSec2 [\iotwod.colorstops.colorstop.synopsis] {\tcode{color_stop} Synopsis}
13+
\rSec2 [\iotwod.colorstops.colorstop.synopsis] {\tcode{color_stop} synopsis}
1414

1515
\begin{codeblock}
1616
namespace std::experimental::io2d::v1 {

source/compositing-op.tex

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -115,17 +115,17 @@
115115
own value.
116116

117117
\pnum
118-
The basic enumerators specify a value for Bound. This value may be 'Yes',
118+
The basic enumerators specify a value for \term{bound}. This value may be 'Yes',
119119
'No', or 'N/A'.
120120

121121
\pnum
122-
If the Bound value is 'Yes', then the source is treated as though it is
122+
If the bound value is 'Yes', then the source is treated as though it is
123123
also a mask. As such, only areas of the surface where the source would affect
124124
the surface are altered. The remaining areas of the surface have the same color
125125
value as before the compositing operation.
126126

127127
\pnum
128-
If the Bound value is 'No', then every area of the surface that is not
128+
If the bound value is 'No', then every area of the surface that is not
129129
affected by the source will become transparent black. In effect, it is as
130130
though the source was treated as being the same size as the destination surface
131131
with every part of the source that does not already have a color value assigned
@@ -134,22 +134,22 @@
134134
black such that evaluation can be bypassed due to the predetermined outcome.
135135

136136
\pnum
137-
If the Bound value is 'N/A', the operation would have the same effect
137+
If the bound value is 'N/A', the operation would have the same effect
138138
regardless of whether it was treated as 'Yes' or 'No' such that those
139-
Bound values are not applicable to the operation. A 'N/A' formula when
139+
bound values are not applicable to the operation. A 'N/A' formula when
140140
applied to an area where the source does not provide a value will evaluate to
141141
the original value of the destination even if the source is treated as having a
142142
value there of transparent black. As such the result is the same as-if the
143143
source were treated as being a mask, i.e. 'Yes' and 'No' treatment each
144144
produce the same result in areas where the source does not have a value.
145145

146146
\pnum
147-
If a clip is set and the Bound value is 'Yes' or 'N/A', then only those
147+
If a clip is set and the bound value is 'Yes' or 'N/A', then only those
148148
areas of the surface that the are within the clip will be affected by the
149149
compositing operation.
150150

151151
\pnum
152-
If a clip is set and the Bound value is 'No', then only those areas of
152+
If a clip is set and the bound value is 'No', then only those areas of
153153
the surface that the are within the clip will be affected by the compositing
154154
operation. Even if no part of the source is within the clip, the operation will
155155
still set every area within the clip to transparent black. Areas outside the
@@ -325,7 +325,7 @@
325325
\end{note}
326326

327327
\pnum
328-
All of the blend enumerators and hsl enumerators have a Bound value of 'N/A'.
328+
All of the blend enumerators and hsl enumerators have a bound value of 'N/A'.
329329

330330
\begin{libreqtab2}
331331
{\tcode{compositing_op} blend enumerator meanings}

0 commit comments

Comments
 (0)