Code Monkey home page Code Monkey logo

webgpu-isoline-geometry's Introduction

TSL Isolines Geometry

TSL Isolines Geometry

Welcome to "TSL Isolines Geometry" This repo is adressed to three.js enthousiasts curious about TSL, but also to creative coders who may not know about this particular algorithm.

Website

Visit https://ulucode.com/random/webgputests/isolines/ to play! Requires a browser with WebGPU support.

TSL

Most of the important code, regarding TSL and the implementation of the algorithm is in /src/lib/elements/IsolinesMeshing.ts The file is commented and uses descriptive variable names. It is partially typed, but don't worry if you know nothing about Typescript : you can safely ignore it (although I would encourage you to look into it).

Disclaimer

This is very experimental : I haven't looked under the hood at how TSL works, I'm just going from the examples provided by three.js and their documentation. I can't guarantee that I'm following good TSL practices is such a thing exists. My goal was to produce a fun toy, with an artistic flavor.

Features

  • TSL and WebGPU: Takes advantage of Three Shading Language (TSL) and WebGPU, with vertex, fragment and compute shaders all in Javascript, no WGSL involved for the end user.
  • Interactive Simulation: Plenty of buttons and sliders to play with, as well cursor interactions.
  • Capture: Capture still frames of your creation.

Getting Started

To start the development environment for this project, follow these steps:

  1. Clone the repository to your local machine:
git clone https://github.com/ULuIQ12/webgpu-isoline-geometry.git
  1. Navigate to the project directory:
cd webgpu-isoline-geometry
  1. Install the dependencies:
npm install
  1. Start the development server:
npm run dev

This will start the development server and open the project in your default browser.

Building the Project

  1. Edit the base path in vite.config.ts

  2. To build the project for production, run the following command:

npm run build

This will create an optimized build of the project in the dist directory.

Acknowledgements

Resources

webgpu-isoline-geometry's People

Contributors

uluiq12 avatar

Stargazers

Jean-Michel Paris avatar Jean-Philippe Deblonde avatar Warren Lu avatar  avatar Jonathan Davidson avatar 地虎降天龙.hawk avatar Makio64 avatar Dennis Smolek avatar  avatar Tom Beddard avatar  avatar Ollie Razdow avatar Catalin Moldovan avatar Vanessa Williams avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.