new training guide (#20495)

* new training guide

* fix end

* new step1

* better images

* update images
old-commit-hash: fd15a21c5a6b45e531820cd70f2e6fe77e2dbfad
This commit is contained in:
Adeeb Shihadeh
2021-03-26 16:43:14 -07:00
committed by GitHub
parent c9bc21d358
commit d82d87c9d6
35 changed files with 81 additions and 56 deletions

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:8c6c04843346495360f87d7378f6b92d1284f26876e4c61772391c4239eabb9a
size 187644

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:a43db34dab4c2f529c43c3f072ea28a3b7c05989151845035f320181d152ee4d
size 1617839

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e7ad4506e6e81e7b374676767be0037b1d27a5a6ba7e2354a639fe72510621c7
size 251834

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:a1cbb6cdc922e0ac1627f2ef8cd555d43558054b67bf5ad5481726d7bc63a644
size 47671

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:25b8ed39ca149b5083c61765951cef34ebbd94ed70d6111250f1f21f89c92170
size 263592

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:4668a60cf8a810d04412730d77703148d632a9634e5dbc3931e67869edb19991
size 50707

Binary file not shown.

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:75e6105ba9a4cab7e403a7b69ec6f7dcaf4c3ba9b89f00a42c6b7d871d70d0f5
size 761149

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:de067b0da7f676428a82d445a29d386f135081c53fd6203437bc7abeef941301
size 297138

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:4a912f9bfc189af20b3ff06eb4ab29d60e0670409f6fa3c01aaf0f20386fa590
size 33840

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:3a89702a4b25a5dd8431689cb06125780c30642613ac11d88dd245e1e8924cd7
size 376601

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:e5b3f1e292b211f062a8dd556cb067e9674af439938230ce3199081d7f67fa4e
size 1169995

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:c9f2b6fa133b102f2008a60dda0b344826ecfa57127ba43c7551d14c1b213d3b
size 234676

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:a985bed14a45c66cc5e4301471e8d250de2394b780bdd1effa17d63575afff6c
size 724946

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:74c839c01695eb33a5bab34b3d979136d922ce0ce829d82cbc029ce231b97f9b
size 33355

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:2ac7d714a352b6d4664622c35a6d34d669eaa344b7cdf991e51592425b3b1d58
size 40061

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:b034c0a336e713cba54f312dd1817815f19a7983abfe2b67a29914e7e18d4db6
size 1968469

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:bd1b7ea05bdadba70f1aa12af9e044224ff751a9feb7336b0868dda99876c4ae
size 199105

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:af9942d842bce44d504a646d13071c189c212a79f8c408cb56f48a02422fb557
size 34188

Binary file not shown.

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:7f7010ad364f32df28adb5e138c503ee34392a53ed82eed13a183edabf127160
size 569757

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:10cc7c1a0515dcef8ae840d8d18cdfb6b60cbede409d25cfc8375c190763d7bc
size 269618

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:786ad8a8ea098f35c31d3b521d1a196e89c04f0deb99959f1a5dd8e46f8e21e4
size 536899

Binary file not shown.

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:34fe0494fba5cb9426341794a0615b1cd33a3fb9ec777093900a9fbee3611e47
size 39582

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:0d67cbc355c1f22e0ce20ff952a02df9b238774ebaf3076acfcc0f10944779aa
size 257768

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:365823c1c76e3d2825820ac08b7ffde59444362fff2cb1262352fde63e614a93
size 1054999

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:21de74ca3ca3723c8d9e8e8671f07fede2a444c4ad1aeeb53dd91d25175a0d70
size 294373

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:90cfe2fd3a2a6b759f4e5e683d6326ad1d1bcc10026597f74af5e63e351a6c18
size 735245

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:441de6705aba7218327cb49866bf00927d2d8b6b724e91c9006b20a88f32c71a
size 216384

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:090c308a382241ba0457049eab32fb169e1624b5581b188975b9b94306e06efc
size 660937

View File

@@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:8a7bfa7d4f48753409dd125d6a48b6b2d7e42a62b4b6fb1f2a7f5f11b212665a
size 200923

View File

@@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:6797a3b3d6d7ed36b045b1cd96847be886e0be5c5483f8ac9e13dc937a3aa8fa
size 705045

View File

@@ -12,30 +12,28 @@
void TrainingGuide::mouseReleaseEvent(QMouseEvent *e) {
int leftOffset = (geometry().width()-1620)/2;
int mousex = e->x()-leftOffset;
int mousey = e->y();
//qDebug() << e->x() << ", " << e->y();
// Check for restart
if (currentIndex == (boundingBox.size() - 1) && 1050 <= mousex && mousex <= 1500 &&
773 <= mousey && mousey <= 954) {
if (currentIndex == (boundingBox.size() - 1) && 200 <= e->x() && e->x() <= 920 &&
760 <= e->y() && e->y() <= 960) {
currentIndex = 0;
} else if (boundingBox[currentIndex][0] <= mousex && mousex <= boundingBox[currentIndex][1] &&
boundingBox[currentIndex][2] <= mousey && mousey <= boundingBox[currentIndex][3]) {
} else if (boundingBox[currentIndex][0] <= e->x() && e->x() <= boundingBox[currentIndex][1] &&
boundingBox[currentIndex][2] <= e->y() && e->y() <= boundingBox[currentIndex][3]) {
currentIndex += 1;
}
if (currentIndex >= boundingBox.size()) {
emit completedTraining();
} else {
image.load("../assets/training/step" + QString::number(currentIndex) + ".jpg");
image.load("../assets/training/step" + QString::number(currentIndex) + ".png");
update();
}
}
void TrainingGuide::showEvent(QShowEvent *event) {
currentIndex = 0;
image.load("../assets/training/step0.jpg");
image.load("../assets/training/step0.png");
}
void TrainingGuide::paintEvent(QPaintEvent *event) {

View File

@@ -26,8 +26,26 @@ private:
// Bounding boxes for the a given training guide step
// (minx, maxx, miny, maxy)
QVector<QVector<int>> boundingBox {{250, 930, 750, 900}, {280, 1280, 650, 950}, {330, 1130, 590, 900}, {910, 1580, 500, 1000}, {1180, 1300, 630, 720}, {290, 1050, 590, 960},
{1090, 1240, 550, 660}, {1050, 1580, 250, 900}, {320, 1130, 670, 1020}, {1010, 1580, 410, 750}, {1040, 1500, 230, 1030}, {300, 1190, 590, 920}, {1050, 1310, 170, 870}, {950, 1530, 460, 770}, {190, 970, 750, 970}};
QVector<QVector<int>> boundingBox {
{650, 1375, 700, 900},
{1600, 1920, 0, 1080},
{1600, 1920, 0, 1080},
{1240, 1750, 480, 1080},
{1570, 1780, 620, 750},
{1600, 1920, 0, 1080},
{1630, 1740, 620, 780},
{1200, 1920, 0, 1080},
{1455, 1850, 400, 660},
{1460, 1800, 195, 520},
{1600, 1920, 0, 1080},
{1350, 1920, 65, 1080},
{1600, 1920, 0, 1080},
{1570, 1900, 130, 1000},
{1350, 1770, 500, 700},
{1600, 1920, 0, 1080},
{1600, 1920, 0, 1080},
{1000, 1800, 760, 954},
};
signals:
void completedTraining();