Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
kiss3d
Keep It Simple, Stupid 3d graphics engine.
This library is born from the frustration in front of the fact that today’s 3D graphics library are:
- either too low level: you have to write your own shaders and opening a window steals you 8 hours, 300 lines of code and 10L of coffee.
- or high level but too hard to understand/use: those are libraries made to write beautiful animations or games. They have a lot of feature; too much feature if you only want to draw a few geometries on the screen.
kiss3d is not designed to be feature-complete or fast. It is designed to be able to draw simple geometric figures and play with them with one-liners.
An on-line version of this documentation is available here.
Features
Most features are one-liners.
- open a window with a default arc-ball camera and a point light.
- a first-person camera is available too and user-defined cameras are possible.
- display boxes, spheres, cones, cylinders, quads and lines.
- change an object color or texture.
- change an object transform (we use the nalgebra library to do that).
- create basic post-processing effects.
As an example, having a red, rotating cube with the light attached to the camera is as simple as:
extern crate native;
extern crate kiss3d;
extern crate nalgebra;
use Vec3;
use Window;
use light;
Some controls are handled by default by the engine (they can be overridden by the user):
scroll
: zoom in / zoom out.left click + drag
: look around.right click + drag
: translate the view point.enter
: look at the origin (0.0, 0.0, 0.0).
Compilation
You will need the last nightly build of the rust compiler and the official package manager: cargo.
Simply add the following to your Cargo.toml
file:
[dependencies.kiss3d]
git = "https://github.com/sebcrozet/kiss3d"
Contributions
I’d love to see people improving this library for their own needs. However, keep in mind that kiss3d is KISS. One-liner features (from the user point of view) are preferred.
Acknowledgements
Thanks to all the Rustafarians for their help, and their OpenGL/ffmpeg/stb-image/etc. bindings.