aboutsummaryrefslogtreecommitdiff
path: root/src/labeller.h
diff options
context:
space:
mode:
authorYour Name <you@example.com>2021-08-17 08:56:06 -0400
committerYour Name <you@example.com>2021-08-17 08:56:06 -0400
commit8a6b5564c0fc37e6e556d04e17ddba86d4bd3dc1 (patch)
tree238d013eb3cfe2dc170a52dec3bfcd72a1e468ca /src/labeller.h
parent8c884838ced928d29a8436be8b2808766c5a1e53 (diff)
downloadannotator-8a6b5564c0fc37e6e556d04e17ddba86d4bd3dc1.tar.gz
annotator-8a6b5564c0fc37e6e556d04e17ddba86d4bd3dc1.tar.bz2
annotator-8a6b5564c0fc37e6e556d04e17ddba86d4bd3dc1.zip
Started work on bounding boxes
Diffstat (limited to 'src/labeller.h')
-rw-r--r--src/labeller.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/labeller.h b/src/labeller.h
index 4248e2a..e0dc090 100644
--- a/src/labeller.h
+++ b/src/labeller.h
@@ -8,11 +8,16 @@
namespace backend {
struct labeller_impl;
+ struct rect {
+ int x1=0, x2=0, y1=0, y2=0;
+ };
+
struct label {
label() {}
label(const std::string& name, double time) : name(name), time(time) {}
std::string name;
double time;
+ rect location;
};
class labeller {
@@ -20,6 +25,7 @@ namespace backend {
labeller(const std::filesystem::path& savepath);
std::pair<label, label> getSurrounding(double time) const;
std::vector<std::string> getLabels() const;
+ std::vector<std::string> getRectangleLabels() const;
void applyLabel(std::string name, double time);
void deleteLabel(double time); // Deletes closest to time, last added if ties
void undo();