mirror of
https://github.com/Rockbox/rockbox.git
synced 2025-10-13 18:17:39 -04:00
Rockbox does not support encrypted ADX. Clearly state this in the manual and the debug messages.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31094 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
3c63cb29e9
commit
bdaac8ba04
3 changed files with 17 additions and 5 deletions
|
@ -149,7 +149,7 @@ enum codec_status codec_run(void)
|
||||||
/* Get loop data */
|
/* Get loop data */
|
||||||
|
|
||||||
looping = 0; start_adr = 0; end_adr = 0;
|
looping = 0; start_adr = 0; end_adr = 0;
|
||||||
if (!memcmp(buf+0x10,"\x01\xF4\x03\x00",4)) {
|
if (!memcmp(buf+0x10,"\x01\xF4\x03",3)) {
|
||||||
/* Soul Calibur 2 style (type 03) */
|
/* Soul Calibur 2 style (type 03) */
|
||||||
DEBUGF("ADX: type 03 found\n");
|
DEBUGF("ADX: type 03 found\n");
|
||||||
/* check if header is too small for loop data */
|
/* check if header is too small for loop data */
|
||||||
|
@ -171,7 +171,7 @@ enum codec_status codec_run(void)
|
||||||
(buf[0x1f])
|
(buf[0x1f])
|
||||||
)/32*channels*18+chanstart;
|
)/32*channels*18+chanstart;
|
||||||
}
|
}
|
||||||
} else if (!memcmp(buf+0x10,"\x01\xF4\x04\x00",4)) {
|
} else if (!memcmp(buf+0x10,"\x01\xF4\x04",3)) {
|
||||||
/* Standard (type 04) */
|
/* Standard (type 04) */
|
||||||
DEBUGF("ADX: type 04 found\n");
|
DEBUGF("ADX: type 04 found\n");
|
||||||
/* check if header is too small for loop data */
|
/* check if header is too small for loop data */
|
||||||
|
@ -196,6 +196,12 @@ enum codec_status codec_run(void)
|
||||||
DEBUGF("ADX: error, couldn't determine ADX type\n");
|
DEBUGF("ADX: error, couldn't determine ADX type\n");
|
||||||
return CODEC_ERROR;
|
return CODEC_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* is file using encryption */
|
||||||
|
if (buf[0x13]==0x08) {
|
||||||
|
DEBUGF("ADX: error, encrypted ADX not supported\n");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (looping) {
|
if (looping) {
|
||||||
DEBUGF("ADX: looped, start: %lx end: %lx\n",start_adr,end_adr);
|
DEBUGF("ADX: looped, start: %lx end: %lx\n",start_adr,end_adr);
|
||||||
|
|
|
@ -73,7 +73,7 @@ bool get_adx_metadata(int fd, struct mp3entry* id3)
|
||||||
id3->filesize = filesize(fd);
|
id3->filesize = filesize(fd);
|
||||||
|
|
||||||
/* get loop info */
|
/* get loop info */
|
||||||
if (!memcmp(buf+0x10,"\x01\xF4\x03\x00",4)) {
|
if (!memcmp(buf+0x10,"\x01\xF4\x03",3)) {
|
||||||
/* Soul Calibur 2 style (type 03) */
|
/* Soul Calibur 2 style (type 03) */
|
||||||
DEBUGF("get_adx_metadata: type 03 found\n");
|
DEBUGF("get_adx_metadata: type 03 found\n");
|
||||||
/* check if header is too small for loop data */
|
/* check if header is too small for loop data */
|
||||||
|
@ -83,7 +83,7 @@ bool get_adx_metadata(int fd, struct mp3entry* id3)
|
||||||
end_adr = get_long_be(&buf[0x28]);
|
end_adr = get_long_be(&buf[0x28]);
|
||||||
start_adr = get_long_be(&buf[0x1c])/32*channels*18+chanstart;
|
start_adr = get_long_be(&buf[0x1c])/32*channels*18+chanstart;
|
||||||
}
|
}
|
||||||
} else if (!memcmp(buf+0x10,"\x01\xF4\x04\x00",4)) {
|
} else if (!memcmp(buf+0x10,"\x01\xF4\x04",3)) {
|
||||||
/* Standard (type 04) */
|
/* Standard (type 04) */
|
||||||
DEBUGF("get_adx_metadata: type 04 found\n");
|
DEBUGF("get_adx_metadata: type 04 found\n");
|
||||||
/* check if header is too small for loop data */
|
/* check if header is too small for loop data */
|
||||||
|
@ -98,6 +98,12 @@ bool get_adx_metadata(int fd, struct mp3entry* id3)
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* is file using encryption */
|
||||||
|
if (buf[0x13]==0x08) {
|
||||||
|
DEBUGF("get_adx_metadata: error, encrypted ADX not supported\n");
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (looping) {
|
if (looping) {
|
||||||
/* 2 loops, 10 second fade */
|
/* 2 loops, 10 second fade */
|
||||||
id3->length = (start_adr-chanstart + 2*(end_adr-start_adr))
|
id3->length = (start_adr-chanstart + 2*(end_adr-start_adr))
|
||||||
|
|
|
@ -114,7 +114,7 @@
|
||||||
& Supports downmixing for playback of 5.1 streams in stereo\\
|
& Supports downmixing for playback of 5.1 streams in stereo\\
|
||||||
ADX
|
ADX
|
||||||
& \fname{.adx}
|
& \fname{.adx}
|
||||||
& \\
|
& Encrypted ADX is not supported.\\
|
||||||
Advanced Audio Coding
|
Advanced Audio Coding
|
||||||
& \fname{.m4a}, \fname{.m4b}, \fname{.mp4}, \fname{.rm}, \fname{.ra}, \fname{.rmvb}
|
& \fname{.m4a}, \fname{.m4b}, \fname{.mp4}, \fname{.rm}, \fname{.ra}, \fname{.rmvb}
|
||||||
\nopt{clipv1,c200v2}{
|
\nopt{clipv1,c200v2}{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue