Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
3f14d5dc
Commit
3f14d5dc
authored
Jul 13, 2009
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
OpenGL: initialize all variables before creating the provider
(cherry picked from commit
c9367612
)
parent
80cd0245
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
20 deletions
+21
-20
modules/video_output/opengl.c
modules/video_output/opengl.c
+21
-20
No files found.
modules/video_output/opengl.c
View file @
3f14d5dc
...
...
@@ -196,26 +196,6 @@ static int CreateVout( vlc_object_t *p_this )
var_Create
(
p_sys
->
p_vout
,
"video-deco"
,
VLC_VAR_BOOL
|
VLC_VAR_DOINHERIT
);
psz
=
var_CreateGetString
(
p_vout
,
"opengl-provider"
);
p_sys
->
p_vout
->
p_module
=
module_need
(
p_sys
->
p_vout
,
"opengl provider"
,
psz
,
false
);
free
(
psz
);
if
(
p_sys
->
p_vout
->
p_module
==
NULL
)
{
msg_Warn
(
p_vout
,
"No OpenGL provider found"
);
vlc_object_detach
(
p_sys
->
p_vout
);
vlc_object_release
(
p_sys
->
p_vout
);
free
(
p_sys
);
return
VLC_ENOOBJ
;
}
p_vout
->
pf_init
=
Init
;
p_vout
->
pf_end
=
End
;
p_vout
->
pf_manage
=
Manage
;
p_vout
->
pf_render
=
Render
;
p_vout
->
pf_display
=
DisplayVideo
;
p_vout
->
pf_control
=
Control
;
/* Forward events from the opengl provider */
var_Create
(
p_sys
->
p_vout
,
"mouse-x"
,
VLC_VAR_INTEGER
);
var_Create
(
p_sys
->
p_vout
,
"mouse-y"
,
VLC_VAR_INTEGER
);
...
...
@@ -237,6 +217,27 @@ static int CreateVout( vlc_object_t *p_this )
var_AddCallback
(
p_vout
,
"autoscale"
,
SendEvents
,
p_sys
->
p_vout
);
var_AddCallback
(
p_vout
,
"scale"
,
SendEvents
,
p_sys
->
p_vout
);
psz
=
var_CreateGetString
(
p_vout
,
"opengl-provider"
);
p_sys
->
p_vout
->
p_module
=
module_need
(
p_sys
->
p_vout
,
"opengl provider"
,
psz
,
false
);
free
(
psz
);
if
(
p_sys
->
p_vout
->
p_module
==
NULL
)
{
msg_Warn
(
p_vout
,
"No OpenGL provider found"
);
vlc_object_detach
(
p_sys
->
p_vout
);
/* no need for var_DelCallback here :-) */
vlc_object_release
(
p_sys
->
p_vout
);
free
(
p_sys
);
return
VLC_ENOOBJ
;
}
p_vout
->
pf_init
=
Init
;
p_vout
->
pf_end
=
End
;
p_vout
->
pf_manage
=
Manage
;
p_vout
->
pf_render
=
Render
;
p_vout
->
pf_display
=
DisplayVideo
;
p_vout
->
pf_control
=
Control
;
return
VLC_SUCCESS
;
}
...
...
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