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
8b045cac
Commit
8b045cac
authored
Sep 10, 2004
by
Gildas Bazin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* modules/codec/rawvideo.c: packetizer will also invert the pictures if needed.
parent
7cf2ad43
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
43 additions
and
0 deletions
+43
-0
modules/codec/rawvideo.c
modules/codec/rawvideo.c
+43
-0
No files found.
modules/codec/rawvideo.c
View file @
8b045cac
...
...
@@ -301,6 +301,49 @@ static block_t *SendFrame( decoder_t *p_dec, block_t *p_block )
p_block
->
i_dts
=
p_block
->
i_pts
=
p_sys
->
i_pts
;
if
(
p_sys
->
b_invert
)
{
picture_t
pic
;
uint8_t
*
p_tmp
,
*
p_pixels
;
int
i
,
j
;
/* Fill in picture_t fields */
vout_InitPicture
(
VLC_OBJECT
(
p_dec
),
&
pic
,
p_dec
->
fmt_out
.
i_codec
,
p_dec
->
fmt_out
.
video
.
i_width
,
p_dec
->
fmt_out
.
video
.
i_height
,
VOUT_ASPECT_FACTOR
);
if
(
!
pic
.
i_planes
)
{
msg_Err
(
p_dec
,
"unsupported chroma"
);
return
p_block
;
}
p_tmp
=
malloc
(
pic
.
p
[
0
].
i_visible_pitch
);
p_pixels
=
p_block
->
p_buffer
;
for
(
i
=
0
;
i
<
pic
.
i_planes
;
i
++
)
{
int
i_pitch
=
pic
.
p
[
i
].
i_visible_pitch
;
uint8_t
*
p_top
=
p_pixels
;
uint8_t
*
p_bottom
=
p_pixels
+
i_pitch
*
(
pic
.
p
[
i
].
i_visible_lines
-
1
);
for
(
j
=
0
;
j
<
pic
.
p
[
i
].
i_visible_lines
/
2
;
j
++
)
{
p_dec
->
p_vlc
->
pf_memcpy
(
p_tmp
,
p_bottom
,
pic
.
p
[
i
].
i_visible_pitch
);
p_dec
->
p_vlc
->
pf_memcpy
(
p_bottom
,
p_top
,
pic
.
p
[
i
].
i_visible_pitch
);
p_dec
->
p_vlc
->
pf_memcpy
(
p_top
,
p_tmp
,
pic
.
p
[
i
].
i_visible_pitch
);
p_top
+=
i_pitch
;
p_bottom
-=
i_pitch
;
}
p_pixels
+=
i_pitch
*
pic
.
p
[
i
].
i_lines
;
}
free
(
p_tmp
);
}
return
p_block
;
}
...
...
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