pixelarray_test.py 文件源码

python
阅读 36 收藏 0 点赞 0 评论 0

项目:Projects 作者: it2school 项目源码 文件源码
def test_itemsize (self):
        for bytes_per_pixel in range(1, 5):
            bits_per_pixel = 8 * bytes_per_pixel
            sf = pygame.Surface ((2, 2), 0, bits_per_pixel)
            ar = pygame.PixelArray (sf)
            ai = arrinter.ArrayInterface (ar)
            self.assertEqual (ai.itemsize, bytes_per_pixel)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号