From 84e29eb59eee269ca9ccb9fe343fcbb8c575b0d9 Mon Sep 17 00:00:00 2001 From: Joseph Ferano Date: Fri, 18 Aug 2023 15:58:32 +0700 Subject: [PATCH] Update README.org with project specific details --- README.org | 52 +++++++++++++++++++++++++++++----------------------- 1 file changed, 29 insertions(+), 23 deletions(-) diff --git a/README.org b/README.org index fbd99c2..24fbe60 100644 --- a/README.org +++ b/README.org @@ -1,39 +1,45 @@ -### FPS Scene +#+OPTIONS: toc:nil -You can walk around the scene with simple FPS controls. -Open `scene.html` with an http server, you can use the following; +* PQ Torus Knot -```python3 -m http.server 8000``` +** About -Unfortunately, elm-reactor has issues with loading obj files so that's why the -python server is needed. +[[https://ferano.io/3d-fp/][Live Link]] -![alt text](screenshots/elm-fps.png "FPS Scene") +This is an attempt to implement the [[https://en.wikipedia.org/wiki/Torus_knot][PQ Torus Knot]] in the Elm programming +language. +** Showcase -##### Controls +** Keybindings -Mouse - Look Rotation +You can increment/decrement P or Q using the keyboard to get different geometry; -WASD - Player movement +- Increment P: ~p~ +- Increment Q: ~q~ +- Decrement P: ~w~ +- Decrement Q: ~o~ -◀ ▼ ▲ ▶ - Move the Robot +** Building with Elm 0.18.0 +To install the binaries manually, follow this short guide; - [[https://sirfitz.medium.com/install-elm-0-18-0-in-2021-3f64ce298801][Install Binaries]] -N and M - Rotate robot left and right +If you want to use =npm= instead; - =npm install -g elm@elm0.18.0= -Y and H - Rotate robot arm up and down +If you use =npm=, note that you will likely need an older version of Node.js, so +it is recommended to use [[https://github.com/nvm-sh/nvm][nvm]] for that. I have not attempted this method +personally, fyi. -U and J - Rotate robot hand up and down +Once you have the Elm compiler, go ahead and run +=elm make Torus.elm= -### PQTorusknot +And that should first pull in all the dependencies then generate an =index.html= +file. -Either open up `torus.html`, or use the command `elm-reactor`, if you want to be able to modify the source file and compile; +Alternatively, you can use ~elm-reactor~, run the command and open up your browser +to ~https://localhost:8000~ and then click on ~Torus.elm~ in the nice project +webview provided. -https://guide.elm-lang.org/install.html - -Alternatively, here's the Ellie link - -https://ellie-app.com/vVTgpBj77ra1 - -![alt text](screenshots/elm-knot.png "PQ Torus Knot") +** License +This project is licensed under the terms of the MIT license. For more +information, see the included LICENSE file.