The project is a scalajs facade for threejs https://threejs.org/
Doc & Demo
Use
https://repo1.maven.org/maven2/app/fmgp/scala-threejs_sjs1.0-RC2_2.13/
libraryDependencies += "app.fmgp" % "fmgp-threejs_2.13" % "0.1-M1"
Run on sbt:
fastOptJS::webpack
controller/console
> :load script.sc
TODO LIST / Roadmap / Ideas
- Add Shapes:
- Frustum (Camera Helper) [8h] (Do it later)
- Axis Path [2d]
- Threejs:
- Support for Terrain[16h]
- Draft initial support for light[16h]
- Draft initial support for materials [1w]
- Interface improvements:
- Support for scene resizing[8h]
- Write Interface with our API [?d]
- Make interface with 3D obj (could be used for mobile and be very useful for VR)
- Publish version 0.1 to Maven
- Fix build.sbt for publish [16h]
- Make documentation [2w]
- Cleanup code
- Rename Github repository, project name in Maven and modelos in SBT
- Chaos theory; Butterfly effect; FMGP; Scala; Geometry
- Make a Docker Container with everything ready to use.
- Serve the FE's javascript file via HTTP from the BE. [4h]
- Draft DocketFile [16h]
- Selling points ideas:
- Scala has really nice BigData libraries but is lack of libraries for Machine Learning, unlike python. I don't think the language is difficult, quite the opposite! IMO the problem is the lack of tools and libs for Data Visualization. I think scalaJS could feel that hole. So the plan here is the make a simples API. Could try to make some interative dashboard with scalajs and mdoc (mdoc is not working with scalajs 1.x)
- Draft support for real-time collaborative work on algorithmic design.
- The system has 3 Components:
- FE - A browser here the models is viewed. Most of the mesh of the models are generated on the FE!
- BE - Server that is connected with the FE via websocket and receive commands from a client.
- Client - Simple API / lib where algorithmic design are specified on the scala RELP or Worksheet. Connects with the BE server
- The system has 3 Components:
- HList for Coordinate (use shapeless or wait for dotty?)
- Implemente a Coordinate system with a HList (Heterogeneous lists). I imagine HList having really nice properties to support an arbitrary number of dimensions. Implement specialized support for 2D and 3D. In top of HList.
- Try to integrate with KHEPRI again
- Support for Constructive Geometry - union; intersection; subtraction (This is not supported on threejs)
- Constructive Solid Geometry - basic implementation (with Quadtrees) Have a look and get inspiration from: https://github.com/dzufferey/scadla https://github.com/dzufferey/scadla-oce-backend https://stemkoski.github.io/Three.js/CSG.html https://github.com/stemkoski/stemkoski.github.com/blob/master/Three.js/CSG.html https://github.com/chandlerprall/ThreeCSplatformG
TODO list that Probably never will happen
- List
- TextShape [2w] (implement my own algorithm)
- Algorithmic design examples
- Bamboo house
- Transformer house - Single room multi configurations
- Experiments:
- Input controller: GamePad; VR; Ray Tracing Pixel-select
- 3 Dimensional Vector graphics
- Game idia: make an empty city or a shopping mall. Give each player's a place to remodel. Would be like an Architecture (algorithmic design) hackathon.
- Game idia:
- Make a 3d maze, where you can only choose between left and right paths and control the velocity.
- Then make a 3d sandbox with weird gravity.
- Use Node.js as the JavaScript runtime system. (We can try also the Electron
- Compile code on the backend as a module and dynamically load it on the FE.
- Try WebGPU and try to implemente some machine learning algorithms!
- FPV Drone Simulator! How hard can it be?
- Optimizations:
- Config circe entity encoder json to drop null values vs Encode text on binary vs Use protobuf
- Experiment with webgl shaders for optimizations.
- Learn WebGL Shaders
Copyright and License
This project is licensed under the MIT license, available at http://opensource.org/licenses/mit-license.php and also in the LICENSE file.
Copyright the Fabio Pinheiro, 2020.