Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
MMCV
Commits
0d77f614
Unverified
Commit
0d77f614
authored
Apr 23, 2019
by
Kai Chen
Committed by
GitHub
Apr 23, 2019
Browse files
Merge pull request #64 from ycxioooong/master
video fps should be float
parents
5d88696a
d8bdc867
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
mmcv/video/io.py
mmcv/video/io.py
+3
-3
No files found.
mmcv/video/io.py
View file @
0d77f614
...
...
@@ -80,7 +80,7 @@ class VideoReader(object):
# get basic info
self
.
_width
=
int
(
self
.
_vcap
.
get
(
CAP_PROP_FRAME_WIDTH
))
self
.
_height
=
int
(
self
.
_vcap
.
get
(
CAP_PROP_FRAME_HEIGHT
))
self
.
_fps
=
int
(
round
(
self
.
_vcap
.
get
(
CAP_PROP_FPS
)
))
self
.
_fps
=
self
.
_vcap
.
get
(
CAP_PROP_FPS
)
self
.
_frame_cnt
=
int
(
self
.
_vcap
.
get
(
CAP_PROP_FRAME_COUNT
))
self
.
_fourcc
=
self
.
_vcap
.
get
(
CAP_PROP_FOURCC
)
...
...
@@ -111,7 +111,7 @@ class VideoReader(object):
@
property
def
fps
(
self
):
"""
in
t: FPS of the video."""
"""
floa
t: FPS of the video."""
return
self
.
_fps
@
property
...
...
@@ -298,7 +298,7 @@ def frames2video(frame_dir,
Args:
frame_dir (str): The directory containing video frames.
video_file (str): Output filename.
fps (
in
t): FPS of the output video.
fps (
floa
t): FPS of the output video.
fourcc (str): Fourcc of the output video, this should be compatible
with the output file type.
filename_tmpl (str): Filename template with the index as the variable.
...
...
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