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
1f02e8c0
Commit
1f02e8c0
authored
Apr 19, 2013
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
visual: do not keep unused fields
parent
3c4189bc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
22 deletions
+20
-22
modules/visualization/visual/visual.c
modules/visualization/visual/visual.c
+20
-22
No files found.
modules/visualization/visual/visual.c
View file @
1f02e8c0
...
@@ -175,9 +175,6 @@ struct filter_sys_t
...
@@ -175,9 +175,6 @@ struct filter_sys_t
{
{
vout_thread_t
*
p_vout
;
vout_thread_t
*
p_vout
;
int
i_width
;
int
i_height
;
int
i_effect
;
int
i_effect
;
visual_effect_t
**
effect
;
visual_effect_t
**
effect
;
};
};
...
@@ -191,21 +188,20 @@ static int Open( vlc_object_t *p_this )
...
@@ -191,21 +188,20 @@ static int Open( vlc_object_t *p_this )
filter_sys_t
*
p_sys
;
filter_sys_t
*
p_sys
;
char
*
psz_effects
,
*
psz_parser
;
char
*
psz_effects
,
*
psz_parser
;
video_format_t
fmt
;
p_sys
=
p_filter
->
p_sys
=
malloc
(
sizeof
(
filter_sys_t
)
);
p_sys
=
p_filter
->
p_sys
=
malloc
(
sizeof
(
filter_sys_t
)
);
if
(
unlikely
(
p_sys
==
NULL
)
)
if
(
unlikely
(
p_sys
==
NULL
)
)
return
VLC_EGENERIC
;
return
VLC_EGENERIC
;
p_sys
->
i_height
=
var_InheritInteger
(
p_filter
,
"effect-height
"
);
int
width
=
var_InheritInteger
(
p_filter
,
"effect-width
"
);
p_sys
->
i_width
=
var_InheritInteger
(
p_filter
,
"effect-width"
);
int
height
=
var_InheritInteger
(
p_filter
,
"effect-width"
);
/* No resolution under 400x532 and no odd dimension */
/* No resolution under 400x532 */
if
(
width
<
532
)
if
(
p_sys
->
i_height
<
400
)
p_sys
->
i_height
=
400
;
width
=
532
;
if
(
p_sys
->
i_width
<
532
)
p_sys
->
i_width
=
532
;
width
&=
~
1
;
/* Work on even dimensions */
if
(
height
<
400
)
if
(
(
p_sys
->
i_height
%
2
)
!=
0
)
p_sys
->
i_height
--
;
height
=
400
;
if
(
(
p_sys
->
i_width
%
2
)
!=
0
)
p_sys
->
i_width
--
;
height
&=
~
1
;
p_sys
->
i_effect
=
0
;
p_sys
->
i_effect
=
0
;
p_sys
->
effect
=
NULL
;
p_sys
->
effect
=
NULL
;
...
@@ -220,8 +216,8 @@ static int Open( vlc_object_t *p_this )
...
@@ -220,8 +216,8 @@ static int Open( vlc_object_t *p_this )
p_effect
=
malloc
(
sizeof
(
visual_effect_t
)
);
p_effect
=
malloc
(
sizeof
(
visual_effect_t
)
);
if
(
!
p_effect
)
if
(
!
p_effect
)
break
;
break
;
p_effect
->
i_width
=
p_sys
->
i_
width
;
p_effect
->
i_width
=
width
;
p_effect
->
i_height
=
p_sys
->
i_
height
;
p_effect
->
i_height
=
height
;
p_effect
->
i_nb_chans
=
aout_FormatNbChannels
(
&
p_filter
->
fmt_in
.
audio
);
p_effect
->
i_nb_chans
=
aout_FormatNbChannels
(
&
p_filter
->
fmt_in
.
audio
);
p_effect
->
i_idx_left
=
0
;
p_effect
->
i_idx_left
=
0
;
p_effect
->
i_idx_right
=
__MIN
(
1
,
p_effect
->
i_nb_chans
-
1
);
p_effect
->
i_idx_right
=
__MIN
(
1
,
p_effect
->
i_nb_chans
-
1
);
...
@@ -295,13 +291,15 @@ static int Open( vlc_object_t *p_this )
...
@@ -295,13 +291,15 @@ static int Open( vlc_object_t *p_this )
}
}
/* Open the video output */
/* Open the video output */
memset
(
&
fmt
,
0
,
sizeof
(
video_format_t
)
);
video_format_t
fmt
=
{
.
i_chroma
=
VLC_CODEC_I420
,
fmt
.
i_width
=
fmt
.
i_visible_width
=
p_sys
->
i_width
;
.
i_width
=
width
,
fmt
.
i_height
=
fmt
.
i_visible_height
=
p_sys
->
i_height
;
.
i_height
=
height
,
fmt
.
i_chroma
=
VLC_CODEC_I420
;
.
i_visible_width
=
width
,
fmt
.
i_sar_num
=
fmt
.
i_sar_den
=
1
;
.
i_visible_height
=
height
,
.
i_sar_num
=
1
,
.
i_sar_den
=
1
,
};
p_sys
->
p_vout
=
aout_filter_RequestVout
(
p_filter
,
NULL
,
&
fmt
);
p_sys
->
p_vout
=
aout_filter_RequestVout
(
p_filter
,
NULL
,
&
fmt
);
if
(
p_sys
->
p_vout
==
NULL
)
if
(
p_sys
->
p_vout
==
NULL
)
{
{
...
...
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