Crates.io | mepeyew |
lib.rs | mepeyew |
version | 0.3.5 |
source | src |
created_at | 2023-05-15 04:37:22.07964 |
updated_at | 2024-04-28 18:17:27.604787 |
description | mepeyew - Small But Powerful Graphics Library |
homepage | https://github.com/davnotdev/mepeyew |
repository | https://github.com/davnotdev/mepeyew |
max_upload_size | |
id | 864726 |
size | 7,385,713 |
Computer graphics has gotten to the point where you can't just draw pixels onto the screen directly anymore. Instead, rendering APIs are used for drawing in order to efficiently utilize the hardware. Each platform has its own set of preferred APIs (DirectX on Windows, Metal on MacOS, etc), where said platform has its own little quirks and tricks.
Built in rust, mepeyew
is meant to hide away these quirks in a nice and neat package while
trying to give you as much power as possible!
mepeyew
wraps multiple graphics APIs like wgpu
, but has an very explicit API similar to Vulkan's.
Hello Triangle | Outlined Cube | PBR Spheres |
---|---|---|
You can run mepeyew
on Windows, MacOS, Linux, and the Web.
Currently, we support Vulkan and WebGpu.
In terms of shading languages, we support Glsl, Spirv, and Wgsl all with the help of naga.
Add this to your Cargo.toml
:
mepeyew = "0.3"
This enables mepeyew
with the following features:
vulkan
webgpu
surface_extension
naga_translation
If you do not plan on using these features, disabling them will decrease your dependency count.
To get started with using mepeyew
, check out
the examples here on Github.
They assume that you already understand graphics programming.
Unfortunately, not everything can be fully abstracted away! Please read the docs before continuing!
MacOS does not natively support Vulkan, so you will need to install LunarG's Vulkan SDK from here. Then, you will need the following exports to proper compile.
VULKAN_SDK=$HOME/VulkanSDK/<version>/macOS
DYLD_FALLBACK_LIBRARY_PATH=$VULKAN_SDK/lib
VK_ICD_FILENAMES=$VULKAN_SDK/share/vulkan/icd.d/MoltenVK_icd.json
VK_LAYER_PATH=$VULKAN_SDK/share/vulkan/explicit_layer.d
Be sure to see the documentation regarding
WebGpuInit
andWebGpuInitFromWindow
.
The easiest way to get setup is to create an extra workspace member in your
Cargo.toml
.
[workspace]
members = [
"run_wasm"
]
Then, implement run_wasm
exactly as shown in this repo.
This is very important as this project depends on my fork of run_wasm
and
NOT the original crate.
Of course, you can use wasm-pack
, trunk
, or whatever else you'd like.
This project is mostly complete, but there are still bugs and changes that may come. The API is designed to be stable, but I can't guarantee anything of course.
prelude