-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
116 lines (102 loc) · 5.44 KB
/
index.html
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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
<!--
MIT License
Copyright (c) 2023 Rohsin Al Razi
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
-->
<!DOCTYPE html>
<html lang="en">
<head>
<title>Machine Vision</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@4.6.1/dist/css/bootstrap.min.css">
<script src="https://cdn.jsdelivr.net/npm/jquery@3.6.0/dist/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/popper.js@1.16.1/dist/umd/popper.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@4.6.1/dist/js/bootstrap.bundle.min.js"></script>
</head>
<body>
<nav class="navbar navbar-expand-md bg-dark navbar-dark">
<a class="navbar-brand" href="#">
<img src="logo.png" style="max-width: 120px">
</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#collapsibleNavbar">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="collapsibleNavbar">
<ul class="navbar-nav">
<li class="nav-item">
<a class="nav-link" href="https://github.com/wEbCoAdEr/MachineVision">Github Repository</a>
</li>
</ul>
</div>
</nav>
<div class="container">
<div class="row" style="margin-top: 20px">
<div style="margin-bottom: 20px" class="col-md-8 offset-md-2">
<div class="card scanResultCard" style="display: none">
<div class="card-header bg-dark text-white"><b>SCAN RESULT</b></div>
<div class="card-body" style="padding: 0">
<table class="table table-bordered table-striped table-hover" style="margin-bottom: 0">
<thead>
<tr>
<th>OBJECT</th>
<th>TOTAL COUNT</th>
</tr>
</thead>
<tbody class="scanResultTableBody">
</tbody>
</table>
<canvas id="output_image_canvas" style="background-repeat: no-repeat;
background-size: cover; max-width: 100%;"></canvas>
</div>
</div>
</div>
<div style="margin-bottom: 20px" class="col-md-8 offset-md-2">
<div class="card">
<div class="card-header bg-dark text-white"><b>SELECT IMAGE</b></div>
<div class="card-body">
<p class="lead">Select a PNG or JPEG image, having maximum size <span id="max-size"></span> KB.</p>
<form id="upload-image-form" action="" method="post" enctype="multipart/form-data">
<div class="alert alert-info" id="loading" style="display: none;" role="alert">
Uploading image...
<div class="progress">
<div class="progress-bar progress-bar-striped active" role="progressbar" aria-valuenow="45" aria-valuemin="0" aria-valuemax="100" style="width: 100%">
</div>
</div>
</div>
<br>
<div id="image-preview-div" style="display: none">
<label for=""><b>SELECTED IMAGE</b></label>
<br>
<img id="preview-img" class="img-fluid" style="width: 100%" src="noimage">
</div>
<div class="form-group">
<input type="file" name="image" id="file" required>
</div>
<div class="form-group">
<button class="btn btn-primary form-control" id="upload-button" type="submit" disabled>SCAN
IMAGE
</button>
</div>
</form>
</div>
</div>
</div>
</div>
</div>
<script src="script.js"></script>
</body>
</html>