GithubHelp home page GithubHelp logo

rlugojr / piston Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pistondevelopers/piston

0.0 1.0 0.0 3.98 MB

A modular game engine written in Rust

Home Page: http://www.piston.rs

License: MIT License

Shell 0.07% Rust 99.93%

piston's Introduction

#Piston

Build Status Crates.io Crates.io

A modular game engine written in Rust

Maintainers of Piston core libraries: @bvssvni

Dive into the world of Piston

Start new project with Piston

You should know how to build "hello world" with Rust, see http://www.rust-lang.org/.

Drawing a red rectangle

Add piston_window to your Cargo.toml, for example:

[dependencies]
piston_window = "0.61.0"

In "src/main.rs", type the following code:

extern crate piston_window;

use piston_window::*;

fn main() {
    let mut window: PistonWindow =
        WindowSettings::new("Hello Piston!", [640, 480])
        .exit_on_esc(true).build().unwrap();
    while let Some(e) = window.next() {
        window.draw_2d(&e, |c, g| {
            clear([1.0; 4], g);
            rectangle([1.0, 0.0, 0.0, 1.0], // red
                      [0.0, 0.0, 100.0, 100.0],
                      c.transform, g);
        });
    }
}

Use cargo run to start the application. It should clear the screen in white color and draw a red rectangle.

red-rectangle

Goals

The Piston project is a large collaboration among many developers. There are libraries for 2D, 3D, event programming, AI, image processing etc. By sharing the maintenance, we get more time to build new stuff.

Piston is as much a community project as it is a collection of libraries. Writing and maintaining code is expensive, and by sharing this cost we reach our goals faster. We believe that seeking personal goals and ambitions, while helping each other, results in higher quality.

  • Our main goal is to free up time for maintainers and the people involved
  • ... such that we can create new amazing stuff and reach our personal goals
  • ... by making more people use Rust for game development and become engaged in open source

In addition we do research or plan to in the following areas:

Dependency graph

dependencies

piston's People

Contributors

bvssvni avatar coeuvre avatar potpourri avatar mitchmindtree avatar gmorenz avatar indiv0 avatar leonkunert avatar bfops avatar tyoverby avatar zummenix avatar mkcp avatar phlosioneer avatar gchp avatar angrylawyer avatar nabijaczleweli avatar maxsnew avatar reem avatar jeremija avatar cantsin avatar milibopp avatar christolliday avatar abonander avatar featureenvy avatar murilocadanus avatar palango avatar pierrechevalier83 avatar tbillington avatar hayleydeckers avatar simcop2387 avatar eklavya 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.