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
495529f7
Commit
495529f7
authored
Mar 18, 2007
by
Justin Ruggles
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
hardcode ff_ac3_frame_sizes table
Originally committed as revision 8435 to
svn://svn.ffmpeg.org/ffmpeg/trunk
parent
92964be8
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
42 additions
and
12 deletions
+42
-12
ac3.c
libavcodec/ac3.c
+0
-8
ac3.h
libavcodec/ac3.h
+1
-1
ac3tab.h
libavcodec/ac3tab.h
+41
-2
parser.c
libavcodec/parser.c
+0
-1
No files found.
libavcodec/ac3.c
View file @
495529f7
...
...
@@ -200,14 +200,6 @@ void ac3_common_init(void)
l
+=
v
;
}
bndtab
[
50
]
=
l
;
/* generate ff_ac3_frame_sizes table */
for
(
i
=
0
;
i
<
38
;
i
++
)
{
int
br
=
ff_ac3_bitratetab
[
i
>>
1
];
ff_ac3_frame_sizes
[
i
][
0
]
=
(
2
*
br
);
ff_ac3_frame_sizes
[
i
][
1
]
=
(
320
*
br
/
147
)
+
(
i
&
1
);
ff_ac3_frame_sizes
[
i
][
2
]
=
(
3
*
br
);
}
}
int
ff_ac3_parse_header
(
const
uint8_t
buf
[
7
],
AC3HeaderInfo
*
hdr
)
...
...
libavcodec/ac3.h
View file @
495529f7
...
...
@@ -89,7 +89,7 @@ typedef struct {
*/
int
ff_ac3_parse_header
(
const
uint8_t
buf
[
7
],
AC3HeaderInfo
*
hdr
);
extern
uint16_t
ff_ac3_frame_sizes
[
38
][
3
];
extern
const
uint16_t
ff_ac3_frame_sizes
[
38
][
3
];
extern
const
uint8_t
ff_ac3_channels
[
8
];
extern
const
uint16_t
ff_ac3_freqs
[
3
];
extern
const
uint16_t
ff_ac3_bitratetab
[
19
];
...
...
libavcodec/ac3tab.h
View file @
495529f7
...
...
@@ -26,9 +26,48 @@
/**
* Possible frame sizes.
*
Generated at runtime to match
ATSC A/52 Table 5.18 Frame Size Code Table.
*
from
ATSC A/52 Table 5.18 Frame Size Code Table.
*/
uint16_t
ff_ac3_frame_sizes
[
38
][
3
];
const
uint16_t
ff_ac3_frame_sizes
[
38
][
3
]
=
{
{
64
,
69
,
96
},
{
64
,
70
,
96
},
{
80
,
87
,
120
},
{
80
,
88
,
120
},
{
96
,
104
,
144
},
{
96
,
105
,
144
},
{
112
,
121
,
168
},
{
112
,
122
,
168
},
{
128
,
139
,
192
},
{
128
,
140
,
192
},
{
160
,
174
,
240
},
{
160
,
175
,
240
},
{
192
,
208
,
288
},
{
192
,
209
,
288
},
{
224
,
243
,
336
},
{
224
,
244
,
336
},
{
256
,
278
,
384
},
{
256
,
279
,
384
},
{
320
,
348
,
480
},
{
320
,
349
,
480
},
{
384
,
417
,
576
},
{
384
,
418
,
576
},
{
448
,
487
,
672
},
{
448
,
488
,
672
},
{
512
,
557
,
768
},
{
512
,
558
,
768
},
{
640
,
696
,
960
},
{
640
,
697
,
960
},
{
768
,
835
,
1152
},
{
768
,
836
,
1152
},
{
896
,
975
,
1344
},
{
896
,
976
,
1344
},
{
1024
,
1114
,
1536
},
{
1024
,
1115
,
1536
},
{
1152
,
1253
,
1728
},
{
1152
,
1254
,
1728
},
{
1280
,
1393
,
1920
},
{
1280
,
1394
,
1920
},
};
/**
* Maps audio coding mode (acmod) to number of full-bandwidth channels.
...
...
libavcodec/parser.c
View file @
495529f7
...
...
@@ -710,7 +710,6 @@ static int ac3_parse_init(AVCodecParserContext *s1)
s
->
inbuf_ptr
=
s
->
inbuf
;
s
->
header_size
=
AC3_HEADER_SIZE
;
s
->
sync
=
ac3_sync
;
ac3_common_init
();
return
0
;
}
#endif
...
...
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