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
6310622b
Commit
6310622b
authored
Dec 13, 2011
by
Vladislav Vinogradov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
minor
parent
056d015b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
8 deletions
+11
-8
window_QT.cpp
modules/highgui/src/window_QT.cpp
+4
-1
point_cloud.cpp
samples/cpp/point_cloud.cpp
+7
-7
No files found.
modules/highgui/src/window_QT.cpp
View file @
6310622b
...
...
@@ -2311,6 +2311,7 @@ QWidget* DefaultViewPort::getWidget()
void
DefaultViewPort
::
setMouseCallBack
(
CvMouseCallback
m
,
void
*
param
)
{
on_mouse
=
m
;
on_mouse_param
=
param
;
}
...
...
@@ -3358,7 +3359,9 @@ void GlFuncTab_QT::generateBitmapFont(const std::string& family, int height, int
__BEGIN__
;
#ifndef Q_WS_WIN
glXUseXFont
(
font
.
handle
(),
start
,
count
,
base
);
font
.
setStyleStrategy
(
QFont
::
OpenGLCompatible
);
if
(
font
.
handle
())
glXUseXFont
(
font
.
handle
(),
start
,
count
,
base
);
#else
SelectObject
(
hDC
,
font
.
handle
());
if
(
!
wglUseFontBitmaps
(
hDC
,
start
,
count
,
base
))
...
...
samples/cpp/point_cloud.cpp
View file @
6310622b
...
...
@@ -27,7 +27,7 @@ public:
private
:
int
mouse_dx_
;
int
mouse_dy_
;
double
yaw_
;
double
pitch_
;
Point3d
pos_
;
...
...
@@ -35,7 +35,7 @@ private:
TickMeter
tm_
;
static
const
int
step_
;
int
frame_
;
GlCamera
camera_
;
GlArrays
pointCloud_
;
string
fps_
;
...
...
@@ -189,7 +189,7 @@ int main(int argc, const char* argv[])
namedWindow
(
windowName
,
WINDOW_OPENGL
);
resizeWindow
(
windowName
,
400
,
400
);
PointCloudRenderer
renderer
(
points
,
imgLeftColor
,
scale
);
createTrackbar
(
"Fov"
,
windowName
,
&
renderer
.
fov_
,
100
);
...
...
@@ -198,7 +198,7 @@ int main(int argc, const char* argv[])
while
(
true
)
{
int
key
=
waitKey
(
1
);
int
key
=
waitKey
(
1
0
);
if
(
key
>=
0
)
key
=
key
&
0xff
;
...
...
@@ -302,9 +302,9 @@ void PointCloudRenderer::update(int key, double aspect)
const
Point3d
leftVec
(
-
1.0
,
0.0
,
0.0
);
const
double
posStep
=
0.1
;
const
double
mouseStep
=
0.001
;
camera_
.
setPerspectiveProjection
(
30.0
+
fov_
/
100.0
*
40.0
,
aspect
,
0.1
,
1000.0
);
yaw_
+=
mouse_dx_
*
mouseStep
;
...
...
@@ -332,7 +332,7 @@ void PointCloudRenderer::update(int key, double aspect)
ostringstream
ostr
;
ostr
<<
"FPS: "
<<
step_
/
tm_
.
getTimeSec
();
fps_
=
ostr
.
str
();
frame_
=
0
;
tm_
.
reset
();
}
...
...
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