Toggle navigation
Toggle navigation
This project
Loading...
Sign in
2020-2-capstone-design2
/
2014104149
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
Graduate
2020-11-23 17:58:05 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
f431fba3054802798a4bd77a4db311b9e55a000f
f431fba3
1 parent
500c5fba
commit
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
3 deletions
flask/templates/index.html
flask/templates/index.html
View file @
f431fba
...
...
@@ -30,7 +30,7 @@
</div>
<script
type=
'text/javascript'
src=
{{url_for('static',
filename=
'js/opencv.js'
)}}
>
<
script
type
=
'text/javascript'
>
let
video
=
document
.
getElementById
(
'videoElement'
);
var
video
=
document
.
querySelector
(
"#videoElement"
);
if
(
navigator
.
mediaDevices
.
getUserMedia
){
navigator
.
mediaDevices
.
getUserMedia
({
video
:
true
})
.
then
(
function
(
stream
)
{
...
...
@@ -41,6 +41,7 @@ if (navigator.mediaDevices.getUserMedia){
}
</script>
<script>
let
video
=
document
.
getElementById
(
'videoElement'
);
let
src
=
new
cv
.
Mat
(
video
.
height
,
video
.
width
,
cv
.
CV_8UC4
);
let
dst
=
new
cv
.
Mat
(
video
.
height
,
video
.
width
,
cv
.
CV_8UC4
);
let
gray
=
new
cv
.
Mat
();
...
...
@@ -81,8 +82,9 @@ if (navigator.mediaDevices.getUserMedia){
utils
.
printError
(
err
);
}
};
// schedule the first one.
setTimeout
(
processVideo
,
0
);
// schedule the first one.
setTimeout
(
processVideo
,
0
);
</script>
</body>
</html>
...
...
Please
register
or
login
to post a comment