fixed take a photo

This commit is contained in:
Saifeddine ALOUI 2024-05-19 18:27:28 +02:00
parent be9fdafce8
commit c5bd7dc42b

View File

@ -113,7 +113,9 @@ def take_photo(processor, client, use_ui=False):
fn = image/f"screen_shot_{index}.png" fn = image/f"screen_shot_{index}.png"
cv2.imwrite(str(fn), frame) cv2.imwrite(str(fn), frame)
client.discussion.image_files.append(fn) client.discussion.image_files.append(fn)
return f'<img src="{discussion_path_to_url(fn_view)}" width="80%"></img>' processor.full(f'<img src="{discussion_path_to_url(fn_view)}" width="80%"></img>')
processor.new_message("")
return "Image shot successful"
def take_a_photo_function(processor, client, use_ui = False): def take_a_photo_function(processor, client, use_ui = False):