mirror of
https://github.com/clockworkpi/launcher.git
synced 2025-12-12 09:48:50 +01:00
add dest surface in GlobalScale
This commit is contained in:
parent
6e9d146e80
commit
712ce14fc5
@ -112,8 +112,8 @@ def DrawText(canvas,text, x,y,width,height,canWidth,canHeight,fontObj):# text fo
|
||||
def SwapAndShow():
|
||||
screen = pygame.display.get_surface()
|
||||
if config.GlobalScale > 1:
|
||||
tmp = pygame.transform.scale(config.GlobalCanvas,(Width*config.GlobalScale,Height*config.GlobalScale))
|
||||
screen.blit(tmp,(0,0,Width*config.GlobalScale,Height*config.GlobalScale))
|
||||
pygame.transform.scale(config.GlobalCanvas,(Width*config.GlobalScale,Height*config.GlobalScale),config.GlobalCanvas2)
|
||||
screen.blit(config.GlobalCanvas2,(0,0,Width*config.GlobalScale,Height*config.GlobalScale))
|
||||
elif config.GlobalScale == 1:
|
||||
screen.blit(config.GlobalCanvas,(0,0,Width,Height))
|
||||
|
||||
|
||||
@ -34,6 +34,7 @@ PowerLevels["balance_saving"] = [40,0,0]
|
||||
PowerLevel = "balance_saving"
|
||||
|
||||
GlobalCanvas=None
|
||||
GlobalCanvas2=None
|
||||
GlobalScale = 1
|
||||
|
||||
def PreparationInAdv():
|
||||
|
||||
@ -663,6 +663,7 @@ if __name__ == '__main__':
|
||||
exit()
|
||||
|
||||
config.GlobalCanvas = pygame.Surface((Width,Height),0,32)
|
||||
config.GlobalCanvas2 = pygame.Surface(SCREEN_SIZE ,0,32)
|
||||
|
||||
crt_screen = CreateByScreen()
|
||||
crt_screen.Init()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user