Using bevy and custom render pipelines in order to render many objects in a forest using chunks for performance.

Overview

bevy_efficient_forest_example

Using bevy and custom render pipelines in order to render many objects in a forest using chunks for performance. Grass is rendered efficiently by not sending loads of data to the gpu but instead randomizing everything on the shader. The trees and the other objects are rendered using gpu instancing.

I could render 10 million grass straws at 70fps on my gaming pc using this approach. No one should need to render this much grass but it's good to know one can :)

Rendering the grass with with the optimized grass renderer instead of the more general gpu instancing gets me 3x-4x better fps. (When only rendering a bunch of grass)

I'm making a game for the web in which you have to code the behavior of forest animals in order to balance an ecosystem. Follow my devlogs if you are interested: https://www.youtube.com/channel/UCqzbiRaNXJa50J4kvJvKpAg

Compatible Bevy versions:

  • Bevy 0.8

Forest: Total instanced objects 192_000 (Not all visable at once, culling) Total grass straws 18_000_000 (Not all visable at once, culling) (90fps when looking around with the current camera constraints) (20x20 chunks):

forest_video.mp4

Grass 1.4 million in 1 draw call (300fps) (entire map in only 1 chunk):

grass.mp4

Textured Trees 115200 (60fps when looking at all chunks) (8x8 chunks)

trees.mp4

My Computer:

  • Nvidia 1080 Ti
  • AMD Ryzen 5 5600X 6-Core Processor
  • 32Gb Ram 2666MHz
You might also like...
A simple extension for `bevy-editor-pls` to support tilemap editing right inside the bevy app.

What is this This is a simple tilemap editor plugin, that hooks right into bevy_editor_pls to work with bevy_ecs_tilemap. It works completely within i

Bevy Simple Portals is a Bevy game engine plugin aimed to create portals.
Bevy Simple Portals is a Bevy game engine plugin aimed to create portals.

Portals for Bevy Bevy Simple Portals is a Bevy game engine plugin aimed to create portals. Those portals are (for now) purely visual and can be used t

Custom QoL patches to the 1.12.1 WoW client

vanilla-tweaks These are some custom patches for the old 1.12.1 World of Warcraft client, which lacks many of the conveniences of more modern clients.

Plugins and helpful methods for using sepax2d with Bevy for 2d overlap detection and collision resolution.

bevy_sepax2d Plugins and helpful methods for using sepax2d with Bevy for 2d overlap detection and collision resolution. Compatible Versions bevy bevy_

An adventure survival voxel game written using Bevy and Rust.

An adventure survival voxel game written using Bevy and Rust.

Proof-of-concept of getting OpenXR rendering support for Bevy game engine using gfx-rs abstractions
Proof-of-concept of getting OpenXR rendering support for Bevy game engine using gfx-rs abstractions

Introduction Proof-of-concept of getting OpenXR rendering support for Bevy game engine using gfx-rs abstractions. (hand interaction with boxes missing

A game of snake written in Rust using the Bevy game engine, targeting WebGL2

Snake using the Bevy Game Engine Prerequisites cargo install cargo-make Build and serve WASM version Set your local ip address in Makefile.toml (loca

Simple island generator written in rust using bevy engine
Simple island generator written in rust using bevy engine

Getting Started Easy enough to run cargo run --release Change generation speed Find the system set that looks like this .add_system_set(

Brine is my attempt at writing a Minecraft client in Rust using the Bevy game engine.
Brine is my attempt at writing a Minecraft client in Rust using the Bevy game engine.

Brine Brine is my attempt at writing a Minecraft client in Rust using the Bevy game engine. It's EXTREMELY work-in-progress. The thing that makes Brin

Releases(v0.1.0)
Owner
Henrik Djurestål
Father to many robots and AI:s 🤖
Henrik Djurestål
A simple helper for spawning objects in Bevy.

Spew A simple helper for spawning objects in Bevy. Usage First, create an enum that holds objects you might want to spawn: #[derive(Debug, Eq, Partial

Jan Hohenheim 6 Mar 20, 2023
Bevy engine + miniquad render plugin

Bevy engine + miniquad renderer This is a plugin for Bevy engine that replaces default windowing and rendering plugins with miniquad based one. Usage

Tomasz Sterna 31 Dec 9, 2022
A tilemap library for Bevy. With many algorithms built in.

Bevy EntiTiles A tilemap library for bevy. Notice that the crate is still in need of optimization. So don't use this in your formal projects. Strongly

443eb9#C 3 Nov 7, 2023
Terminal UI implementation and types for the Dark Forest game

dark-forest.rs Terminal UI implementation and types for the Dark Forest game Development We use the standard Rust toolchain cargo check

Georgios Konstantopoulos 63 Nov 12, 2022
Dark Forest, the world's first decentralized real-time strategy game.

darkforest-rs Dark Forest, the world's first decentralized real-time strategy game.

null 44 Oct 9, 2022
Minecraft using Bevy and Bevy-Meshem

minecraft_bevy Minecraft_bevy was built to showcase bevy_meshem. After a week of developing it has: Chunk loading / unloading each chunk's mesh is bei

Adam 7 Oct 4, 2023
Using USBPcap to side-step anticheat in games, in order to reroute rumble packets to sex toys via The Buttplug Sex Toy Control Library

Using USBPcap to side-step anticheat in games, in order to reroute rumble packets to sex toys via The Buttplug Sex Toy Control Library.

qDot 23 Jan 3, 2023
realize XPBD with rust and render in Unity

XPBD Simulation with Rust & Unity 上次看了XPBD的论文,最近又恰好在学习Rust,于是就想着用Rust来实现一个XPBD Solver练一下手,正好一箭双雕。 XPBD结论公式可参考此篇 - XPBD论文解读(Extended Position-Based Dyn

zilch 23 Nov 15, 2022
Minecraft-esque voxel engine prototype made with the bevy game engine. Pending bevy 0.6 release to undergo a full rewrite.

vx_bevy A voxel engine prototype made using the Bevy game engine. Goals and features Very basic worldgen Animated chunk loading (ala cube world) Optim

Lucas Arriesse 125 Dec 31, 2022
bevy-hikari is an implementation of voxel cone tracing global illumination with anisotropic mip-mapping in Bevy

Bevy Voxel Cone Tracing bevy-hikari is an implementation of voxel cone tracing global illumination with anisotropic mip-mapping in Bevy. Bevy Version

研究社交 208 Dec 27, 2022