@@ -178,7 +178,7 @@ Next we need to set up OpenGL rendering for this window.
178178
179179::: {.printedClojure}
180180``` clojure
181- #object[org.lwjgl.opengl.GLCapabilities 0x30f1b3c2 " org.lwjgl.opengl.GLCapabilities@30f1b3c2 " ]
181+ #object[org.lwjgl.opengl.GLCapabilities 0x688b081a " org.lwjgl.opengl.GLCapabilities@688b081a " ]
182182
183183```
184184:::
@@ -987,7 +987,8 @@ This shader program requires setup of several uniforms and a texture.
987987``` clojure
988988(do
989989 (GL20/glUseProgram program-moon)
990- (GL20/glUniform2f (GL20/glGetUniformLocation program-moon " iResolution" ) window-width window-height)
990+ (GL20/glUniform2f (GL20/glGetUniformLocation program-moon " iResolution" )
991+ window-width window-height)
991992 (GL20/glUniform1f (GL20/glGetUniformLocation program-moon " fov" ) (to-radians 25.0 ))
992993 (GL20/glUniform1f (GL20/glGetUniformLocation program-moon " alpha" ) (to-radians 30.0 ))
993994 (GL20/glUniform1f (GL20/glGetUniformLocation program-moon " beta" ) (to-radians -20.0 ))
@@ -1716,7 +1717,7 @@ We reuse the vertex shader from the previous section.
17161717
17171718The fragment shader this time is more involved.
17181719
1719- * A horizon matrix with normal, tangent, and bitangent vectors is computed/
1720+ * A horizon matrix with normal, tangent, and bitangent vectors is computed.
17201721* The elevation is sampled in four directions from the current 3D point.
17211722* The elevation values are used to create two surface vectors.
17221723* The cross product of the surface vectors is computed and normalized to get the normal vector.
@@ -2021,8 +2022,10 @@ Note that in practise you will
20212022* use higher resolution data and map the data onto texture tiles
20222023* generate textures containing normal maps offline
20232024* create a multiresolution map
2024- * you use tessellation to increase the mesh resolution
2025- * you will use elevation data to deform the mesh
2025+ * use tessellation to increase the mesh resolution
2026+ * use elevation data to deform the mesh
2027+
2028+ Thanks to [ Timothy Pratley] ( https://timothypratley.blogspot.com/p/httpswww.html ) for helping getting this post online.
20262029
20272030
20282031``` {=html}
0 commit comments