Post Reply 
How to use graphic.draw_filled_polygon?
11-28-2021, 10:25 PM
Post: #8
RE: How to use graphic.draw_filled_polygon?
with the last update 2021-11-25 it's now working on the G2 too.
<draw_filled_polygon()> obviously needs two parameters. one list of the co-ordinates an one color.

E.g:
from graphic import *
draw_filled_polygon(((0,0),(160,120),(0,240)),blue)

instead of making it all <tuple> seems we can mix <list> and <tuple>. This works also:
draw_filled_polygon([(0,0),(160,120),(0,240)],blue) or even a mix(ugly):
draw_filled_polygon([[0,0],(160,120),(0,240)],blue)

Günter
Find all posts by this user
Quote this message in a reply
Post Reply 


Messages In This Thread
RE: How to use graphic.draw_filled_polygon? - Guenter Schink - 11-28-2021 10:25 PM



User(s) browsing this thread: 1 Guest(s)