diff --git a/.gitignore b/.gitignore index c729144..5d6b155 100644 --- a/.gitignore +++ b/.gitignore @@ -7,4 +7,5 @@ build/ __pycache__/ *.pyc clashroyalebuildabot/debug -clashroyalebuildabot/emulator/platform-tools \ No newline at end of file +clashroyalebuildabot/emulator/platform-tools +env/ \ No newline at end of file diff --git a/clashroyalebuildabot/visualizer.py b/clashroyalebuildabot/visualizer.py index d5a56ce..6ada675 100644 --- a/clashroyalebuildabot/visualizer.py +++ b/clashroyalebuildabot/visualizer.py @@ -33,6 +33,7 @@ def __init__(self): self.font = ImageFont.load_default() self.unit_names = [unit["name"] for unit in list(NAME2UNIT.values())] cv2.namedWindow("Visualizer", cv2.WINDOW_NORMAL) + logger.info("Visualizer initialized.") def _draw_text(self, d, bbox, text, rgba=(0, 0, 0, 255)): @@ -74,10 +75,6 @@ def annotate_image(self, image, state): def run(self, image, state): annotated_image = self.annotate_image(image, state) - # Convert PIL image to a NumPy array explicitly annotated_image = np.array(annotated_image) - # Ensure the window is initialized cv2.imshow("Visualizer", cv2.cvtColor(annotated_image, cv2.COLOR_RGB2BGR)) - #Log the window size - logger.info(f"Visualizer window size: {cv2.getWindowImageRect('Visualizer')}") - cv2.waitKey(0) \ No newline at end of file + cv2.waitKey(1) diff --git a/platform-tools-latest-windows.zip b/platform-tools-latest-windows.zip new file mode 100644 index 0000000..98897e9 Binary files /dev/null and b/platform-tools-latest-windows.zip differ