Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
sample_tracker
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
bioroboticslab
biotracker
sample_tracker
Commits
ba45d8d6
Commit
ba45d8d6
authored
9 years ago
by
justayak
Browse files
Options
Downloads
Patches
Plain Diff
unify paints
parent
ee6d2306
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
SampleTracker.cpp
+6
-8
6 additions, 8 deletions
SampleTracker.cpp
SampleTracker.h
+1
-2
1 addition, 2 deletions
SampleTracker.h
with
7 additions
and
10 deletions
SampleTracker.cpp
+
6
−
8
View file @
ba45d8d6
...
@@ -65,8 +65,13 @@ void SampleTracker::track(ulong, const cv::Mat &imgOriginal) {
...
@@ -65,8 +65,13 @@ void SampleTracker::track(ulong, const cv::Mat &imgOriginal) {
_imageChanged
=
true
;
_imageChanged
=
true
;
}
}
void
SampleTracker
::
paint
(
ProxyPaintObject
&
p
,
const
View
&
view
)
{
void
SampleTracker
::
paint
(
ProxyPaintObject
&
p
,
QPainter
*
painter
,
const
View
&
view
)
{
if
(
view
.
name
!=
_currentView
||
_imageChanged
)
{
if
(
view
.
name
!=
_currentView
||
_imageChanged
)
{
painter
->
drawRoundRect
(
QRectF
(
QPointF
(
100
,
100
),
QPointF
(
1000
,
1000
)));
if
(
_showSelectorRec
)
{
drawRectangle
(
painter
);
}
_currentView
=
view
.
name
;
_currentView
=
view
.
name
;
// getting image object will force videoView to upload it to graphic mem
// getting image object will force videoView to upload it to graphic mem
...
@@ -81,13 +86,6 @@ void SampleTracker::paint(ProxyPaintObject &p , const View &view) {
...
@@ -81,13 +86,6 @@ void SampleTracker::paint(ProxyPaintObject &p , const View &view) {
}
}
}
}
void
SampleTracker
::
paintOverlay
(
QPainter
*
painter
)
{
painter
->
drawRoundRect
(
QRectF
(
QPointF
(
100
,
100
),
QPointF
(
1000
,
1000
)));
if
(
_showSelectorRec
)
{
drawRectangle
(
painter
);
}
}
//this will draw a basic rectangle
//this will draw a basic rectangle
void
SampleTracker
::
drawRectangle
(
QPainter
*
painter
)
{
void
SampleTracker
::
drawRectangle
(
QPainter
*
painter
)
{
QColor
color
(
Qt
::
cyan
);
QColor
color
(
Qt
::
cyan
);
...
...
This diff is collapsed.
Click to expand it.
SampleTracker.h
+
1
−
2
View file @
ba45d8d6
...
@@ -14,8 +14,7 @@ class SampleTracker : public TrackingAlgorithm {
...
@@ -14,8 +14,7 @@ class SampleTracker : public TrackingAlgorithm {
SampleTracker
(
Settings
&
settings
,
QWidget
*
parent
);
SampleTracker
(
Settings
&
settings
,
QWidget
*
parent
);
void
track
(
ulong
frameNumber
,
const
cv
::
Mat
&
frame
)
override
;
void
track
(
ulong
frameNumber
,
const
cv
::
Mat
&
frame
)
override
;
void
paint
(
ProxyPaintObject
&
,
View
const
&
view
=
OriginalView
)
override
;
void
paint
(
ProxyPaintObject
&
,
QPainter
*
,
View
const
&
view
=
OriginalView
)
override
;
void
paintOverlay
(
QPainter
*
painter
)
override
;
void
postConnect
()
override
;
void
postConnect
()
override
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment