Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
FFmpeg
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
libremedia
Tethys
FFmpeg
Commits
c9d0f450
Commit
c9d0f450
authored
12 years ago
by
Justin Ruggles
Browse files
Options
Downloads
Patches
Plain Diff
pcmdec: use planar sample format for pcm_s16le_planar
parent
79b77475
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
libavcodec/pcm.c
+10
-9
10 additions, 9 deletions
libavcodec/pcm.c
with
10 additions
and
9 deletions
libavcodec/pcm.c
+
10
−
9
View file @
c9d0f450
...
@@ -338,15 +338,16 @@ static int pcm_decode_frame(AVCodecContext *avctx, void *data,
...
@@ -338,15 +338,16 @@ static int pcm_decode_frame(AVCodecContext *avctx, void *data,
break
;
break
;
case
AV_CODEC_ID_PCM_S16LE_PLANAR
:
case
AV_CODEC_ID_PCM_S16LE_PLANAR
:
{
{
const
uint8_t
*
src2
[
FF_SANE_NB_CHANNELS
];
n
/=
avctx
->
channels
;
n
/=
avctx
->
channels
;
for
(
c
=
0
;
c
<
avctx
->
channels
;
c
++
)
for
(
c
=
0
;
c
<
avctx
->
channels
;
c
++
)
{
src2
[
c
]
=
&
src
[
c
*
n
*
2
];
samples
=
s
->
frame
.
extended_data
[
c
];
for
(;
n
>
0
;
n
--
)
#if HAVE_BIGENDIAN
for
(
c
=
0
;
c
<
avctx
->
channels
;
c
++
)
{
DECODE
(
16
,
le16
,
src
,
samples
,
n
,
0
,
0
)
AV_WN16A
(
samples
,
bytestream_get_le16
(
&
src2
[
c
]));
#else
samples
+=
2
;
memcpy
(
samples
,
src
,
n
*
2
);
}
#endif
src
+=
n
*
2
;
}
break
;
break
;
}
}
case
AV_CODEC_ID_PCM_U16LE
:
case
AV_CODEC_ID_PCM_U16LE
:
...
@@ -533,7 +534,7 @@ PCM_CODEC (PCM_MULAW, AV_SAMPLE_FMT_S16, pcm_mulaw, "PCM mu-law")
...
@@ -533,7 +534,7 @@ PCM_CODEC (PCM_MULAW, AV_SAMPLE_FMT_S16, pcm_mulaw, "PCM mu-law")
PCM_CODEC
(
PCM_S8
,
AV_SAMPLE_FMT_U8
,
pcm_s8
,
"PCM signed 8-bit"
);
PCM_CODEC
(
PCM_S8
,
AV_SAMPLE_FMT_U8
,
pcm_s8
,
"PCM signed 8-bit"
);
PCM_CODEC
(
PCM_S16BE
,
AV_SAMPLE_FMT_S16
,
pcm_s16be
,
"PCM signed 16-bit big-endian"
);
PCM_CODEC
(
PCM_S16BE
,
AV_SAMPLE_FMT_S16
,
pcm_s16be
,
"PCM signed 16-bit big-endian"
);
PCM_CODEC
(
PCM_S16LE
,
AV_SAMPLE_FMT_S16
,
pcm_s16le
,
"PCM signed 16-bit little-endian"
);
PCM_CODEC
(
PCM_S16LE
,
AV_SAMPLE_FMT_S16
,
pcm_s16le
,
"PCM signed 16-bit little-endian"
);
PCM_DECODER
(
PCM_S16LE_PLANAR
,
AV_SAMPLE_FMT_S16
,
pcm_s16le_planar
,
"PCM 16-bit little-endian planar"
);
PCM_DECODER
(
PCM_S16LE_PLANAR
,
AV_SAMPLE_FMT_S16
P
,
pcm_s16le_planar
,
"PCM 16-bit little-endian planar"
);
PCM_CODEC
(
PCM_S24BE
,
AV_SAMPLE_FMT_S32
,
pcm_s24be
,
"PCM signed 24-bit big-endian"
);
PCM_CODEC
(
PCM_S24BE
,
AV_SAMPLE_FMT_S32
,
pcm_s24be
,
"PCM signed 24-bit big-endian"
);
PCM_CODEC
(
PCM_S24DAUD
,
AV_SAMPLE_FMT_S16
,
pcm_s24daud
,
"PCM D-Cinema audio signed 24-bit"
);
PCM_CODEC
(
PCM_S24DAUD
,
AV_SAMPLE_FMT_S16
,
pcm_s24daud
,
"PCM D-Cinema audio signed 24-bit"
);
PCM_CODEC
(
PCM_S24LE
,
AV_SAMPLE_FMT_S32
,
pcm_s24le
,
"PCM signed 24-bit little-endian"
);
PCM_CODEC
(
PCM_S24LE
,
AV_SAMPLE_FMT_S32
,
pcm_s24le
,
"PCM signed 24-bit little-endian"
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment