-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathindex.html
265 lines (219 loc) · 13 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
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
<!doctype html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<title>Image Editor</title>
<link rel="icon" href="img/favicon.png">
<link rel="stylesheet" href="css/bootstrap.min.css">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link rel="stylesheet" href="css/main.css">
</head>
<body>
<!-- MODALS -->
<div class="modal fade" id="morphModal" tabindex="-1" role="dialog" aria-labelledby="modalCenterTitle" aria-hidden="true">
<div class="modal-dialog modal-dialog-centered" role="document">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="modalCenterTitle">Morphological options*</h5>
<a href="#" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">×</span>
</a>
</div>
<div class="modal-body">
<div class="form-group">
<label for="kerShape">Transform Type</label>
<select class="custom-select" id="morphType">
<option value="-1" selected>Select the type of operation</option>
<option value="0">Erosion</option>
<option value="1">Dilation</option>
<option value="2">Opening</option>
<option value="3">Closing</option>
<option value="4">Morphologic Gradient</option>
<option value="5">Top Hat</option>
<option value="6">Black Hat</option>
</select>
<br><br>
<label for="kerSize">Kernel Size</label>
<input type="number" class="form-control" id="kerSize" min="1" max="40" value=1>
<br>
<label for="kerShape">Kernel Shape</label>
<select class="custom-select" id="kerShape">
<option value="-1" selected>Select the kernel shape</option>
<option value="0">Rect</option>
<option value="1">Crossed</option>
<option value="2">Ellipse</option>
</select>
</div>
</div>
<div class="modal-footer">
<p>Note: In order to perform the morphological operation, the image will be binarized first.</p>
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancel</button>
<button type="button" class="btn btn-primary" data-dismiss="modal" id="triggerMorphTransform">Apply</button>
</div>
</div>
</div>
</div>
<!-- MENU BARS? -->
<header>
<nav class="navbar navbar-light bg-light navbar-expand-md">
<!-- -->
<button class="navbar-toggler ml-auto" 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">
<!-- FILE SUBMENU -->
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="" data-toggle="dropdown">
File
</a>
<div class="dropdown-menu">
<!-- <div class="custom-file">
<input type="file" class="custom-file-input">
</div> -->
<input type="file" class="dropdown-item input-file" id="fileInput">
<label class="dropdown-item inp-file-label" for="fileInput">Upload image</label>
<a id="triggerDownload" class="dropdown-item" href="#" download>Salvar...</a>
</div>
</li>
<!-- FILTER SUBMENU -->
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="" data-toggle="dropdown">
Filters
</a>
<div class="dropdown-menu">
<a class="dropdown-item" href="#" id="triggerBlur">Blur</a>
<a class="dropdown-item" href="#" id="triggerPixelize">Pixelize</a>
<a class="dropdown-item" href="#" id="triggerSepia">Sepia</a>
<a class="dropdown-item" href="#" id="triggerGrayScale">Gray Scale</a>
<a class="dropdown-item" href="#" id="triggerNegative">Negative</a>
<a class="dropdown-item" href="#" id="triggerCartoon">Cartoon</a>
</div>
</li>
<!-- BINARIZATION SUBMENU -->
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="" data-toggle="dropdown">
Binarization
</a>
<div class="dropdown-menu">
<a class="dropdown-item" href="#" id="triggerTresh">Thresholding</a>
<a class="dropdown-item" href="#" id="triggerLaplace">Laplace</a>
<a class="dropdown-item" href="#" id="triggerSobel">Sobel</a>
<a class="dropdown-item" href="#" id="triggerCanny">Canny Edge Detection</a>
</div>
</li>
<!-- COLOR SUBMENU -->
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="" data-toggle="dropdown">
Color
</a>
<div class="dropdown-menu">
<a class="dropdown-item disabled" href="#" id="triggerBrightness">Brightness</a>
<a class="dropdown-item disabled" href="#" id="triggerContrast">Contrast</a>
<a class="dropdown-item disabled" href="#" id="triggerSaturation">Saturation</a>
</div>
</li>
<!-- MORPHOLOGICAL OPERATIONS -->
<!-- <li class="nav-item dropdown"> -->
<a class="nav-link" href="#" id="" data-toggle="modal" data-target="#morphModal">
Morphological Operations
</a>
<!-- </li> -->
</ul>
</div>
</nav>
</header>
<!-- MAIN -->
<main class="container-fluid">
<div class="row">
<div class="col-md-1 tool-box shadow-sm bg-white rounded">
<div class="row">
<a href="#" class="col-md-4 offset-md-3 btn btn-outline-secondary icon" id="triggerPen" data-toggle="tooltip" data-placement="right" title="Pen">
<i class="material-icons">
edit
</i>
</a>
<a href="#" class="col-md-4 offset-md-3 btn btn-outline-secondary icon" id="btnResizeImg" data-toggle="tooltip" data-placement="right" title="Resize">
<i class="material-icons">
crop_free
</i>
</a>
<a href="#" class="col-md-4 offset-md-3 btn btn-outline-secondary icon" id="btnRotateImg" data-toggle="tooltip" data-placement="right" title="Rotate">
<i class="material-icons">
loop
</i>
</a>
<a href="#" class="col-md-4 offset-md-3 btn btn-outline-secondary icon" id="triggerCutImg" data-toggle="tooltip" data-placement="right" title="Cut Image">
<i class="material-icons">
crop
</i>
</a>
<a href="#" class="col-md-4 offset-md-3 btn btn-outline-secondary" id="triggerText" data-toggle="tooltip" data-placement="right" title="Put Text">
<i class="material-icons">
format_shapes
</i>
</a>
<a href="#" class="col-md-4 offset-md-3 btn btn-outline-secondary" id="triggerHorizontalFlip"data-toggle="tooltip" data-placement="right" title="Flip Horizontally">
<i class="material-icons">
flip
</i>
</a>
<a href="#" class="col-md-4 offset-md-3 btn btn-outline-secondary" id="triggerVerticalFlip"data-toggle="tooltip" data-placement="right" title="Flip Vertically">
<i class="material-icons v">
flip
</i>
</a>
<input class="icon col-md-4 offset-md-3 btn btn-outline-secondary jscolor" id="penColor" data-toggle="tooltip" data-placement="left" title="Choose color" value="fff">
<div class="col-md-9" id="penSize">
<input type="text" class="form-control" id="size" value="5">
<input type="range" min="1" max="20" step="1" value = "5" class="custom-range" id="inputSize">
</div>
</div>
</div>
<div class="col-md-8 offset-md-1 out-img-container" id="outImgContainer">
<!-- <center> -->
<img id="inputImg" src=""></img>
<canvas class="output-img" id="outputImg"></canvas>
<!-- </center> -->
</div>
<div class="input-group col-md-5" id="textTool">
<div class="row meta-info">
<div class="col-md-5">
<input class="form-control form-control-sm" type="text" placeholder="Tamanho" id="textSize">
<input class="col-sm-2 btn btn-outline-secondary jscolor" id="textColor" data-toggle="tooltip" data-placement="right" title="" value="fff" data-original-title="Choose color">
<select class="custom-select custom-select-sm" id="fontFamily">
<option selected="">Fonte</option>
<option value="Comic Sans MS">Comic Sans MS</option>
<option value="Georgia">Georgia</option>
<option value="Book Antiqua">Book Antiqua</option>
<option value"Arial">Arial</option>
</select>
</div>
</div>
<div class="col-md-6">
<textarea rows = "3" cols="8" class="form-control" id="textContent" aria-describedby="meta-info"> </textarea>
</div>
</div>
</main>
<!-- SOME RANDOM THING -->
<!-- <footer class="shadow-sm bg-light">
<div class="container-fluid p-3 p-md-5">
<div class="col-md-12 col-sm-12">
<ul class = "bd-footer-links">
<li><a href="#">UFFS</a></li>
</ul>
<p>Currently beta v0.0.1.</p>
</div>
</div>
</footer> -->
<script src="js/jquery-3.3.1.min.js" charset="utf-8"></script>
<script src="js/bootstrap.bundle.min.js" charset="utf-8"></script>
<script src="js/utils.js" charset="utf-8"></script>
<script src="js/opencv.js" charset="utf-8" id="opencvJSFile"></script>
<script src="js/filters.js" charset="utf-8"></script>
<script src="js/tools.js" charset="utf-8"></script>
<script src="js/jscolor.js" charset="utf-8"></script>
<script src="js/main.js" charset="utf-8"></script>
</body>
</html>