Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-1.1
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-1.1
Commits
8db1d3e9
Commit
8db1d3e9
authored
Nov 02, 2009
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Enabled direct3d in "vout display" wrapper.
parent
f6d06e15
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
43 additions
and
4 deletions
+43
-4
modules/video_output/wrapper.c
modules/video_output/wrapper.c
+43
-4
No files found.
modules/video_output/wrapper.c
View file @
8db1d3e9
...
...
@@ -56,16 +56,21 @@ DECLARE_OPEN(directfb);
DECLARE_OPEN
(
yuv
);
DECLARE_OPEN
(
snapshot
);
DECLARE_OPEN
(
vmem
);
DECLARE_OPEN
(
direct3d_xp
);
DECLARE_OPEN
(
direct3d_vista
);
#undef DECLARE_OPEN
#define DECLARE_MODULE
(name, priority)
\
set_description( "Video display "#
nam
e" wrapper" ) \
set_shortname( "Video display "#
nam
e" wrapper" ) \
#define DECLARE_MODULE
_EXT(name, module, priority)
\
set_description( "Video display "#
modul
e" wrapper" ) \
set_shortname( "Video display "#
modul
e" wrapper" ) \
set_capability( "video output", priority ) \
set_callbacks( Open##
name, Close )
\
set_callbacks( Open##
module, Close )
\
add_shortcut( #name )
#define DECLARE_MODULE(name, priority) \
DECLARE_MODULE_EXT(name, name, priority)
vlc_module_begin
()
set_category
(
CAT_VIDEO
)
set_subcategory
(
SUBCAT_VIDEO_VOUT
)
...
...
@@ -102,6 +107,12 @@ vlc_module_begin()
add_submodule
()
DECLARE_MODULE
(
vmem
,
0
)
add_submodule
()
DECLARE_MODULE_EXT
(
direct3d
,
direct3d_vista
,
150
)
add_submodule
()
DECLARE_MODULE_EXT
(
direct3d
,
direct3d_xp
,
50
)
vlc_module_end
()
#undef DECLARE_MODULE
...
...
@@ -110,6 +121,7 @@ vlc_module_end()
*
*****************************************************************************/
struct
vout_sys_t
{
const
char
*
name
;
char
*
title
;
vout_display_t
*
vd
;
bool
use_dr
;
...
...
@@ -131,6 +143,10 @@ static void Display(vout_thread_t *, picture_t *);
static
void
VoutGetDisplayCfg
(
vout_thread_t
*
,
vout_display_cfg_t
*
,
const
char
*
title
);
static
int
Forward
(
vlc_object_t
*
,
char
const
*
,
vlc_value_t
,
vlc_value_t
,
void
*
);
/*****************************************************************************
*
*****************************************************************************/
...
...
@@ -146,6 +162,7 @@ static int Open(vlc_object_t *object, const char *module)
if
(
!
sys
)
return
VLC_ENOMEM
;
sys
->
name
=
module
;
sys
->
title
=
var_CreateGetNonEmptyString
(
vout
,
"video-title"
);
/* */
...
...
@@ -172,6 +189,12 @@ static int Open(vlc_object_t *object, const char *module)
return
VLC_EGENERIC
;
}
/* */
if
(
!
strcmp
(
sys
->
name
,
"direct3d_xp"
)
||
!
strcmp
(
sys
->
name
,
"direct3d_vista"
))
{
var_Create
(
vout
,
"direct3d-desktop"
,
VLC_VAR_BOOL
|
VLC_VAR_DOINHERIT
);
var_AddCallback
(
vout
,
"direct3d-desktop"
,
Forward
,
NULL
);
}
/* */
vout
->
pf_init
=
Init
;
vout
->
pf_end
=
End
;
...
...
@@ -192,6 +215,11 @@ static void Close(vlc_object_t *object)
vout_thread_t
*
vout
=
(
vout_thread_t
*
)
object
;
vout_sys_t
*
sys
=
vout
->
p_sys
;
/* */
if
(
!
strcmp
(
sys
->
name
,
"direct3d_xp"
)
||
!
strcmp
(
sys
->
name
,
"direct3d_vista"
))
{
var_DelCallback
(
vout
,
"direct3d-desktop"
,
Forward
,
NULL
);
}
vout_DeleteDisplay
(
sys
->
vd
,
NULL
);
free
(
sys
->
title
);
free
(
sys
);
...
...
@@ -482,3 +510,14 @@ static void VoutGetDisplayCfg(vout_thread_t *vout, vout_display_cfg_t *cfg, cons
else
if
(
align_mask
&
0x8
)
cfg
->
align
.
horizontal
=
VOUT_DISPLAY_ALIGN_BOTTOM
;
}
static
int
Forward
(
vlc_object_t
*
object
,
char
const
*
var
,
vlc_value_t
oldval
,
vlc_value_t
newval
,
void
*
data
)
{
vout_thread_t
*
vout
=
(
vout_thread_t
*
)
object
;
VLC_UNUSED
(
oldval
);
VLC_UNUSED
(
data
);
return
var_Set
(
vout
->
p_sys
->
vd
,
var
,
newval
);
}
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