Skip to content
Source
Docs
Explore
Skills
MCP servers
For agents
Search or jump to…
Sign in
Sign up
pingdotgg
/
t3code
Pull requests
pingdotgg
t3code
Public
Synced with GitHub
Popular #1
Fork
0
0
0
0
1
2
3
4
5
6
7
8
9
Code
Architecture
Issues
Pull requests
Community
Assets
CI
Agents
Settings
fix(server): reduce dropped frames in agent preview recordings
#34131
Send to my agent
Closed
juliusmarminge
wants to merge 6 commits into
main
from
refs/pull/34131/head
·
opened
3 weeks ago
View on GitHub
Conversation
6
Commits
6
Files changed
3
Impact
Showing
3 changed files
with
141 additions
and
28 deletions
.
x
0 of 3 viewed, 3 left
Files
Hide whitespace
Unified
Split
110 additions and 4 deletions
+110
-4
apps/server/src/preview/ServerBrowser.test.ts
Modified
Diff
Before/After
Viewed
apps/server/src/preview/ServerBrowser.test.ts
View file
Expand up
Show all 259 lines
@@ -260,27 +260,60 @@
260
260
width:
0
,
261
261
height:
0
,
262
262
getContext: () => ({
drawImage
() {},
fillRect
() {} }),
263
-
captureStream: (frameRate?:
number
) => ({ frameRate,
getTracks
: () => [] }),
263
+
captureStream: (frameRate?:
number
) => ({
264
+
frameRate,
265
+
getTracks
: () => [],
266
+
getVideoTracks
: () => [{
requestFrame
() {} }],
267
+
}),
268
+
};
269
+
const
video = {
270
+
play
:
async
() => {},
271
+
pause
() {},
272
+
requestVideoFrameCallback
: (callback: () =>
void
) =>
queueMicrotask
(callback),
264
273
};
265
274
class
FakeMediaRecorder
{
266
275
static
isTypeSupported = (
type
:
string
) =>
type
===
"video/webm"
;
267
276
onstart: (() =>
void
) |
null
=
null
;
277
+
onstop: (() =>
void
) |
null
=
null
;
278
+
ondataavailable: ((event: {
data
:
Blob
}) =>
void
) |
null
=
null
;
279
+
state =
"inactive"
;
280
+
mimeType =
"video/webm"
;
281
+
readonly
stream: { frameRate?:
number
};
268
282
constructor
(stream: { frameRate?:
number
}, options: {
videoBitsPerSecond
:
number
}) {
283
+
this
.
stream
= stream;
269
284
encoderStreams.
push
({
270
285
frameRate
: stream.
frameRate
,
271
286
bitsPerSecond
: options.
videoBitsPerSecond
,
272
287
});
Home
Search
Explore
Menu