sdl2.ext.Renderer.draw_line() error when argument is multiple lines

Issue #56 resolved
Matic Kukovec created an issue

Py-SDL2 version: 0.9.2

Python version: 3.3 (32-bit)

OS: Windows Vista (64-bit)

Same issue as in "Issue 52", the function works for a single line, but fails if the argument is multiple lines as defined in the docs:

(line1_x1, line1_y1, line1_x2, line1_y2, line2_x1, line2_y1, ...)

Error example code:


Error message:

File "C:\Python33\lib\site-packages\sdl2\ext\", line 144, in draw_line

ptlist = (SDL_Point * pcount / 2)()

TypeError: unsupported operand type(s) for /: '_ctypes.PyCArrayType' and 'int'

Comments (1)

  1. Marcus von Appen repo owner
    • fixed issue #56: sdl2.ext.Renderer.draw_line() and sdl2.ext.Renderer.draw_point() handle multiple lines (or points) as arguments properly now

    → <<cset 0aa582b37676>>

  2. Log in to comment