Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
19ccde25
Commit
19ccde25
authored
Oct 17, 2002
by
Sam Hocevar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* ./modules/video_output/directx/events.c: mouse coordinates support for
the DirectX plugin (please test compilation).
parent
65c29155
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
1 deletion
+23
-1
modules/video_output/directx/events.c
modules/video_output/directx/events.c
+23
-1
No files found.
modules/video_output/directx/events.c
View file @
19ccde25
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
* events.c: Windows DirectX video output events handler
* events.c: Windows DirectX video output events handler
*****************************************************************************
*****************************************************************************
* Copyright (C) 2001 VideoLAN
* Copyright (C) 2001 VideoLAN
* $Id: events.c,v 1.
3 2002/10/06 19:28:28 gbazin
Exp $
* $Id: events.c,v 1.
4 2002/10/17 16:56:52 sam
Exp $
*
*
* Authors: Gildas Bazin <gbazin@netcourrier.com>
* Authors: Gildas Bazin <gbazin@netcourrier.com>
*
*
...
@@ -65,6 +65,8 @@ void DirectXEventThread( event_thread_t *p_event )
...
@@ -65,6 +65,8 @@ void DirectXEventThread( event_thread_t *p_event )
{
{
MSG
msg
;
MSG
msg
;
POINT
old_mouse_pos
;
POINT
old_mouse_pos
;
vlc_value_t
val
;
int
i_width
,
i_height
,
i_x
,
i_y
;
/* Initialisation */
/* Initialisation */
...
@@ -94,6 +96,21 @@ void DirectXEventThread( event_thread_t *p_event )
...
@@ -94,6 +96,21 @@ void DirectXEventThread( event_thread_t *p_event )
case
WM_NCMOUSEMOVE
:
case
WM_NCMOUSEMOVE
:
case
WM_MOUSEMOVE
:
case
WM_MOUSEMOVE
:
vout_PlacePicture
(
p_event
->
p_vout
,
p_event
->
p_vout
->
p_sys
->
i_window_width
,
p_event
->
p_vout
->
p_sys
->
i_window_height
,
&
i_x
,
&
i_y
,
&
i_width
,
&
i_height
);
val
.
i_int
=
(
GET_X_LPARAM
(
msg
.
lParam
)
-
i_x
)
*
p_event
->
p_vout
->
render
.
i_width
/
i_width
;
var_Set
(
p_event
->
p_vout
,
"mouse-x"
,
val
);
val
.
i_int
=
(
GET_Y_LPARAM
(
msg
.
lParam
)
-
i_y
)
*
p_event
->
p_vout
->
render
.
i_height
/
i_height
;
var_Set
(
p_event
->
p_vout
,
"mouse-y"
,
val
);
val
.
b_bool
=
VLC_TRUE
;
var_Set
(
p_event
->
p_vout
,
"mouse-moved"
,
val
);
if
(
(
abs
(
GET_X_LPARAM
(
msg
.
lParam
)
-
old_mouse_pos
.
x
)
>
2
||
if
(
(
abs
(
GET_X_LPARAM
(
msg
.
lParam
)
-
old_mouse_pos
.
x
)
>
2
||
(
abs
(
GET_Y_LPARAM
(
msg
.
lParam
)
-
old_mouse_pos
.
y
))
>
2
)
)
(
abs
(
GET_Y_LPARAM
(
msg
.
lParam
)
-
old_mouse_pos
.
y
))
>
2
)
)
{
{
...
@@ -126,6 +143,11 @@ void DirectXEventThread( event_thread_t *p_event )
...
@@ -126,6 +143,11 @@ void DirectXEventThread( event_thread_t *p_event )
}
}
break
;
break
;
case
WM_LBUTTONUP
:
var
.
b_bool
=
VLC_TRUE
;
var_Set
(
p_event
->
p_vout
,
"mouse-clicked"
,
val
);
break
;
case
WM_LBUTTONDOWN
:
case
WM_LBUTTONDOWN
:
break
;
break
;
...
...
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