Skip to content

Commit

Permalink
Updated helper to reflect new ImGUI.
Browse files Browse the repository at this point in the history
  • Loading branch information
bXi committed Aug 3, 2024
1 parent ac12b8c commit 1b318c9
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions utils/helpers.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -233,9 +233,8 @@ void Helpers::DrawMainMenu() {

ImGui::Text("size = %d x %d", my_image_width, my_image_height);

SDL_PixelFormat *pixelFormat = texture.second.surface->format;
SDL_PixelFormatEnum pixelFormatEnum = pixelFormat->format;
const char *surfacePixelFormatName = SDL_GetPixelFormatName(pixelFormatEnum);

const char *surfacePixelFormatName = SDL_GetPixelFormatName(texture.second.surface->format);

ImGui::Text("pixel format = %s", surfacePixelFormatName);

Expand All @@ -257,7 +256,7 @@ void Helpers::DrawMainMenu() {
ImGui::Begin("Gamepads", &imguiInputVisible);

int numJoysticks;
SDL_JoystickID *joysticks = SDL_GetGamepads(&numJoysticks);
const SDL_JoystickID *joysticks = SDL_GetGamepads(&numJoysticks);

for (int i = 0; i < numJoysticks; ++i) {

Expand Down

0 comments on commit 1b318c9

Please sign in to comment.