Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
1426a88f
Commit
1426a88f
authored
Jun 20, 2008
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
skins2: use the vout window interface (untested)
parent
62148528
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
14 deletions
+40
-14
modules/gui/skins2/src/skin_main.cpp
modules/gui/skins2/src/skin_main.cpp
+33
-0
modules/gui/skins2/src/vlcproc.cpp
modules/gui/skins2/src/vlcproc.cpp
+5
-13
modules/gui/skins2/src/vlcproc.hpp
modules/gui/skins2/src/vlcproc.hpp
+2
-1
No files found.
modules/gui/skins2/src/skin_main.cpp
View file @
1426a88f
...
@@ -255,6 +255,35 @@ static void Run( intf_thread_t *p_intf )
...
@@ -255,6 +255,35 @@ static void Run( intf_thread_t *p_intf )
}
}
// Callbacks for vout requests
static
int
WindowOpen
(
vlc_object_t
*
p_this
)
{
vout_window_t
*
pWnd
=
(
vout_window_t
*
)
p_this
;
intf_thread_t
*
pIntf
=
(
intf_thread_t
*
)
vlc_object_find_name
(
p_this
,
"skins2"
,
FIND_ANYWHERE
);
if
(
p_intf
==
NULL
)
return
VLC_EGENERIC
;
/* FIXME: most probably not thread-safe,
* albeit no worse than ever before */
pWind
->
handle
=
VlcProc
::
getWindow
(
pIntf
,
pWnd
->
vout
,
&
pWnd
->
pos_x
,
&
pWnd
->
pos_y
,
&
pWnd
->
width
,
&
pWnd
->
height
);
pWnd
->
p_private
=
p_intf
;
pWnd
->
control
=
&
VlcProc
::
controlWindow
return
VLC_SUCCESS
;
}
static
void
WindowClose
(
vlc_object_t
*
p_this
)
{
vout_window_t
*
pWnd
=
(
vout_window_t
*
)
p_this
;
intf_thread_t
*
pIntf
=
(
intf_thread_t
*
)
p_this
->
p_private
;
VlCproc
::
releaseWindow
(
pIntf
,
pWnd
->
handle
);
}
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
// DemuxOpen: initialize demux
// DemuxOpen: initialize demux
//---------------------------------------------------------------------------
//---------------------------------------------------------------------------
...
@@ -442,6 +471,10 @@ vlc_module_begin();
...
@@ -442,6 +471,10 @@ vlc_module_begin();
set_callbacks
(
Open
,
Close
);
set_callbacks
(
Open
,
Close
);
add_shortcut
(
"skins"
);
add_shortcut
(
"skins"
);
add_submodule
();
set_capability
(
"vout window"
,
51
);
set_callbacks
(
WindowOpen
,
WindowClose
);
add_submodule
();
add_submodule
();
set_description
(
N_
(
"Skins loader demux"
)
);
set_description
(
N_
(
"Skins loader demux"
)
);
set_capability
(
"demux"
,
5
);
set_capability
(
"demux"
,
5
);
...
...
modules/gui/skins2/src/vlcproc.cpp
View file @
1426a88f
...
@@ -30,6 +30,7 @@
...
@@ -30,6 +30,7 @@
#include <vlc_aout.h>
#include <vlc_aout.h>
#include <vlc_vout.h>
#include <vlc_vout.h>
#include <vlc_playlist.h>
#include <vlc_playlist.h>
#include <vlc_window.h>
#include "vlcproc.hpp"
#include "vlcproc.hpp"
#include "os_factory.hpp"
#include "os_factory.hpp"
...
@@ -164,11 +165,6 @@ VlcProc::VlcProc( intf_thread_t *pIntf ): SkinObject( pIntf ),
...
@@ -164,11 +165,6 @@ VlcProc::VlcProc( intf_thread_t *pIntf ): SkinObject( pIntf ),
var_AddCallback
(
pIntf
,
"interaction"
,
onInteraction
,
this
);
var_AddCallback
(
pIntf
,
"interaction"
,
onInteraction
,
this
);
pIntf
->
b_interaction
=
true
;
pIntf
->
b_interaction
=
true
;
// Callbacks for vout requests
/* getIntf()->pf_request_window = &getWindow;
getIntf()->pf_release_window = &releaseWindow;
getIntf()->pf_control_window = &controlWindow;
*/
getIntf
()
->
p_sys
->
p_input
=
NULL
;
getIntf
()
->
p_sys
->
p_input
=
NULL
;
}
}
...
@@ -182,11 +178,6 @@ VlcProc::~VlcProc()
...
@@ -182,11 +178,6 @@ VlcProc::~VlcProc()
vlc_object_release
(
getIntf
()
->
p_sys
->
p_input
);
vlc_object_release
(
getIntf
()
->
p_sys
->
p_input
);
}
}
// Callbacks for vout requests
/* getIntf()->pf_request_window = NULL;
getIntf()->pf_release_window = NULL;
getIntf()->pf_control_window = NULL;
*/
var_DelCallback
(
getIntf
()
->
p_sys
->
p_playlist
,
"intf-change"
,
var_DelCallback
(
getIntf
()
->
p_sys
->
p_playlist
,
"intf-change"
,
onIntfChange
,
this
);
onIntfChange
,
this
);
var_DelCallback
(
getIntf
()
->
p_sys
->
p_playlist
,
"item-append"
,
var_DelCallback
(
getIntf
()
->
p_sys
->
p_playlist
,
"item-append"
,
...
@@ -633,9 +624,10 @@ void VlcProc::releaseWindow( intf_thread_t *pIntf, void *pWindow )
...
@@ -633,9 +624,10 @@ void VlcProc::releaseWindow( intf_thread_t *pIntf, void *pWindow )
}
}
int
VlcProc
::
controlWindow
(
intf_thread_t
*
pIntf
,
void
*
pWindow
,
int
VlcProc
::
controlWindow
(
struct
vout_window_t
*
pWnd
,
int
query
,
va_list
args
)
int
query
,
va_list
args
)
{
{
intf_thread_t
*
pIntf
=
(
intf_thread_t
*
)
pWnd
->
p_private
;
VlcProc
*
pThis
=
pIntf
->
p_sys
->
p_vlcProc
;
VlcProc
*
pThis
=
pIntf
->
p_sys
->
p_vlcProc
;
switch
(
query
)
switch
(
query
)
...
@@ -651,7 +643,7 @@ int VlcProc::controlWindow( intf_thread_t *pIntf, void *pWindow,
...
@@ -651,7 +643,7 @@ int VlcProc::controlWindow( intf_thread_t *pIntf, void *pWindow,
// Post a resize vout command
// Post a resize vout command
CmdResizeVout
*
pCmd
=
CmdResizeVout
*
pCmd
=
new
CmdResizeVout
(
pThis
->
getIntf
(),
pW
indow
,
new
CmdResizeVout
(
pThis
->
getIntf
(),
pW
nd
->
handle
,
i_width
,
i_height
);
i_width
,
i_height
);
AsyncQueue
*
pQueue
=
AsyncQueue
::
instance
(
pThis
->
getIntf
()
);
AsyncQueue
*
pQueue
=
AsyncQueue
::
instance
(
pThis
->
getIntf
()
);
pQueue
->
push
(
CmdGenericPtr
(
pCmd
)
);
pQueue
->
push
(
CmdGenericPtr
(
pCmd
)
);
...
@@ -659,7 +651,7 @@ int VlcProc::controlWindow( intf_thread_t *pIntf, void *pWindow,
...
@@ -659,7 +651,7 @@ int VlcProc::controlWindow( intf_thread_t *pIntf, void *pWindow,
}
}
default:
default:
msg_Dbg
(
p
Intf
,
"control query not supported"
);
msg_Dbg
(
p
Wnd
,
"control query not supported"
);
break
;
break
;
}
}
...
...
modules/gui/skins2/src/vlcproc.hpp
View file @
1426a88f
...
@@ -38,6 +38,7 @@
...
@@ -38,6 +38,7 @@
class
OSTimer
;
class
OSTimer
;
class
VarBool
;
class
VarBool
;
struct
aout_instance_t
;
struct
aout_instance_t
;
struct
vout_window_t
;
/// Singleton object handling VLC internal state and playlist
/// Singleton object handling VLC internal state and playlist
...
@@ -218,7 +219,7 @@ class VlcProc: public SkinObject
...
@@ -218,7 +219,7 @@ class VlcProc: public SkinObject
static
void
releaseWindow
(
intf_thread_t
*
pIntf
,
void
*
pWindow
);
static
void
releaseWindow
(
intf_thread_t
*
pIntf
,
void
*
pWindow
);
/// Callback to change a vout window
/// Callback to change a vout window
static
int
controlWindow
(
intf_thread_t
*
pIntf
,
void
*
pWindow
,
static
int
controlWindow
(
struct
vout_window_t
*
pWnd
,
int
query
,
va_list
args
);
int
query
,
va_list
args
);
/// Callback for equalizer-bands variable
/// Callback for equalizer-bands variable
...
...
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