Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
VLC
Manage
Activity
Members
Labels
Plan
Issues
4k
Issue boards
Milestones
Code
Merge requests
454
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Contributor analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
VideoLAN
VLC
Commits
b68794c7
Commit
b68794c7
authored
12 years ago
by
Rémi Denis-Courmont
Browse files
Options
Downloads
Patches
Plain Diff
smem: use aout_BitsPerSample()
parent
08b3f509
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
modules/stream_out/smem.c
+3
-28
3 additions, 28 deletions
modules/stream_out/smem.c
with
3 additions
and
28 deletions
modules/stream_out/smem.c
+
3
−
28
View file @
b68794c7
...
...
@@ -52,6 +52,7 @@
#include
<vlc_sout.h>
#include
<vlc_block.h>
#include
<vlc_codec.h>
#include
<vlc_aout.h>
/*****************************************************************************
* Module descriptor
...
...
@@ -268,36 +269,10 @@ static sout_stream_id_t *AddAudio( sout_stream_t *p_stream, es_format_t *p_fmt )
{
char
*
psz_tmp
;
sout_stream_id_t
*
id
;
int
i_bits_per_sample
;
int
i_bits_per_sample
=
aout_BitsPerSample
(
p_fmt
->
i_codec
)
;
switch
(
p_fmt
->
i_codec
)
if
(
!
i_bits_per_sample
)
{
case
VLC_CODEC_U8
:
case
VLC_CODEC_S8
:
i_bits_per_sample
=
8
;
break
;
case
VLC_CODEC_U16L
:
case
VLC_CODEC_S16L
:
case
VLC_CODEC_U16B
:
case
VLC_CODEC_S16B
:
i_bits_per_sample
=
16
;
break
;
case
VLC_CODEC_U24L
:
case
VLC_CODEC_S24L
:
case
VLC_CODEC_U24B
:
case
VLC_CODEC_S24B
:
i_bits_per_sample
=
24
;
break
;
case
VLC_CODEC_S32L
:
case
VLC_CODEC_S32B
:
case
VLC_CODEC_FL32
:
case
VLC_CODEC_FI32
:
i_bits_per_sample
=
32
;
break
;
case
VLC_CODEC_FL64
:
i_bits_per_sample
=
64
;
break
;
default:
msg_Err
(
p_stream
,
"Smem does only support raw audio format"
);
return
NULL
;
}
...
...
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