Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/340.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/python-3.x/15.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Python 无法降低PI Zero W上pygame的全屏分辨率_Python_Python 3.x_Raspberry Pi_Pygame - Fatal编程技术网

Python 无法降低PI Zero W上pygame的全屏分辨率

Python 无法降低PI Zero W上pygame的全屏分辨率,python,python-3.x,raspberry-pi,pygame,Python,Python 3.x,Raspberry Pi,Pygame,我在Raspberry PI Zero W上以ie:1920x1080的桌面分辨率运行Raspbian(buster),但希望使用pygame创建一个以较低分辨率全屏运行的python游戏。我无法切换到较低的全屏分辨率,列表模式仅返回单一模式(当前屏幕分辨率) 当我用pygame.display.list_modes()列出可用模式时 ---pygame仅返回当前屏幕分辨率,即:1920x1080 我在raspbian stretch和更新的buster版本上有相同的行为 我在以任何其他分辨率运

我在Raspberry PI Zero W上以ie:1920x1080的桌面分辨率运行Raspbian(buster),但希望使用pygame创建一个以较低分辨率全屏运行的python游戏。我无法切换到较低的全屏分辨率,列表模式仅返回单一模式(当前屏幕分辨率)

  • 当我用pygame.display.list_modes()列出可用模式时 ---pygame仅返回当前屏幕分辨率,即:1920x1080
  • 我在raspbian stretch和更新的buster版本上有相同的行为
  • 我在以任何其他分辨率运行操作系统时也有相同的行为,即:1024x768,然后1024x768是唯一返回的模式
  • 这种行为在windows pc或PI4型号B上都看不到
  • Python3即时模式:

    >>> import pygame
    pygame 1.9.6
    Hello from the pygame community. https://www.pygame.org/contribute.html
    >>> pygame.init()
    (6, 0)
    >>> pygame.display.list_modes()
    [(1920, 1080)]
    
    pygame.display.list_modes()应返回多种模式,但仅返回当前分辨率

    pygame.display.set_模式((800600),pygame.FULLSCREEN)切换到全屏,但屏幕分辨率保持不变,为1920x1080。没有出现错误

    鉴于在PC和PI4上运行的行为正确,此问题可能仅限于零W板?? --丰富的