Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
c622ebf8
Commit
c622ebf8
authored
Jun 10, 2013
by
Anatoly Baksheev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
implemented wasStopped flag
parent
0f5da429
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
9 deletions
+11
-9
viz3d.hpp
modules/viz/include/opencv2/viz/viz3d.hpp
+6
-5
viz3d.cpp
modules/viz/src/viz3d.cpp
+3
-2
test_viz3d.cpp
modules/viz/test/test_viz3d.cpp
+2
-2
No files found.
modules/viz/include/opencv2/viz/viz3d.hpp
View file @
c622ebf8
...
...
@@ -26,8 +26,8 @@ namespace temp_viz
void
setBackgroundColor
(
const
Color
&
color
=
Color
::
black
());
void
addCoordinateSystem
(
double
scale
,
const
Affine3f
&
t
,
const
String
&
id
=
"coordinate"
);
void
showPointCloud
(
const
String
&
id
,
InputArray
cloud
,
InputArray
colors
,
const
Affine3f
&
pose
=
Affine3f
::
Identity
());
void
showPointCloud
(
const
String
&
id
,
InputArray
cloud
,
InputArray
colors
,
const
Affine3f
&
pose
=
Affine3f
::
Identity
());
bool
addPointCloudNormals
(
const
Mat
&
cloud
,
const
Mat
&
normals
,
int
level
=
100
,
float
scale
=
0.02
f
,
const
String
&
id
=
"cloud"
);
...
...
@@ -51,10 +51,11 @@ namespace temp_viz
void
spin
();
void
spinOnce
(
int
time
=
1
,
bool
force_redraw
=
false
);
void
registerKeyboardCallback
(
void
(
*
callback
)(
const
cv
::
KeyboardEvent
&
,
void
*
),
void
*
cookie
=
0
);
void
registerMouseCallback
(
void
(
*
callback
)(
const
cv
::
MouseEvent
&
,
void
*
),
void
*
cookie
=
0
);
void
registerKeyboardCallback
(
void
(
*
callback
)(
const
cv
::
KeyboardEvent
&
,
void
*
),
void
*
cookie
=
0
);
void
registerMouseCallback
(
void
(
*
callback
)(
const
cv
::
MouseEvent
&
,
void
*
),
void
*
cookie
=
0
);
bool
wasStopped
()
const
;
private
:
Viz3d
(
const
Viz3d
&
);
Viz3d
&
operator
=
(
const
Viz3d
&
);
...
...
modules/viz/src/viz3d.cpp
View file @
c622ebf8
...
...
@@ -96,4 +96,6 @@ void temp_viz::Viz3d::registerKeyboardCallback(void (*callback)(const cv::Keyboa
void
temp_viz
::
Viz3d
::
registerMouseCallback
(
void
(
*
callback
)(
const
cv
::
MouseEvent
&
,
void
*
),
void
*
cookie
)
{
impl_
->
registerMouseCallback
(
callback
,
cookie
);
}
\ No newline at end of file
}
bool
temp_viz
::
Viz3d
::
wasStopped
()
const
{
return
impl_
->
wasStopped
();
}
modules/viz/test/test_viz3d.cpp
View file @
c622ebf8
...
...
@@ -90,7 +90,7 @@ TEST(Viz_viz3d, accuracy)
v
.
addPolygonMesh
(
*
mesh
,
"pq"
);
while
(
1
)
//TODO implement and replace with !viz.wasStopped(
)
while
(
!
v
.
wasStopped
()
)
{
// Creating new point cloud with id cloud1
cv
::
Affine3f
cloudPosition
(
angle_x
,
angle_y
,
angle_z
,
cv
::
Vec3f
(
pos_x
,
pos_y
,
pos_z
));
...
...
@@ -103,7 +103,7 @@ TEST(Viz_viz3d, accuracy)
pos_y
=
std
::
sin
(
angle_x
);
pos_z
=
std
::
sin
(
angle_x
);
v
.
spinOnce
(
1
0
);
v
.
spinOnce
(
1
,
true
);
}
// cv::Mat normals(cloud.size(), CV_32FC3, cv::Scalar(0, 10, 0));
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment