Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
68416d1a
Commit
68416d1a
authored
Nov 12, 2012
by
Jean-Baptiste Kempf
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
DTS in wav: use DTS helper
parent
108edbd9
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
35 deletions
+9
-35
modules/codec/dts_header.c
modules/codec/dts_header.c
+6
-4
modules/demux/Modules.am
modules/demux/Modules.am
+1
-1
modules/demux/mpeg/es.c
modules/demux/mpeg/es.c
+2
-30
No files found.
modules/codec/dts_header.c
View file @
68416d1a
...
...
@@ -195,11 +195,9 @@ int GetSyncInfo( const uint8_t *p_buf,
pi_bit_rate
,
pi_frame_length
);
}
/* DTS-HD */
else
else
if
(
p_buf
[
0
]
==
0x64
&&
p_buf
[
1
]
==
0x58
&&
p_buf
[
2
]
==
0x20
&&
p_buf
[
3
]
==
0x25
)
{
assert
(
p_buf
[
0
]
==
0x64
&&
p_buf
[
1
]
==
0x58
&&
p_buf
[
2
]
==
0x20
&&
p_buf
[
3
]
==
0x25
);
int
i_dts_hd_size
;
bs_t
s
;
bs_init
(
&
s
,
&
p_buf
[
4
],
DTS_HEADER_SIZE
-
4
);
...
...
@@ -230,6 +228,10 @@ int GetSyncInfo( const uint8_t *p_buf,
*/
return
i_dts_hd_size
;
}
else
{
return
VLC_EGENERIC
;
}
*
pb_dts_hd
=
false
;
return
i_frame_size
;
...
...
modules/demux/Modules.am
View file @
68416d1a
...
...
@@ -65,7 +65,7 @@ endif
libvlc_LTLIBRARIES += $(LTLIBavformat)
EXTRA_LTLIBRARIES += libavformat_plugin.la
libes_plugin_la_SOURCES = mpeg/es.c
libes_plugin_la_SOURCES = mpeg/es.c
../codec/dts_header.c ../codec/dts_header.h ../codec/a52.h
libes_plugin_la_CFLAGS = $(AM_CFLAGS)
libes_plugin_la_LIBADD = $(AM_LIBADD)
...
...
modules/demux/mpeg/es.c
View file @
68416d1a
...
...
@@ -38,6 +38,7 @@
#include <vlc_input.h>
#include "../../codec/a52.h"
#include "../../codec/dts_header.h"
/*****************************************************************************
* Module descriptor
...
...
@@ -920,36 +921,7 @@ static int A52Init( demux_t *p_demux )
static
int
DtsCheckSync
(
const
uint8_t
*
p_peek
,
int
*
pi_samples
)
{
/* TODO return frame size for robustness */
/* 14 bits, little endian version of the bitstream */
if
(
p_peek
[
0
]
==
0xff
&&
p_peek
[
1
]
==
0x1f
&&
p_peek
[
2
]
==
0x00
&&
p_peek
[
3
]
==
0xe8
&&
(
p_peek
[
4
]
&
0xf0
)
==
0xf0
&&
p_peek
[
5
]
==
0x07
)
{
return
0
;
}
/* 14 bits, big endian version of the bitstream */
else
if
(
p_peek
[
0
]
==
0x1f
&&
p_peek
[
1
]
==
0xff
&&
p_peek
[
2
]
==
0xe8
&&
p_peek
[
3
]
==
0x00
&&
p_peek
[
4
]
==
0x07
&&
(
p_peek
[
5
]
&
0xf0
)
==
0xf0
)
{
return
0
;
}
/* 16 bits, big endian version of the bitstream */
else
if
(
p_peek
[
0
]
==
0x7f
&&
p_peek
[
1
]
==
0xfe
&&
p_peek
[
2
]
==
0x80
&&
p_peek
[
3
]
==
0x01
)
{
return
0
;
}
/* 16 bits, little endian version of the bitstream */
else
if
(
p_peek
[
0
]
==
0xfe
&&
p_peek
[
1
]
==
0x7f
&&
p_peek
[
2
]
==
0x01
&&
p_peek
[
3
]
==
0x80
)
{
return
0
;
}
VLC_UNUSED
(
pi_samples
);
return
VLC_EGENERIC
;
return
SyncCode
(
p_peek
);
}
static
int
DtsProbe
(
demux_t
*
p_demux
,
int64_t
*
pi_offset
)
...
...
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