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
31740736
Commit
31740736
authored
Jul 11, 2010
by
Reimar Döffinger
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove useless casts and memset.
Originally committed as revision 24186 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
e1d7c883
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
12 deletions
+10
-12
dvbsubdec.c
libavcodec/dvbsubdec.c
+10
-12
No files found.
libavcodec/dvbsubdec.c
View file @
31740736
...
...
@@ -356,9 +356,7 @@ static void delete_state(DVBSubContext *ctx)
static
av_cold
int
dvbsub_init_decoder
(
AVCodecContext
*
avctx
)
{
int
i
,
r
,
g
,
b
,
a
=
0
;
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
memset
(
avctx
->
priv_data
,
0
,
sizeof
(
DVBSubContext
));
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
ctx
->
composition_id
=
avctx
->
sub_id
&
0xffff
;
ctx
->
ancillary_id
=
avctx
->
sub_id
>>
16
;
...
...
@@ -428,7 +426,7 @@ static av_cold int dvbsub_init_decoder(AVCodecContext *avctx)
static
av_cold
int
dvbsub_close_decoder
(
AVCodecContext
*
avctx
)
{
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
DVBSubRegionDisplay
*
display
;
delete_state
(
ctx
);
...
...
@@ -731,7 +729,7 @@ static int dvbsub_read_8bit_string(uint8_t *destbuf, int dbuf_len,
static
void
dvbsub_parse_pixel_data_block
(
AVCodecContext
*
avctx
,
DVBSubObjectDisplay
*
display
,
const
uint8_t
*
buf
,
int
buf_size
,
int
top_bottom
,
int
non_mod
)
{
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
DVBSubRegion
*
region
=
get_region
(
ctx
,
display
->
region_id
);
const
uint8_t
*
buf_end
=
buf
+
buf_size
;
...
...
@@ -848,7 +846,7 @@ static void dvbsub_parse_pixel_data_block(AVCodecContext *avctx, DVBSubObjectDis
static
void
dvbsub_parse_object_segment
(
AVCodecContext
*
avctx
,
const
uint8_t
*
buf
,
int
buf_size
)
{
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
const
uint8_t
*
buf_end
=
buf
+
buf_size
;
const
uint8_t
*
block
;
...
...
@@ -907,7 +905,7 @@ static void dvbsub_parse_object_segment(AVCodecContext *avctx,
static
void
dvbsub_parse_clut_segment
(
AVCodecContext
*
avctx
,
const
uint8_t
*
buf
,
int
buf_size
)
{
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
const
uint8_t
*
buf_end
=
buf
+
buf_size
;
int
clut_id
;
...
...
@@ -995,7 +993,7 @@ static void dvbsub_parse_clut_segment(AVCodecContext *avctx,
static
void
dvbsub_parse_region_segment
(
AVCodecContext
*
avctx
,
const
uint8_t
*
buf
,
int
buf_size
)
{
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
const
uint8_t
*
buf_end
=
buf
+
buf_size
;
int
region_id
,
object_id
;
...
...
@@ -1107,7 +1105,7 @@ static void dvbsub_parse_region_segment(AVCodecContext *avctx,
static
void
dvbsub_parse_page_segment
(
AVCodecContext
*
avctx
,
const
uint8_t
*
buf
,
int
buf_size
)
{
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
DVBSubRegionDisplay
*
display
;
DVBSubRegionDisplay
*
tmp_display_list
,
**
tmp_ptr
;
...
...
@@ -1311,7 +1309,7 @@ static void dvbsub_parse_display_definition_segment(AVCodecContext *avctx,
static
int
dvbsub_display_end_segment
(
AVCodecContext
*
avctx
,
const
uint8_t
*
buf
,
int
buf_size
,
AVSubtitle
*
sub
)
{
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
DVBSubDisplayDefinition
*
display_def
=
ctx
->
display_definition
;
DVBSubRegion
*
region
;
...
...
@@ -1399,8 +1397,8 @@ static int dvbsub_decode(AVCodecContext *avctx,
{
const
uint8_t
*
buf
=
avpkt
->
data
;
int
buf_size
=
avpkt
->
size
;
DVBSubContext
*
ctx
=
(
DVBSubContext
*
)
avctx
->
priv_data
;
AVSubtitle
*
sub
=
(
AVSubtitle
*
)
data
;
DVBSubContext
*
ctx
=
avctx
->
priv_data
;
AVSubtitle
*
sub
=
data
;
const
uint8_t
*
p
,
*
p_end
;
int
segment_type
;
int
page_id
;
...
...
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