GithubHelp home page GithubHelp logo

rc-nannou's Introduction

nannou sketchbook

nannou sketchbook during my batch @ The Recurse Center.

dependencies

  • rust: https://www.rust-lang.org/

    • cargo (comes with rust)
  • vulkan sdk (should install the first time you try to build a nannou sketch)

the workspace

The root directory is a cargo workspace which allows all of the sketches to share nannou as a dependency and improves build time for new sketches.

Sketches share the same /target directory which is located in the root folder

example of document heirarchy:

rc-nannou
  ├── Cargo.toml          # Defines workspace
  ├── sketch-one/         # Container for sketch
  │    ├── Cargo.toml     # Defines sketch dependencies
  │    └── src/
  │         └── main.rs   # Main sketch file
  └── target/             # Where sketches are built

run a sketch

Use the following command to run & display a nannou sketch (Where [SKETCHNAME] is the name of a sketch directory)

cargo run -p [SKETCHNAME] --release

The sketch name must be included in the Cargo.toml file in the root directory under "members".

example:

members = [
  "sketch-one",           # It's ok to have trailing commas
]

cli

because it's kind of tedious to continue updating the main Cargo.toml file with all of the "members" of the workspace, I wrote a bash script that offers two functions

nannou run [SKETCHNAME]   # runs a sketch
nannou update             # updates members list
                          #   in main Cargo.toml

TODO: instructions for how to install nannou cli?

rc-nannou's People

Contributors

zachkrall avatar

Stargazers

 avatar  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.