Webgl Seed Save

🌐🌱 A starter repo for building WebGL applications.

Project README

Cover Art

WebGL Seed

License Unit Tests Dependency Status devDependency Status

A simple hello triangle example you could use to as a basis when starting WebGL.

Setup

First install:

Then type the following in any terminal your such as VS Code's Integrated Terminal.

# πŸ‘ Clone the repo
git clone https://github.com/alaingalvan/webgl-seed

# πŸ’Ώ go inside the folder
cd webgl-seed

# πŸ”¨ Start building the project
npm start

Refer to this blog post on designing web libraries and apps for more details on Node.js, packages, etc.

Project Layout

As your project becomes more complex, you'll want to separate files and organize your application to something more akin to a game or renderer, check out this post on game engine architecture and this one on real time renderer architecture for more details.

β”œβ”€ πŸ“‚ node_modules/   # πŸ‘Ά Dependencies
β”‚  β”œβ”€ πŸ“ gl-matrix      # βž• Linear Algebra
β”‚  └─ πŸ“ ...            # πŸ•š Other Dependencies (TypeScript, Webpack, etc.)
β”œβ”€ πŸ“‚ src/            # 🌟 Source Files
β”‚  β”œβ”€ πŸ“„ renderer.ts    # πŸ”Ί Triangle Renderer
β”‚  └─ πŸ“„ main.ts        # 🏁 Application Main
β”œβ”€ πŸ“„ .gitignore      # πŸ‘οΈ Ignore certain files in git repo
β”œβ”€ πŸ“„ package.json    # πŸ“¦ Node Package File
β”œβ”€ πŸ“„ license.md      # βš–οΈ Your License (Unlicense)
└─ πŸ“ƒreadme.md        # πŸ“– Read Me!

Some key dependencies are:

  • gl-matrix - WebGL's best linear algebra library, perfect for people used to linear algebra libraries like GLM or the built in GLSL data structures.

  • Webpack - Compiles our TypeScript files and creates binaries for us to use.

  • TypeScript - JavaScript with types, makes it significantly easier to program web apps with instant autocomplete and type checking.

Open Source Agenda is not affiliated with "Webgl Seed" Project. README Source: alaingalvan/webgl-seed
Stars
44
Open Issues
7
Last Commit
1 year ago

Open Source Agenda Badge

Open Source Agenda Rating