Issue #24 resolved

blit_array() fails with a 24 bit surface

René Dudfield
created an issue

== Lenard Lindstrom, 2008-10-22 13:31:06 -0700

{{{ Created attachment 13 Test program that reproduces blit_array() bug.

Pygame-1.9.0a0 (rev. 1668) numpy 1.0.4 Python 2.5.2

pygame.surfarray.blit_array() raises an exception when a 3d array is copied to a 24 bit surface. The test program is attached.

Traceback (most recent call last): File "array_bug.py", line 6, in <module> pygame.surfarray.blit_array(s, a) File "C:\PRG\PYTHON25\lib\site-packages\pygame\surfarray.py", line 260, in bli t_array return numpysf.blit_array (surface, array) File "C:\PRG\PYTHON25\lib\site-packages\pygame_numpysurfarray.py", line 381, in blit_array (array[:,:,1::3] >> losses[1] << shifts[1]) | \ TypeError: unsupported operand type(s) for >>: 'float' and 'int' }}}


Attachments: [[http://www.pygame.org/old_bug_attachments/13/array_bug.py| array_bug.py]]

== Lenard Lindstrom, 2009-01-22 01:28:17 -0800

{{{ Fixed in SVN revision 1851. }}}


Comments (1)

  1. Log in to comment