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
bee379f5
Commit
bee379f5
authored
Sep 13, 2014
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gl: remove redundant pointer
parent
13f58bee
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
20 deletions
+20
-20
modules/video_output/gl.c
modules/video_output/gl.c
+20
-20
No files found.
modules/video_output/gl.c
View file @
bee379f5
...
@@ -83,8 +83,6 @@ vlc_module_end ()
...
@@ -83,8 +83,6 @@ vlc_module_end ()
struct
vout_display_sys_t
struct
vout_display_sys_t
{
{
vout_display_opengl_t
*
vgl
;
vout_display_opengl_t
*
vgl
;
vout_window_t
*
window
;
vlc_gl_t
*
gl
;
vlc_gl_t
*
gl
;
picture_pool_t
*
pool
;
picture_pool_t
*
pool
;
};
};
...
@@ -134,11 +132,11 @@ static int Open (vlc_object_t *obj)
...
@@ -134,11 +132,11 @@ static int Open (vlc_object_t *obj)
sys
->
gl
=
NULL
;
sys
->
gl
=
NULL
;
sys
->
pool
=
NULL
;
sys
->
pool
=
NULL
;
sys
->
window
=
MakeWindow
(
vd
);
vout_window_t
*
surface
=
MakeWindow
(
vd
);
if
(
s
ys
->
window
==
NULL
)
if
(
s
urface
==
NULL
)
goto
error
;
goto
error
;
sys
->
gl
=
vlc_gl_Create
(
s
ys
->
window
,
API
,
"$"
MODULE_VARNAME
);
sys
->
gl
=
vlc_gl_Create
(
s
urface
,
API
,
"$"
MODULE_VARNAME
);
if
(
sys
->
gl
==
NULL
)
if
(
sys
->
gl
==
NULL
)
goto
error
;
goto
error
;
...
@@ -168,8 +166,8 @@ static int Open (vlc_object_t *obj)
...
@@ -168,8 +166,8 @@ static int Open (vlc_object_t *obj)
error:
error:
if
(
sys
->
gl
!=
NULL
)
if
(
sys
->
gl
!=
NULL
)
vlc_gl_Destroy
(
sys
->
gl
);
vlc_gl_Destroy
(
sys
->
gl
);
if
(
s
ys
->
window
!=
NULL
)
if
(
s
urface
!=
NULL
)
vout_display_DeleteWindow
(
vd
,
s
ys
->
window
);
vout_display_DeleteWindow
(
vd
,
s
urface
);
free
(
sys
);
free
(
sys
);
return
VLC_EGENERIC
;
return
VLC_EGENERIC
;
}
}
...
@@ -181,13 +179,15 @@ static void Close (vlc_object_t *obj)
...
@@ -181,13 +179,15 @@ static void Close (vlc_object_t *obj)
{
{
vout_display_t
*
vd
=
(
vout_display_t
*
)
obj
;
vout_display_t
*
vd
=
(
vout_display_t
*
)
obj
;
vout_display_sys_t
*
sys
=
vd
->
sys
;
vout_display_sys_t
*
sys
=
vd
->
sys
;
vlc_gl_t
*
gl
=
sys
->
gl
;
vout_window_t
*
surface
=
gl
->
surface
;
vlc_gl_MakeCurrent
(
sys
->
gl
);
vlc_gl_MakeCurrent
(
gl
);
vout_display_opengl_Delete
(
sys
->
vgl
);
vout_display_opengl_Delete
(
sys
->
vgl
);
vlc_gl_ReleaseCurrent
(
sys
->
gl
);
vlc_gl_ReleaseCurrent
(
gl
);
vlc_gl_Destroy
(
sys
->
gl
);
vlc_gl_Destroy
(
gl
);
vout_display_DeleteWindow
(
vd
,
s
ys
->
window
);
vout_display_DeleteWindow
(
vd
,
s
urface
);
free
(
sys
);
free
(
sys
);
}
}
...
@@ -242,24 +242,24 @@ static int Control (vout_display_t *vd, int query, va_list ap)
...
@@ -242,24 +242,24 @@ static int Control (vout_display_t *vd, int query, va_list ap)
#endif
#endif
case
VOUT_DISPLAY_CHANGE_FULLSCREEN
:
case
VOUT_DISPLAY_CHANGE_FULLSCREEN
:
{
{
const
vout_display_cfg_t
*
c
fg
=
const
vout_display_cfg_t
*
c
=
va_arg
(
ap
,
const
vout_display_cfg_t
*
);
va_arg
(
ap
,
const
vout_display_cfg_t
*
);
return
vout_window_SetFullScreen
(
sys
->
window
,
cfg
->
is_fullscreen
);
return
vout_window_SetFullScreen
(
sys
->
gl
->
surface
,
c
->
is_fullscreen
);
}
}
case
VOUT_DISPLAY_CHANGE_WINDOW_STATE
:
case
VOUT_DISPLAY_CHANGE_WINDOW_STATE
:
{
{
unsigned
state
=
va_arg
(
ap
,
unsigned
);
unsigned
state
=
va_arg
(
ap
,
unsigned
);
return
vout_window_SetState
(
sys
->
window
,
state
);
return
vout_window_SetState
(
sys
->
gl
->
surface
,
state
);
}
}
case
VOUT_DISPLAY_CHANGE_DISPLAY_SIZE
:
case
VOUT_DISPLAY_CHANGE_DISPLAY_SIZE
:
case
VOUT_DISPLAY_CHANGE_DISPLAY_FILLED
:
case
VOUT_DISPLAY_CHANGE_DISPLAY_FILLED
:
case
VOUT_DISPLAY_CHANGE_ZOOM
:
case
VOUT_DISPLAY_CHANGE_ZOOM
:
{
{
const
vout_display_cfg_t
*
c
fg
=
va_arg
(
ap
,
const
vout_display_cfg_t
*
);
const
vout_display_cfg_t
*
c
=
va_arg
(
ap
,
const
vout_display_cfg_t
*
);
const
video_format_t
*
src
=
&
vd
->
source
;
const
video_format_t
*
src
=
&
vd
->
source
;
if
(
query
==
VOUT_DISPLAY_CHANGE_DISPLAY_SIZE
)
if
(
query
==
VOUT_DISPLAY_CHANGE_DISPLAY_SIZE
)
...
@@ -268,16 +268,16 @@ static int Control (vout_display_t *vd, int query, va_list ap)
...
@@ -268,16 +268,16 @@ static int Control (vout_display_t *vd, int query, va_list ap)
force
=
va_arg
(
ap
,
int
);
force
=
va_arg
(
ap
,
int
);
if
(
force
if
(
force
&&
(
c
fg
->
display
.
width
!=
vd
->
cfg
->
display
.
width
&&
(
c
->
display
.
width
!=
vd
->
cfg
->
display
.
width
||
c
fg
->
display
.
height
!=
vd
->
cfg
->
display
.
height
)
||
c
->
display
.
height
!=
vd
->
cfg
->
display
.
height
)
&&
vout_window_SetSize
(
sys
->
window
,
&&
vout_window_SetSize
(
sys
->
gl
->
surface
,
c
fg
->
display
.
width
,
cfg
->
display
.
height
))
c
->
display
.
width
,
c
->
display
.
height
))
return
VLC_EGENERIC
;
return
VLC_EGENERIC
;
}
}
vout_display_place_t
place
;
vout_display_place_t
place
;
vout_display_PlacePicture
(
&
place
,
src
,
c
fg
,
false
);
vout_display_PlacePicture
(
&
place
,
src
,
c
,
false
);
vlc_gl_MakeCurrent
(
sys
->
gl
);
vlc_gl_MakeCurrent
(
sys
->
gl
);
glViewport
(
place
.
x
,
place
.
y
,
place
.
width
,
place
.
height
);
glViewport
(
place
.
x
,
place
.
y
,
place
.
width
,
place
.
height
);
vlc_gl_ReleaseCurrent
(
sys
->
gl
);
vlc_gl_ReleaseCurrent
(
sys
->
gl
);
...
...
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