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
ad852da0
Commit
ad852da0
authored
Feb 14, 2009
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cosmetics.
parent
70514818
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
11 deletions
+9
-11
src/video_output/vout_pictures.c
src/video_output/vout_pictures.c
+9
-11
No files found.
src/video_output/vout_pictures.c
View file @
ad852da0
...
...
@@ -455,26 +455,24 @@ void vout_PlacePicture( const vout_thread_t *p_vout,
unsigned
int
*
restrict
pi_width
,
unsigned
int
*
restrict
pi_height
)
{
if
(
(
i_width
<=
0
)
||
(
i_height
<=
0
)
)
if
(
i_width
<=
0
||
i_height
<=
0
)
{
*
pi_width
=
*
pi_height
=
*
pi_x
=
*
pi_y
=
0
;
return
;
}
bool
b_autoscale
=
p_vout
->
b_autoscale
;
int
i_zoom
=
p_vout
->
i_zoom
;
/* be realistic, scaling factor confined between .2 and 10. */
if
(
i_zoom
>
10
*
ZOOM_FP_FACTOR
||
i_zoom
<
ZOOM_FP_FACTOR
/
5
)
i_zoom
=
ZOOM_FP_FACTOR
;
if
(
b_autoscale
)
if
(
p_vout
->
b_autoscale
)
{
*
pi_width
=
i_width
;
*
pi_height
=
i_height
;
}
else
{
int
i_zoom
=
p_vout
->
i_zoom
;
/* be realistic, scaling factor confined between .2 and 10. */
if
(
i_zoom
>
10
*
ZOOM_FP_FACTOR
||
i_zoom
<
ZOOM_FP_FACTOR
/
5
)
i_zoom
=
ZOOM_FP_FACTOR
;
unsigned
int
i_original_width
,
i_original_height
;
if
(
p_vout
->
fmt_in
.
i_sar_num
>=
p_vout
->
fmt_in
.
i_sar_den
)
...
...
@@ -494,9 +492,9 @@ void vout_PlacePicture( const vout_thread_t *p_vout,
*
pi_height
=
i_original_height
*
i_zoom
/
ZOOM_FP_FACTOR
;
}
int64_t
i_scaled_width
=
p_vout
->
fmt_in
.
i_visible_width
*
(
int64_t
)
p_vout
->
fmt_in
.
i_sar_num
*
int64_t
i_scaled_width
=
p_vout
->
fmt_in
.
i_visible_width
*
(
int64_t
)
p_vout
->
fmt_in
.
i_sar_num
*
*
pi_height
/
p_vout
->
fmt_in
.
i_visible_height
/
p_vout
->
fmt_in
.
i_sar_den
;
int64_t
i_scaled_height
=
p_vout
->
fmt_in
.
i_visible_height
*
(
int64_t
)
p_vout
->
fmt_in
.
i_sar_den
*
int64_t
i_scaled_height
=
p_vout
->
fmt_in
.
i_visible_height
*
(
int64_t
)
p_vout
->
fmt_in
.
i_sar_den
*
*
pi_width
/
p_vout
->
fmt_in
.
i_visible_width
/
p_vout
->
fmt_in
.
i_sar_num
;
if
(
i_scaled_width
<=
0
||
i_scaled_height
<=
0
)
...
...
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