Skip to content

Grayed out Modal windows in python backend #156

@Aman-Anas

Description

@Aman-Anas

The interior of modal windows is grayed out in the backend, rather than the exterior area. This seems to be a documented issue with some backends with a newer Dear Imgui version

Documented here: https://github.com/ocornut/imgui/releases/tag/v1.86

I was able to fix it by changing some lines in the opengl renderer

                gl.glDrawElements(
                    gl.GL_TRIANGLES,
                    command.elem_count,
                    gltype,
                    ctypes.c_void_p(idx_buffer_offset),
                )

to

                gl.glDrawElements(
                    gl.GL_TRIANGLES,
                    command.elem_count,
                    gltype,
                    ctypes.c_void_p(command.idx_offset * imgui.INDEX_SIZE)
                )

I don't really know opengl too well, but it seems to work fine.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions