XeNTaX Forum Index
Forum MultiEx Commander Tools Tools Home
It is currently Mon Feb 20, 2017 10:03 pm

All times are UTC + 1 hour


Forum rules


Please click here to view the forum rules



Post new topic Reply to topic  [ 15 posts ] 
Author Message
 Post subject: FIFA 17 - Commentary Audio files
PostPosted: Fri Nov 11, 2016 6:50 pm 
Offline
ultra-n00b

Joined: Sun Oct 04, 2015 10:19 pm
Posts: 8
Has thanked: 0 time
Have thanks: 0 time
hi to all, i would ask help to decode audio files from FIFA 17 Commentary, i have made some hex research in the past and have found some information if useful:

1) Audio container/codec i think must be a EALayer3 ( Hex audio frame begin with 0x48 )
2) codec has been changed from fifa 16 with new coding in Frostbite engine ( From 0x19 - Speex to 0x1C i suppose Opus Codec )
3) Sample to 48000 Hz from old speex 32000 hz ( hex show 0xBB 0x80 = 48000 )
4) after sample Ealayer3 structure 0x40 - code for lenght of audio file
5) after that Ealayer3 structure 0x44 - code for think a pitch time
6) after that 0x28 0x08 is the same for all streams and think is the begin of frame packet
7) Ealayer3 container closing with same 0x45 follow by 0x04 or 0x05 or 0x06 used by Ea to recognize type of audio

From Demo of old ignite fifa 16 i have seen some file with debug inside from ea and audio master audio file was simple .wav and .aiff and ea encoded with speex format ( was the .sbr .sbs archive for all fifa version from 2011 to 2016 )


Ask for expert an help to decode this stream as wav or mp3






i have extract the first audio file from .cas commentary ( cut and paste from demo file not encrypted with hex viewer)
i have put an extension .eal3 but its not real

https://mega.nz/#!mU8D1DpY!nyv-qZJTy8eDLOELbILRHxUFl4e6Rk2yFYwMhijDUkg


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.



Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Fri Nov 11, 2016 8:01 pm 
Offline
double-veteran
double-veteran

Joined: Tue Mar 24, 2015 8:12 pm
Posts: 1010
Has thanked: 12 times
Have thanks: 391 times
rocket7900 wrote:
1) Audio container/codec i think must be a EALayer3 ( Hex audio frame begin with 0x48 )
2) codec has been changed from fifa 16 with new coding in Frostbite engine ( From 0x19 - Speex to 0x1C i suppose Opus Codec )
3) Sample to 48000 Hz from old speex 32000 hz ( hex show 0xBB 0x80 = 48000 )
4) after sample Ealayer3 structure 0x40 - code for lenght of audio file
5) after that Ealayer3 structure 0x44 - code for think a pitch time
6) after that 0x28 0x08 is the same for all streams and think is the begin of frame packet
7) Ealayer3 container closing with same 0x45 follow by 0x04 or 0x05 or 0x06 used by Ea to recognize type of audio


1) ealayer3 is not a container, its codec. This file is not ealayer3
2) why do you think its opus?
5) 0x44 is frame size
7) its not type of audio, just end of file. And you cut off some bytes from it in the end


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Fri Nov 11, 2016 9:51 pm 
Offline
ultra-n00b

Joined: Sun Oct 04, 2015 10:19 pm
Posts: 8
Has thanked: 0 time
Have thanks: 0 time
Sorry for not technical english, but i have attached the first stream inside .cas was an example found for the commentary of the demo games, after that ( it's finished with 0x45 0x00 0x00 0x05 ) begin another streams and so on ( i cant attach 800mb of entire .cas file )

i have opened the .exe of the game and searching in the hex viewer there are some reference to soma audio codec tha the game use, ACC audio for the video, speex, opus, EA use some free codec for their audio files so they changed from fifa 16 was used speex to the best quality of opus ( same free ) to improve the audio quality ( i have compared soma portion of opus sample audio to this stream and there are some similitudes...

in fifa 16 i have tried to change the value of the bytes after 0x44 and the voice in the game was acclereted after that, because ea using a system of pitch predicition to combine some portion of dialogues togheter during the game commenatry ( portion of dialogues that have different pitch time )

why it's not a ealayer3 ??? refering from zench page for the header b type
https://bitbucket.org/Zenchreal/ealayer3/src/6bd060055708bc874b41501a7214adbbf077b64c/src/Writers/HeaderBWriter.cpp?at=default&fileviewer=file-view-default Ea changed ealayer3 and modify that when passed to speex compression but the basic structure is the same perhaps a variant of ealayer3

i'm not expert but this is what i have found studing on it... i think it's a bit of base to know better for found or create an decoder


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Fri Nov 11, 2016 10:02 pm 
Offline
ultra-n00b

Joined: Sun Oct 04, 2015 10:19 pm
Posts: 8
Has thanked: 0 time
Have thanks: 0 time
attach some piece of hex viewer on th main .exe where there are reference to audio codec used in the game...


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.



Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Fri Nov 11, 2016 10:03 pm 
Offline
ultra-n00b

Joined: Sun Oct 04, 2015 10:19 pm
Posts: 8
Has thanked: 0 time
Have thanks: 0 time
another


Attachments:


You do not have the required permissions to view the files attached to this post. Register to gain access.



Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Fri Nov 11, 2016 10:41 pm 
Offline
double-veteran
double-veteran

Joined: Tue Mar 24, 2015 8:12 pm
Posts: 1010
Has thanked: 12 times
Have thanks: 391 times
rocket7900 wrote:
( it's finished with 0x45 0x00 0x00 0x05 )


It must be finished with 0x45 0x00 0x00 0x05 0x00, so you cut off 1 byte in this case

rocket7900 wrote:
in fifa 16 i have tried to change the value of the bytes after 0x44 and the voice in the game was acclereted after that


Its because you ruined the file structure which can lead to unpredictable results. After 0x44 is FRAME SIZE.

rocket7900 wrote:
why it's not a ealayer3 ???


Because ealayer3 is MP3 audio. This is not MP3 audio. This is another codec, maybe OPUS as you said. But in this case to decode it we need to build proper OPUS header for the raw data contained in this file. Do you know how to do this?


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Fri Nov 11, 2016 10:58 pm 
Offline
ultra-n00b

Joined: Sun Oct 04, 2015 10:19 pm
Posts: 8
Has thanked: 0 time
Have thanks: 0 time
i suppose that is opus because the quality of the audio in the game is better than old fifa 16 ( 0x19 speex codec ) and found some reference to opus in the exe and after see this comparision

http://opus-codec.org/comparison/

so i think that EA for fifa 17 using Frostbite change in better with this codec but its only what i suppose...if is opus there is above site that share all for encoder and decoder audio libreries for opus format ( use ogg container but for me EA - DICE on their audio engine use a raw opus packet payload inside the eayaler3 )

after the 0x44 frame size for all stream is common this code 0x28 0x08 in the fifa form 2012 to 2016 was 0x19 0x83 i dont know if audio packet start from there or not...


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Sat Nov 12, 2016 7:33 am 
Offline
double-veteran
double-veteran

Joined: Tue Mar 24, 2015 8:12 pm
Posts: 1010
Has thanked: 12 times
Have thanks: 391 times
rocket7900 wrote:
raw opus packet payload inside


ok, this must be the case, but stop calling it ealayer3, because it sounds like "they use mp3 inside ogg"

Also 0x2808 is number of samples in a frame. Then goes raw data.


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Sat Nov 12, 2016 2:39 pm 
Offline
ultra-n00b

Joined: Sun Oct 04, 2015 10:19 pm
Posts: 8
Has thanked: 0 time
Have thanks: 0 time
Here are the opus libraries:

http://opus-codec.org/downloads/

Are you able to decode the raw data if is opus audio ?


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Sat Nov 12, 2016 3:22 pm 
Offline
double-veteran
double-veteran

Joined: Tue Mar 24, 2015 8:12 pm
Posts: 1010
Has thanked: 12 times
Have thanks: 391 times
rocket7900 wrote:
Are you able to decode the raw data if is opus audio ?


I tried decoding it and it failed. As I expected.

I don't think decoding raw data is that easy. This is ogg, and you can't decode it just like that. It requires some complex manipulations and good knowledge of this codec. I don't have time for this.


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Sun Nov 27, 2016 10:11 pm 
Offline
ultra-n00b

Joined: Sun Oct 04, 2015 10:19 pm
Posts: 8
Has thanked: 0 time
Have thanks: 0 time
daemon1 wrote:
rocket7900 wrote:
Are you able to decode the raw data if is opus audio ?


I tried decoding it and it failed. As I expected.

I don't think decoding raw data is that easy. This is ogg, and you can't decode it just like that. It requires some complex manipulations and good knowledge of this codec. I don't have time for this.



i dont know if usefull, but i have found this code to convert simple rtp opus audio payload to ogg

https://git.xiph.org/?p=opus-tools.git;a=blob;f=src/opusrtp.c;hb=HEAD

if EA have their special audio container perhaps after code ( 2880 ) start the payload...


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Mon Nov 28, 2016 4:42 pm 
Offline
double-veteran
double-veteran

Joined: Tue Mar 24, 2015 8:12 pm
Posts: 1010
Has thanked: 12 times
Have thanks: 391 times
this is a part of their official tools. And it can't be compiled as a single file. I don't have time to mess with their code and learn the codec.

p.s. what is RTP?


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Wed Nov 30, 2016 11:22 pm 
Offline
ultra-n00b

Joined: Sun Oct 04, 2015 10:19 pm
Posts: 8
Has thanked: 0 time
Have thanks: 0 time
daemon1 wrote:
this is a part of their official tools. And it can't be compiled as a single file. I don't have time to mess with their code and learn the codec.

p.s. what is RTP?


is useful https://en.wikipedia.org/wiki/RTP_audio_video_profile


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Thu Dec 01, 2016 5:23 pm 
Offline
double-veteran
double-veteran

Joined: Tue Mar 24, 2015 8:12 pm
Posts: 1010
Has thanked: 12 times
Have thanks: 391 times
ok then this RTP will not help us

you need someone who have time to CODE opus stuff for you, or find a tool that can handle raw opus stuff. I dont have time for this


Top
 Profile  
 
 Post subject: Re: FIFA 17 - Commentary Audio files
PostPosted: Thu Dec 01, 2016 9:29 pm 
Offline
advanced

Joined: Thu Oct 15, 2015 8:15 pm
Posts: 58
Has thanked: 13 times
Have thanks: 1 time
daemon1 wrote:
I dont have time for this

You already said that.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 15 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group