maybe support encoded cameras
This commit is contained in:
+2
-1
@@ -255,6 +255,7 @@ const deal_with_data = (session: Session, dv: DataView) => {
|
||||
// retransmit
|
||||
return;
|
||||
}
|
||||
if (session.curImage.length == 0) return; // missed the start-of-frame packet
|
||||
|
||||
let b = Buffer.from(data.buffer);
|
||||
|
||||
@@ -269,7 +270,7 @@ const deal_with_data = (session: Session, dv: DataView) => {
|
||||
return;
|
||||
}
|
||||
|
||||
if (session.curImage.length <= 1) return; // header does not have markers
|
||||
if (session.curImage.length == 1) return; // header does not have markers
|
||||
|
||||
let lastFrameSlice = session.curImage[session.curImage.length - 1];
|
||||
const lastResetMarker = findAllResetMarkers(lastFrameSlice).pop();
|
||||
|
||||
Reference in New Issue
Block a user