Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
e77f8586
Commit
e77f8586
authored
Oct 09, 2007
by
Rafaël Carré
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
v4l2: fix mmap method
parent
997feb29
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
4 deletions
+3
-4
modules/access/v4l2.c
modules/access/v4l2.c
+3
-4
No files found.
modules/access/v4l2.c
View file @
e77f8586
...
...
@@ -29,7 +29,6 @@
/*
* TODO: No mjpeg support yet.
* TODO: mmap untested.
* TODO: Tuner partial implementation.
* TODO: Alsa input support?
*/
...
...
@@ -995,7 +994,7 @@ static int InitMmap( demux_t *p_demux, int i_fd )
for
(
p_sys
->
i_nbuffers
=
0
;
p_sys
->
i_nbuffers
<
req
.
count
;
++
p_sys
->
i_nbuffers
)
{
struct
v4l2_buffer
buf
;
memset
(
&
buf
,
0
,
sizeof
(
buf
)
);
buf
.
type
=
V4L2_BUF_TYPE_VIDEO_CAPTURE
;
buf
.
memory
=
V4L2_MEMORY_MMAP
;
...
...
@@ -1009,11 +1008,11 @@ static int InitMmap( demux_t *p_demux, int i_fd )
p_sys
->
p_buffers
[
p_sys
->
i_nbuffers
].
length
=
buf
.
length
;
p_sys
->
p_buffers
[
p_sys
->
i_nbuffers
].
start
=
mmap
(
NULL
,
buf
.
length
,
PROT_READ
|
PROT_WRITE
,
MAP_SHARED
,
p_sys
->
i_fd_video
,
buf
.
m
.
offset
);
mmap
(
NULL
,
buf
.
length
,
PROT_READ
|
PROT_WRITE
,
MAP_SHARED
,
i_fd
,
buf
.
m
.
offset
);
if
(
p_sys
->
p_buffers
[
p_sys
->
i_nbuffers
].
start
==
MAP_FAILED
)
{
msg_Err
(
p_demux
,
"mmap failed"
);
msg_Err
(
p_demux
,
"mmap failed
(%m)
"
);
goto
open_failed
;
}
}
...
...
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