1from tkinter import *
2from PIL import ImageTk, Image
3
4root = Tk()
5
6c = Canvas(root, width=500, height=500)
7c.pack()
8
9img = ImageTk.PhotoImage(Image.open(r"imagepath\imagename.extension"))
10c.create_image(x, y, image=img, anchor=NW)
1from tkinter import *
2root = Tk()
3myCanvas = Canvas(root)
4myCanvas.pack()
5
6def create_circle(x, y, r, canvasName): #center coordinates, radius
7 x0 = x - r
8 y0 = y - r
9 x1 = x + r
10 y1 = y + r
11 return canvasName.create_oval(x0, y0, x1, y1)
12
13create_circle(100, 100, 20, myCanvas)
14create_circle(50, 25, 10, myCanvas)
15root.mainloop()