ui: flip driver camera horizontally (#35712)

flip driver camera horizontally
This commit is contained in:
Dean Lee
2025-07-14 00:33:27 +08:00
committed by GitHub
parent db37f4187e
commit 55579c8c08
+3
View File
@@ -179,6 +179,9 @@ class CameraView(Widget):
transform = self._calc_frame_matrix(rect)
src_rect = rl.Rectangle(0, 0, float(self.frame.width), float(self.frame.height))
# Flip driver camera horizontally
if self._stream_type == VisionStreamType.VISION_STREAM_DRIVER:
src_rect.width = -src_rect.width
# Calculate scale
scale_x = rect.width * transform[0, 0] # zx