multiply in crPage

This commit is contained in:
Simon Knott 2024-09-09 16:46:09 +02:00
parent daaba42b6a
commit 932095ccad
No known key found for this signature in database
GPG key ID: 8CEDC00028084AEC
2 changed files with 2 additions and 2 deletions

View file

@ -898,7 +898,7 @@ class FrameSession {
const buffer = Buffer.from(payload.data, 'base64'); const buffer = Buffer.from(payload.data, 'base64');
this._page.emit(Page.Events.ScreencastFrame, { this._page.emit(Page.Events.ScreencastFrame, {
buffer, buffer,
timestamp: payload.metadata.timestamp, timestamp: payload.metadata.timestamp ? payload.metadata.timestamp * 1000 : undefined,
width: payload.metadata.deviceWidth, width: payload.metadata.deviceWidth,
height: payload.metadata.deviceHeight, height: payload.metadata.deviceHeight,
}); });

View file

@ -473,7 +473,7 @@ export class Tracing extends SdkObject implements InstrumentationListener, Snaps
width: params.width, width: params.width,
height: params.height, height: params.height,
timestamp: monotonicTime(), timestamp: monotonicTime(),
frameSwapTimestamp: params.timestamp ? params.timestamp * 1000 : undefined, frameSwapTimestamp: params.timestamp,
}; };
// Make sure to write the screencast frame before adding a reference to it. // Make sure to write the screencast frame before adding a reference to it.
this._appendResource(sha1, params.buffer); this._appendResource(sha1, params.buffer);