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
ce484549
Commit
ce484549
authored
Sep 14, 2009
by
Pierre Ynard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
v4l2: work around broken resolution detection
This piece of code really ought to be fixed better than that
parent
23561729
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
4 deletions
+14
-4
modules/access/v4l2.c
modules/access/v4l2.c
+14
-4
No files found.
modules/access/v4l2.c
View file @
ce484549
...
...
@@ -2000,13 +2000,23 @@ static int OpenVideoDev( vlc_object_t *p_obj, demux_sys_t *p_sys, bool b_demux )
fmt
.
fmt
.
pix
.
pixelformat
);
msg_Dbg
(
p_demux
,
"Found maximum framerate of %f"
,
p_sys
->
f_fps
);
}
uint32_t
i_width
,
i_height
;
GetMaxDimensions
(
p_demux
,
i_fd
,
fmt
.
fmt
.
pix
.
pixelformat
,
p_sys
->
f_fps
,
&
fmt
.
fmt
.
pix
.
width
,
&
fmt
.
fmt
.
pix
.
height
);
&
i_width
,
&
i_height
);
if
(
i_width
||
i_height
)
{
msg_Dbg
(
p_demux
,
"Found optimal dimensions for framerate %f of %dx%d"
,
p_sys
->
f_fps
,
fmt
.
fmt
.
pix
.
width
,
fmt
.
fmt
.
pix
.
height
);
p_sys
->
f_fps
,
i_width
,
i_height
);
fmt
.
fmt
.
pix
.
width
=
i_width
;
fmt
.
fmt
.
pix
.
height
=
i_height
;
if
(
v4l2_ioctl
(
i_fd
,
VIDIOC_S_FMT
,
&
fmt
)
<
0
)
{;}
}
else
{
msg_Warn
(
p_obj
,
"Could not find optimal width and height."
);
}
}
/* Reassign width, height and chroma incase driver override */
p_sys
->
i_width
=
fmt
.
fmt
.
pix
.
width
;
...
...
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