def create_other_buttons(self): f = self.make_frame("Direction") btn = Radiobutton(f, variable=self.engine.backvar, value=1, text="Up") btn.pack(side="left") if self.engine.isback(): btn.invoke() btn = Radiobutton(f, variable=self.engine.backvar, value=0, text="Down") btn.pack(side="left") if not self.engine.isback(): btn.invoke()
imgtk = ImageTk.PhotoImage(image=img) lmain.imgtk = imgtk lmain.configure(image=imgtk) while counter != 100: counter += 1 lmain.after(10, show_frame) show_frame() # cap.release() R00 = Radiobutton(top, text="Single Image", variable=var00, value=1, command=var00Sel) R00.invoke() R00.place(x = 180, y = 15) R01 = Radiobutton(top, text="Webcam", variable=var00, value=2, command=var00Sel) R01.place(x = 350, y = 15) label1 = tkinter.Label(top, text = "Low-Resolution Image", relief=RAISED) label1.config(width = 50) label1.place(x = 180, y = 50) def click1(): filename = filedialog.askopenfilename(initialdir='/Desktop')