Skip to content

Commit

Permalink
Disable depth and stencil buffers
Browse files Browse the repository at this point in the history
Disable allocation of depth and stencil buffers. This reduces active
GPU memory consumption by almost a third, at least on Linux.
  • Loading branch information
Jasu authored and chrisduerr committed Oct 11, 2019
1 parent 2f83f2d commit 3475e44
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- Crash when resuming after suspension
- Crash when trying to start on X11 with a Wayland compositor running
- Crash with a virtual display connected on X11
- GPU memory usage has been decreased by disabling allocation of depth and stencil buffers

### Removed

Expand Down
2 changes: 2 additions & 0 deletions alacritty/src/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,8 @@ fn create_gl_window(
let windowed_context = ContextBuilder::new()
.with_srgb(srgb)
.with_vsync(true)
.with_depth_buffer(0)
.with_stencil_buffer(0)
.with_hardware_acceleration(None)
.build_windowed(window, event_loop)?;

Expand Down

0 comments on commit 3475e44

Please sign in to comment.