Skip to content

Commit eb7cd0f

Browse files
committed
Live Stream ex fixed
1 parent 087580d commit eb7cd0f

File tree

1 file changed

+2
-2
lines changed
  • content/hardware/06.nicla/boards/nicla-vision/tutorials/live-streaming

1 file changed

+2
-2
lines changed

content/hardware/06.nicla/boards/nicla-vision/tutorials/live-streaming/content.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ def start_streaming(s):
148148
while True:
149149
clock.tick() # Track elapsed milliseconds between snapshots().
150150
frame = sensor.snapshot()
151-
cframe = frame.compressed(quality=35)
151+
cframe = frame.to_jpeg(quality=35, copy=True)
152152
header = (
153153
"\r\n--openmv\r\n"
154154
"Content-Type: image/jpeg\r\n"
@@ -273,7 +273,7 @@ def start_streaming(s):
273273
while True:
274274
clock.tick() # Track elapsed milliseconds between snapshots().
275275
frame = sensor.snapshot()
276-
cframe = frame.compressed(quality=35)
276+
cframe = frame.to_jpeg(quality=35, copy=True)
277277
header = (
278278
"\r\n--openmv\r\n"
279279
"Content-Type: image/jpeg\r\n"

0 commit comments

Comments
 (0)