Skip to content

Commit

Permalink
Fixed dest img reading
Browse files Browse the repository at this point in the history
  • Loading branch information
hanzhi713 committed Nov 5, 2018
1 parent b349e7b commit b16e174
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -262,7 +262,7 @@ def load_dest_img():
fp = filedialog.askopenfilename(initialdir=os.path.dirname(__file__), title="Select destination image",
filetypes=(("images", "*.jpg"), ("images", "*.png"), ("images", "*.gif"),
("all files", "*.*")))
if fp is not None and len(fp) >= 0 and os.path.isfile(fp):
if fp is not None and len(fp) > 0 and os.path.isfile(fp):
try:
print("Destination image loaded from", fp, file=out_wrapper)
dest_img = cv2.imread(fp)
Expand Down

0 comments on commit b16e174

Please sign in to comment.