Skip to content

Rect has a negative size #6

@EmanuelNorsk

Description

@EmanuelNorsk

Hi, I am having issues again, this time with a rectangle that just wont draw without crashing or kind of crashing in a way.

Running:
sdl3.SDL_SetRenderLogicalPresentation(self.renderer, ctypes.c_long(self.innerSize[0]), ctypes.c_long(self.innerSize[1]), sdl3.SDL_LOGICAL_PRESENTATION_LETTERBOX)

somehow messes the rest of my code.

This only happens if i set the mode to sdl3.SDL_LOGICAL_PRESENTATION_LETTERBOX
if the mode is set to sdl3.SDL_LOGICAL_PRESENTATION_STRETCH, it works fine and no error is generated, but I want the screen to be in letterbox.

Running this here (Assume the variables are set to a valid python number):

Image

Prints out this:

ERROR: b'rect has a negative size', (50.0, 50.0, 200.0, 200.0), (50.0, 50.0, 200.0, 200.0)

I have no idea why it is messed up. Do you know?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions