diff --git a/LEARN.md b/LEARN.md index 9b3a0ae..0638ab8 100644 --- a/LEARN.md +++ b/LEARN.md @@ -95,6 +95,8 @@ CLOG "The Framework" (Code Tutorials) - [31-tutorial.lisp](tutorial/31-tutorial.lisp) - Database and Authority based websites - clog-web-dbi and clog-auth - [32-tutorial.lisp](tutorial/32-tutorial.lisp) - Database Managed Content websites - clog-web-content - [33-tutorial.lisp](tutorial/33-tutorial.lisp) - with-clog-create - Using a declarative syntax for GUIs +- [34-tutorial.lisp](tutorial/34-tutorial.lisp) - 2D WebGL example +- [35-tutorial.lisp](tutorial/35-tutorial.lisp) - 3D WebGL example CLOG Demos - Learn through Projects diff --git a/README.md b/README.md index 438b55e..2c1a1e7 100644 --- a/README.md +++ b/README.md @@ -271,6 +271,8 @@ CLOG Tutorials - [31-tutorial.lisp](tutorial/31-tutorial.lisp) - Database and Authority based websites - clog-web-dbi and clog-auth - [32-tutorial.lisp](tutorial/32-tutorial.lisp) - Database Managed Content websites - clog-web-content - [33-tutorial.lisp](tutorial/33-tutorial.lisp) - with-clog-create - Using a declarative syntax for GUIs +- [34-tutorial.lisp](tutorial/34-tutorial.lisp) - 2D WebGL example +- [35-tutorial.lisp](tutorial/35-tutorial.lisp) - 3D WebGL example CLOG Demos diff --git a/tutorial/35-tutorial.lisp b/tutorial/35-tutorial.lisp index eacd616..c1af49f 100644 --- a/tutorial/35-tutorial.lisp +++ b/tutorial/35-tutorial.lisp @@ -168,20 +168,18 @@ ;; Indices (bind-buffer index-buffer :ELEMENT_ARRAY_BUFFER) (use-program program) - (uniform-matrix gl 4 projection-matrix nil (list (random 1.0) (random 1.0) (random 1.0) (random 1.0) - (random 1.0) (random 1.0) (random 1.0) (random 1.0) - (random 1.0) (random 1.0) (random 1.0) (random 1.0) - (random 1.0) (random 1.0) (random 1.0) (random 1.0))) - (uniform-matrix gl 4 model-view-matrix nil (list (random 1.0) (random 1.0) (random 1.0) (random 1.0) - (random 1.0) (random 1.0) (random 1.0) (random 1.0) - (random 1.0) (random 1.0) (random 1.0) (random 1.0) - (random 1.0) (random 1.0) (random 1.0) (random 1.0))) + (uniform-matrix gl 4 projection-matrix nil + (list 2.4142136573791504 0 0 0 + 0 2.4142136573791504 0 0 + 0 0 -1.0002000331878662 -1 + 0 0 -0.020002000033855438 0)) + (uniform-matrix gl 4 model-view-matrix nil + (list 0.24186034500598907 0.6221014261245728 -0.7446430921554565 0 + -0.7772392630577087 0.5836206674575806 0.2351299524307251 0 + 0.5808637738227844 0.5218972563743591 0.6246763467788696 0 + 0 0 -6 1)) (draw-elements gl :TRIANGLES 36 :UNSIGNED_SHORT 0))) - (loop - (unless (clog:validp body) - (return)) - (draw-scene) - (sleep .1))))) + (draw-scene)))) (defun start-tutorial () "Start turtorial." diff --git a/tutorial/README.md b/tutorial/README.md index 16eef33..9e04231 100644 --- a/tutorial/README.md +++ b/tutorial/README.md @@ -58,4 +58,6 @@ Tutorial Summary - 30-tutorial.lisp - Instant websites - clog-web-site - 31-tutorial.lisp - Database and Authority based websites - clog-web-dbi and clog-auth - 32-tutorial.lisp - Database Managed Content websites - clog-web-content -- 33-tutorial.lisp - with-clog-create - Using a declarative syntax for GUIs \ No newline at end of file +- 33-tutorial.lisp - with-clog-create - Using a declarative syntax for GUIs +- 34-tutorial.lisp - 2D WebGL example +- 35-tutorial.lisp - 3D WebGL example \ No newline at end of file