From 2f267859fde4f65809074e568dae21d453e3b930 Mon Sep 17 00:00:00 2001 From: Slider0007 Date: Mon, 7 Oct 2024 19:33:28 +0200 Subject: [PATCH] Update --- sd-card/html/edit_sequence.html | 68 ++++++++++++++++++--------------- 1 file changed, 37 insertions(+), 31 deletions(-) diff --git a/sd-card/html/edit_sequence.html b/sd-card/html/edit_sequence.html index 983893b78..a41d11af5 100644 --- a/sd-card/html/edit_sequence.html +++ b/sd-card/html/edit_sequence.html @@ -103,36 +103,32 @@

Number Sequences

ROI Configuration

- Region Of Interest (ROI) for digit numbers can be defined on this page. If no digit number - needs to be processed, disable digit number processing by deselecting "Digit ROI Processing". + This page is dedicated to defining number sequences. Each number sequence consists of digital ROIs and/or analog + ROIs that are processed together. After defining the number sequence, you need to specify the corresponding digit + and/or analog Region Of Interest (ROI). These ROIs are processed by the algorithm to digitize + the content.
+ By default, one number sequence ("main") is already predefined and selected in the Number Sequence dropdown. + If additional number sequences are required, they can be added using the buttons next to the dropdown.

- By default one number sequence (a number seqence contains of digit ROIs and/or analog counter ROIs which are - processed together) is predefined and already selected in the drop down "Number Sequence". If more than - one number sequence is needed additional one's can be added with the buttons next to the drop down. Each number - sequence will be processed separately. + The ROI type can be switched using the Digit ROI / Analog ROI selection box. Individual ROIs in the selected + number sequence can be toggled using the selection box next to the ROI type selector.
+ To create new ROIs, click New. The new ROI will automatically be assigned a unique name in ascending order + based on the type selected (dig1, dig2, ... / ana1, ana2, ...). Deleting an ROI from the existing ones will + rename the remaining ROIs in ascending order, without leaving any gaps.
+ + ROIs can be positioned either by dragging and dropping with the mouse or by manually entering parameters into the + designated fields. For accurate ROI placement and sizing, please consult the documentation thoroughly, as precise + configurations are essential for reliable processing: + ROI Configuration.
+ The order of the ROIs determines their position (and thus the multiplication factor) within the number sequence. + The position in the sequence can be changed using the Move Lower and Move Higher buttons. Below + the selection boxes, the resulting multiplication factors are displayed: one based solely on the position/order + in the number sequence, and another adjusted by the decimal shift setting (Parameter: Decimal Shift, default: 0).

- Using drag and drop by mouse of by manually entering the parameters into the given fields the digit ROIs can be - positined to the digit numbers on the reference image. To have proper ROI placement and sizes please check the - documentation in detail because it's very important to be really precise to have reliable processing: - ROI Configuration. - With the drop down "ROI" the different ROIs in the respective number sequence can be selected.
- - To create new ROIs use "New ROI". The new ROIs are automatically named uniquely and in ascending order - (e.g. dig1, dig2, ...). Deleting a ROI between exisitung ones will rename the remaining ROIs in ascending order - without keeping any naming gap. -

-

- The order of the ROI defines the position (and therefore the multiplication factor) within the number sequence. - The position in the number sequence can be changed with the buttons "Move Lower" and "Move Higher". - The multiplication factor which is shown below the ROI drop down is the multiplication factor of pure position/order - in number sequence and the factor right-hand side to this is the additionally corrected by decimal shift setting - (expert parameter: Decimal Shift, default: 0). -

-

- After the definition of digit ROIs is completed don't forget to save the new configuration with the button - "Save And Apply". The new configuration gets automatically applied. No reboot is required. + Once the sequences and ROIs are defined, don't forget to save the new configuration by clicking the Save And Apply + button. The new configuration will be applied automatically, and no reboot is required.


@@ -348,6 +344,7 @@

Number Sequences

RefreshROI(); parseROIArrangement(); + onTypeChanged(); } @@ -376,6 +373,7 @@

Number Sequences

RefreshROI(); parseROIArrangement(); + onTypeChanged(); } @@ -587,9 +585,14 @@

Number Sequences

{ for (i = 0; i < jsonConfigModifiedDelta[type]["sequence"].length; ++i) { if (jsonConfigModifiedDelta[type]["sequence"][i]["sequencename"] == sequenceName) { - jsonConfigModifiedDelta[type]["sequence"][i]["roi"].push({"x": parseInt(x), - "y": parseInt(y), "dx": parseInt(dx), "dy": parseInt(dy), "ccw": false, "ar": dx/dy}); - + if (typeSelection.value == "digit") { + jsonConfigModifiedDelta[type]["sequence"][i]["roi"].push({"x": parseInt(x), + "y": parseInt(y), "dx": parseInt(dx), "dy": parseInt(dy), "ar": dx/dy}); + } + else if (typeSelection.value == "analog") { + jsonConfigModifiedDelta[type]["sequence"][i]["roi"].push({"x": parseInt(x), + "y": parseInt(y), "dx": parseInt(dx), "dy": parseInt(dy), "ccw": false, "ar": dx/dy}); + } return ""; } } @@ -993,8 +996,6 @@

Number Sequences

document.getElementById("lockSizesDigit").checked = lockSizeDigit; document.getElementById("lockSizesAnalog").checked = lockSizeAnalog; - document.getElementById("CCW").checked = jsonConfigModifiedDelta.analog.sequence[sequenceSelection.selectedIndex].roi[roiSelected].ccw; - document.getElementById("lockSpaceEquidistant").checked = lockSpaceEquidistant; document.getElementById("space").disabled = !lockSpaceEquidistant; document.getElementById("space").value = space; @@ -1003,6 +1004,11 @@

Number Sequences

rect.startY = document.getElementById("refy").value = jsonConfigModifiedDelta[typeSelection.value].sequence[sequenceSelection.selectedIndex].roi[roiSelected].y; rect.w = document.getElementById("refdx").value = jsonConfigModifiedDelta[typeSelection.value].sequence[sequenceSelection.selectedIndex].roi[roiSelected].dx; rect.h = document.getElementById("refdy").value = jsonConfigModifiedDelta[typeSelection.value].sequence[sequenceSelection.selectedIndex].roi[roiSelected].dy; + + if (typeSelection.value == "analog") { + document.getElementById("CCW").checked = jsonConfigModifiedDelta.analog.sequence[sequenceSelection.selectedIndex].roi[roiSelected].ccw; + } + RefreshDraw(); }