Skip to content

Commit

Permalink
add icon
Browse files Browse the repository at this point in the history
  • Loading branch information
Qendolin committed Jun 16, 2024
1 parent 3047ac6 commit cd5f4ce
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
Binary file added assets/textures/icon32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
8 changes: 8 additions & 0 deletions src/Game.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
#include "GL/StateManager.h"
#include "GL/Texture.h"
#include "Input.h"
#include "Loader/Loader.h"
#include "Particles/ParticleSystem.h"
#include "Physics/Physics.h"
#include "Renderer/BloomRenderer.h"
Expand Down Expand Up @@ -208,6 +209,13 @@ void Game::load() {
gtaoRenderer_ = std::make_unique<GtaoRenderer>();
gtaoRenderer_->setViewport(window.size.x, window.size.y);
debugRenderer_ = std::make_unique<DebugRenderer>();

GLFWimage window_icon;
auto window_icon_img = loader::image("assets/textures/icon32.png");
window_icon.width = window_icon_img.width;
window_icon.height = window_icon_img.height;
window_icon.pixels = window_icon_img.data.get();
glfwSetWindowIcon(window, 1, &window_icon);
}

void Game::unload() {
Expand Down

0 comments on commit cd5f4ce

Please sign in to comment.