Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
476a7243
Commit
476a7243
authored
Mar 22, 2020
by
Andreas Rheinhardt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avformat/r3d: Remove write-only array
Signed-off-by:
Andreas Rheinhardt
<
andreas.rheinhardt@gmail.com
>
parent
6b0c9478
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
17 deletions
+3
-17
r3d.c
libavformat/r3d.c
+3
-17
No files found.
libavformat/r3d.c
View file @
476a7243
...
...
@@ -27,7 +27,6 @@
typedef
struct
R3DContext
{
unsigned
video_offsets_count
;
unsigned
*
video_offsets
;
unsigned
rdvo_offset
;
int
audio_channels
;
...
...
@@ -118,17 +117,14 @@ static int r3d_read_rdvo(AVFormatContext *s, Atom *atom)
int
i
;
r3d
->
video_offsets_count
=
(
atom
->
size
-
8
)
/
4
;
r3d
->
video_offsets
=
av_malloc
(
atom
->
size
);
if
(
!
r3d
->
video_offsets
)
return
AVERROR
(
ENOMEM
);
for
(
i
=
0
;
i
<
r3d
->
video_offsets_count
;
i
++
)
{
r3d
->
video_offsets
[
i
]
=
avio_rb32
(
s
->
pb
);
if
(
!
r3d
->
video_offsets
[
i
]
)
{
unsigned
video_offset
=
avio_rb32
(
s
->
pb
);
if
(
!
video_offset
)
{
r3d
->
video_offsets_count
=
i
;
break
;
}
av_log
(
s
,
AV_LOG_TRACE
,
"video offset %d: %#x
\n
"
,
i
,
r3d
->
video_offsets
[
i
]
);
av_log
(
s
,
AV_LOG_TRACE
,
"video offset %d: %#x
\n
"
,
i
,
video_offset
);
}
if
(
st
->
avg_frame_rate
.
num
)
...
...
@@ -400,15 +396,6 @@ static int r3d_seek(AVFormatContext *s, int stream_index, int64_t sample_time, i
return
0
;
}
static
int
r3d_close
(
AVFormatContext
*
s
)
{
R3DContext
*
r3d
=
s
->
priv_data
;
av_freep
(
&
r3d
->
video_offsets
);
return
0
;
}
AVInputFormat
ff_r3d_demuxer
=
{
.
name
=
"r3d"
,
.
long_name
=
NULL_IF_CONFIG_SMALL
(
"REDCODE R3D"
),
...
...
@@ -416,6 +403,5 @@ AVInputFormat ff_r3d_demuxer = {
.
read_probe
=
r3d_probe
,
.
read_header
=
r3d_read_header
,
.
read_packet
=
r3d_read_packet
,
.
read_close
=
r3d_close
,
.
read_seek
=
r3d_seek
,
};
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