Skip to content

Commit 5f6bb1d

Browse files
authored
Face detection resolution and Quality control quality improvements (#109)
* Update UI to allow face detection enabling for CIF mode Unexpected consequence of the changes addressed in #98 * Changed the UI labelling for the 'quality' slider to just say 'High (slow)' and 'Low (fast)', much more comprehensible, thanks @TungstenE2 I also allow the slider to go to '6' instead of '10' for the OV2640
1 parent f97d56e commit 5f6bb1d

File tree

3 files changed

+12
-12
lines changed

3 files changed

+12
-12
lines changed

index_other.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ const uint8_t index_simple_html[] = R"=====(<!doctype html>
270270
271271
framesize.onchange = () => {
272272
updateConfig(framesize)
273-
if (framesize.value > 5) {
273+
if (framesize.value > 6) {
274274
updateValue(detect, false)
275275
updateValue(recognize, false)
276276
}

index_ov2640.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -68,11 +68,11 @@ const uint8_t index_ov2640_html[] = R"=====(<!doctype html>
6868
</div>
6969
<div class="input-group" id="quality-group">
7070
<label for="quality">Quality</label>
71-
<div class="range-min">63</div>
71+
<div class="range-min">Low<br><span style="font-size: 80%;">(fast)</span></div>
7272
<!-- Note; the following element is 'flipped' in CSS so that it slides from High to Low
7373
As a result the 'min' and 'max' values are reversed here too -->
74-
<input type="range" id="quality" min="10" max="63" value="10" class="default-action" title="Lower is Better">
75-
<div class="range-max">10</div>
74+
<input type="range" id="quality" min="6" max="63" value="10" class="default-action">
75+
<div class="range-max">High<br><span style="font-size: 80%;">(slow)</span></div>
7676
</div>
7777
<div class="input-group" id="brightness-group">
7878
<label for="brightness">Brightness</label>
@@ -572,14 +572,14 @@ const uint8_t index_ov2640_html[] = R"=====(<!doctype html>
572572

573573
framesize.onchange = () => {
574574
updateConfig(framesize)
575-
if (framesize.value > 5) {
575+
if (framesize.value > 6) {
576576
updateValue(detect, false)
577577
updateValue(recognize, false)
578578
}
579579
}
580580

581581
detect.onchange = () => {
582-
if (framesize.value > 5) {
582+
if (framesize.value > 6) {
583583
alert("Please select CIF or lower resolution before enabling this feature!");
584584
updateValue(detect, false)
585585
return;
@@ -592,7 +592,7 @@ const uint8_t index_ov2640_html[] = R"=====(<!doctype html>
592592
}
593593

594594
recognize.onchange = () => {
595-
if (framesize.value > 5) {
595+
if (framesize.value > 6) {
596596
alert("Please select CIF or lower resolution before enabling this feature!");
597597
updateValue(recognize, false)
598598
return;

index_ov3660.h

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -70,11 +70,11 @@ const uint8_t index_ov3660_html[] = R"=====(<!doctype html>
7070
</div>
7171
<div class="input-group" id="quality-group">
7272
<label for="quality">Quality</label>
73-
<div class="range-min">63</div>
73+
<div class="range-min">Low<br><span style="font-size: 80%;">(fast)</span></div>
7474
<!-- Note; the following element is 'flipped' in CSS so that it slides from High to Low
7575
As a result the 'min' and 'max' values are reversed here too -->
7676
<input type="range" id="quality" min="4" max="63" value="10" class="default-action">
77-
<div class="range-max">4</div>
77+
<div class="range-max">High<br><span style="font-size: 80%;">(slow)</span></div>
7878
</div>
7979
<div class="input-group" id="brightness-group">
8080
<label for="brightness">Brightness</label>
@@ -580,14 +580,14 @@ const uint8_t index_ov3660_html[] = R"=====(<!doctype html>
580580

581581
framesize.onchange = () => {
582582
updateConfig(framesize)
583-
if (framesize.value > 5) {
583+
if (framesize.value > 6) {
584584
updateValue(detect, false)
585585
updateValue(recognize, false)
586586
}
587587
}
588588

589589
detect.onchange = () => {
590-
if (framesize.value > 5) {
590+
if (framesize.value > 6) {
591591
alert("Please select CIF or lower resolution before enabling this feature!");
592592
updateValue(detect, false)
593593
return;
@@ -600,7 +600,7 @@ const uint8_t index_ov3660_html[] = R"=====(<!doctype html>
600600
}
601601

602602
recognize.onchange = () => {
603-
if (framesize.value > 5) {
603+
if (framesize.value > 6) {
604604
alert("Please select CIF or lower resolution before enabling this feature!");
605605
updateValue(recognize, false)
606606
return;

0 commit comments

Comments
 (0)