Skip to content

Commit 7f4e552

Browse files
Ian ThomasIan Thomas
Ian Thomas
authored and
Ian Thomas
committed
Corrected minor typos
1 parent 3e67ade commit 7f4e552

6 files changed

+39
-39
lines changed

02-introduction.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,7 @@ Buffers
219219
+++++++
220220

221221
The next question is thus where do those vertices comes from ? The idea of
222-
modern GL is that vertices are stored on the GPU and needs to be uploaded to
222+
modern GL is that vertices are stored on the GPU and need to be uploaded to
223223
the GPU before rendering. The way to do that is to build buffers onto the CPU
224224
and to send these buffers onto the GPU. If your data does not change, no need
225225
to upload them again. That is the big difference with the previous fixed

03-quickstart.rst

+8-8
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Preliminaries
1717
-------------------------------------------------------------------------------
1818

1919
The main difficulty for newcomers in programming modern OpenGL is that it
20-
requires to underdtand a lot of different concepts at once and then, to perform
20+
requires to understand a lot of different concepts at once and then, to perform
2121
a lot of operations before rendering anything on screen. This complexity
2222
implies that there are many places where your code can be wrong, both at the
2323
conceptual and code level. To illustrate this difficulty, we'll program our
@@ -395,7 +395,7 @@ We now need to bind the buffer to the program, that is, for each attribute
395395
present in the vertex shader program, we need to tell OpenGL where to find the
396396
corresponding data (i.e. GPU buffer) and this requires some computations. More
397397
precisely, we need to tell the GPU how to read the buffer in order to bind each
398-
value to the relevant attribute. To do this, GPU needs to kow what is the
398+
value to the relevant attribute. To do this, GPU needs to know what is the
399399
stride between 2 consecutive element and what is the offset to read one
400400
attribute:
401401

@@ -531,7 +531,7 @@ Varying color
531531
A colored quad using a per-vertex color.
532532

533533
Until now, we have been using a constant color for the four vertices of our
534-
quad and the result is (unsuprinsingly) a boring uniform red or blue quad. We
534+
quad and the result is (unsurprisingly) a boring uniform red or blue quad. We
535535
can make a bit more interesting though by assigning different colors for each
536536
vertex and see how OpenGL will interpolate colors. Our new vertex shader would
537537
need to be rewritten as:
@@ -722,8 +722,8 @@ program.
722722
Uniform color
723723
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
724724

725-
Adding a `uniform` specified color like is only a matter of modifying the
726-
fragment shader as in the previous section an directly assigning the color to
725+
Adding a `uniform` specified color is only a matter of modifying the
726+
fragment shader as in the previous section and directly assigning the color to
727727
the quad program (see `<code/chapter-03/glumpy-quad-uniform-color.py>`_):
728728

729729
.. code:: python
@@ -735,8 +735,8 @@ the quad program (see `<code/chapter-03/glumpy-quad-uniform-color.py>`_):
735735
Varying color
736736
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
737737

738-
Adding a per-vertex color like is also and only a matter of modifying the
739-
fragment shader as in the previous section an directly assigning the color to
738+
Adding a per-vertex color is also only a matter of modifying the
739+
fragment shader as in the previous section and directly assigning the color to
740740
the quad program (see `<code/chapter-03/glumpy-quad-varying-color.py>`_):
741741

742742
.. code:: python
@@ -849,7 +849,7 @@ angle theta around the origin (0,0) for a point (x,y):
849849
float y2 = sin(theta)*x + cos(theta)*y;
850850
851851
852-
Solution: `<code/chapter-03/quad-rotate.py>`_
852+
Solution: `<code/chapter-03/quad-rotation.py>`_
853853

854854

855855
.. _GLUT: http://freeglut.sourceforge.net

04-maths.rst

+5-5
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Basic Mathematics
1010
1111
1212
There is no way around mathematics. If you want to understand computer
13-
geometry, you need to masterize a few mathematical concepts. But not that many
13+
geometry, you need to master a few mathematical concepts. But not that many
1414
actually. I won't introduce everything since there is already a lot of
1515
tutorials online explaining the core concepts of `linear algrebra
1616
<http://math.hws.edu/graphicsbook/c3/s5.html>`_, `Euclidean geometry
@@ -92,7 +92,7 @@ through points to be projected). For these two projections, results are similar
9292
but different. In the first case, distances have been exactly conserved while
9393
in the second case, the distance between projected points has increased, but
9494
projected points are still equidistant. The third projection is where
95-
homogenous coordinates make sense. For this (abritraty) projection, we decided
95+
homogenous coordinates make sense. For this (arbitrary) projection, we decided
9696
that the further the point is from the origin, and the further away from the
9797
origin its projection will be. To do that, we measure the distance of the point
9898
to the origin and we add this distance to its `w` value before projecting it
@@ -110,7 +110,7 @@ P(-0.5), P(0.0), P(+0.5), P(+1.0)]`, we have have `║P(-1.0)-P(-0.5)]║ >
110110
actual representation: a + bi⃗ + cj⃗ + dk⃗, where a, b, c, and d are real
111111
numbers, and i⃗, j⃗, k⃗ are the fundamental quaternion units.
112112

113-
Back to our regular 3D-Euclidean space, the principle remains the same and we have the following relationgship between Cartesian and homogeneous coordinates:
113+
Back to our regular 3D-Euclidean space, the principle remains the same and we have the following relationship between Cartesian and homogeneous coordinates:
114114

115115
.. code::
116116
:class: math
@@ -122,7 +122,7 @@ Back to our regular 3D-Euclidean space, the principle remains the same and we ha
122122
Cartesian Homogeneous
123123
124124
125-
If you didn't understood everything, you can stick to the description provided
125+
If you didn't understand everything, you can stick to the description provided
126126
by Sam Hocevar:
127127

128128
* If w = 1, then the vector (x,y,z,1) is a position in space
@@ -144,7 +144,7 @@ Transformations
144144
(bottom). Remember that last transformation is on the left.
145145

146146

147-
We'll use now homogeneous coordinates and express all our transformations using
147+
We'll now use homogeneous coordinates and express all our transformations using
148148
only 4×4 matrices. This will allow us to chain several transformations by
149149
multiplying transformation matrices. However, before diving into the actual
150150
definition of these matrices, we need to decide if we consider a four

05-cube.rst

+4-4
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,10 @@ explicitly OpenGL how to draw 6 faces with them:
3232
3333
These vertice describe a cube centered on (0,0,0) that goes from (-1,-1,-1) to
3434
(+1,+1,+1). Unfortunately, we cannot use `gl.GL_TRIANGLE_STRIP` as we did for
35-
the quad. If your remember how this rendering primitive considers vertices as a
35+
the quad. If you remember how this rendering primitive considers vertices as a
3636
succession of triangles, you should also realize there is no way to organize
37-
our vertices into a triangle strip that wpuld describe our cube. This means we
38-
have to tell OpenGL explicitely what are our triangles, i.e. we need to
37+
our vertices into a triangle strip that would describe our cube. This means we
38+
have to tell OpenGL explicitly what are our triangles, i.e. we need to
3939
describe triangles in terms of vertex indices (relatively to the `V` array we
4040
just defined):
4141

@@ -108,7 +108,7 @@ from the `glumpy.glm` module (that also defines ortho, frustum and perspective
108108
matrices as well as rotation, translation and scaling operations). This default
109109
perspective matrix is located at the origin and look in the negative z
110110
direction with the up direction pointing toward the positive y-axis. If we
111-
leave our cube at the origin, the camera would be inside the cube and we woudl
111+
leave our cube at the origin, the camera would be inside the cube and we would
112112
not see much. So let first create a view matrix that is a translation along the
113113
z-axis:
114114

16-glsl-reference.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ functionality are intrinsically declared with the following types:
171171

172172
:proto:`gl_PointSize`
173173

174-
The variable gl_PointSize` is intended for a vertex shader to write the size
174+
The variable `gl_PointSize` is intended for a vertex shader to write the size
175175
of the point to be rasterized. It is measured in pixels.
176176

177177

0 commit comments

Comments
 (0)