diff --git a/src/robot_interface/endpoints/video_sender.py b/src/robot_interface/endpoints/video_sender.py index 8c8968e..5172bd5 100644 --- a/src/robot_interface/endpoints/video_sender.py +++ b/src/robot_interface/endpoints/video_sender.py @@ -68,13 +68,19 @@ class VideoSender(SocketBase): if cv2.waitKey(1) & 0xFF == ord('q'): # << Add this: Updates the window break - small_frame = cv2.resize(frame, (320, 240), interpolation=cv2.INTER_AREA) - encode_param = [int(cv2.IMWRITE_JPEG_QUALITY), 70] - _, buffer = cv2.imencode('.jpg', small_frame, encode_param) + height, width, channels = frame.shape + print(width) + print(height) + pixel_data = frame.tobytes() - #cv2.imshow("Sender Preview", small_frame) # << Add this: Opens the window + width_bytes = struct.pack('