-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
74 lines (67 loc) · 2.19 KB
/
index.html
File metadata and controls
74 lines (67 loc) · 2.19 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<html>
<head>
<meta charset="UTF-8">
<title>HTMLVideoElement.captureStream() demo</title>
<style type="text/css">
.control-buttons {
display: flex;
justify-content: center;
}
.control-buttons button{
margin-right: 10px;
}
.video-preview {
display: flex;
justify-content: center;
}
.video-preview .original-preview{
width:640px;
height: 360px;
display: flex;
justify-content: center;
align-items: center;
}
.video-preview .original-video {
flex: 0;
}
.video-preview .original-video video {
width:640px;
height: auto;
}
.video-preview canvas {
width:640px;
height: 360px;
background-color: black;
}
.track-fps-info {
font-weight: bold;
}
</style>
</head>
<body>
<div class="control-buttons">
<button class="start-button">Play & Start streamCapture</button>
<button class="stop-button">Stop</button>
<input type="file">
</div>
<div class="video-preview">
<div class="original-video">
<h2>Original video</h2>
<div class="original-preview">Click "Play & Start streamCapture" button to play video</div>
<h3>Info about original video:</h3>
<div class="original-info"></div>
</div>
<div class="video-frames">
<h2>Rendered VideoFrames</h2>
<div class="frames-preview">
<canvas></canvas>
</div>
<h3>Info about captured track's capabilities:</h3>
<div class="track-info"></div>
<div class="track-fps-info">FPS generated by MediaStreamTrackProcessor: <span class="track-fps"></span></div>
<div class="track-fps-info">number of requestVideoFrameCallback per second: <span class="callback-fps"></span></div>
</div>
</div>
<script type="text/javascript" src="https://unpkg.com/mediainfo.js"></script>
<script src="index.js"></script>
</body>