पर पायगम के साथ गलत रंग एंटीअलाइजिंग मैं मैकबुक प्रो (गैर-रेटिना) ओएस एक्स चलाने पर पायगम का उपयोग कर रहा हूं। जब मैं एंटीअलाइज्ड लाइन या सर्कल बनाने की कोशिश करता हूं, तो यह गलत रंग के रूप में बाहर आ रहा है ।ओएस एक्स
import sys, pygame, random, math
import pygame.gfxdraw
black = (0,0,0)
white = (255, 255, 255)
green = (0, 255, 0)
pygame.init()
size = width, height = 800, 600
screen = pygame.display.set_mode(size)
# make the background
background = pygame.Surface(screen.get_size())
#background.fill(black)
background.fill(white)
while 1:
# handle single events
for event in pygame.event.get():
if event.type == pygame.QUIT: sys.exit()
if event.type == pygame.KEYDOWN:
if event.key == pygame.K_ESCAPE: sys.exit()
screen.blit(background, (0, 0))
pygame.draw.line(screen, green, [0, 0], [50,30], 1)
pygame.draw.aaline(screen, green, [0, 50],[50, 80], True)
pygame.draw.circle(screen, black, [100, 100], 10)
pygame.gfxdraw.aacircle(screen, 100, 130, 10, black)
pygame.display.flip()
ओर जाता है कौन सा करने के लिए:
धन्यवाद, यह बेहद सहायक है! – user2171504