Rockbox

Tasklist

FS#8162 - Core speex decoder and voice for SWCODEC targets

Attached to Project: Rockbox
Opened by Michael Sevakis (MikeS) - Thursday, 15 November 2007, 20:48 GMT
Last edited by Michael Sevakis (MikeS) - Sunday, 18 November 2007, 17:21 GMT
Task Type Patches
Category User Interface
Status Closed
Assigned To No-one
Operating System SW-codec
Severity Low
Priority Normal
Reported Version Daily build (which?)
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

This changes the suppoted voice format from MPEG audio to Speex and moves the decoder to the core which simplifies the playback engine greatly and factors voice away from playback.c.
This task depends upon

Closed by  Michael Sevakis (MikeS)
Sunday, 18 November 2007, 17:21 GMT
Reason for closing:  Accepted
Additional comments about closing:  New format is now used as of r15668
Comment by Michael Sevakis (MikeS) - Thursday, 15 November 2007, 21:24 GMT
Oops...forgot to check for decoding errors. Bump the voice version to 4.00 as well.
Comment by Linus Nielsen Feltzing (linusnielsen) - Friday, 16 November 2007, 07:30 GMT
I love it!!!!!!

However, there seems to be lots of unrelated changes as well, like renaming of types etc. Were these really necessary for the voice to work?

Anyway, I think this should be committed ASAP, provided that this doesn't in any way affect the Archos players, that still need voice files in MP3 format.
Comment by Michael Sevakis (MikeS) - Friday, 16 November 2007, 13:04 GMT
They were nescessary to get me to pay attention to details in pcmbuf.c (where mostly they are) so I could finish this :). Clipping changes in there were to improve the mixing speeds a bit. Can be cleaned. I'm having trouble with building the encoder (can't find headers) or I would have put Thom's extra changes to post a complete solution for testing.

No effect on Archos. That's the idea.

BTW, what about setting up the daily voice as speex? Shouldn't that be ready to go along with a full tools patch so this gets done in one felled swoop?
Comment by Michael Sevakis (MikeS) - Friday, 16 November 2007, 13:26 GMT
hmmm...perhaps I should leave the type conversions since the better clipping routine for mixing requires int32_t and int16_t explicitly and it's nicer to used the explicitely sized types for this?
Comment by Linus Nielsen Feltzing (linusnielsen) - Friday, 16 November 2007, 14:00 GMT
Keep the type conversions, they are for the better anyway.
Comment by Michael Sevakis (MikeS) - Friday, 16 November 2007, 16:31 GMT
Third version. Resync. Minor revisions and comments.
Comment by Michael Sevakis (MikeS) - Saturday, 17 November 2007, 02:38 GMT
Fourth version. Some mp3-specific code was still being called that prevented speex .talk clips from loading successfully.

EDIT: The needed version change in voicefont.c was also missing thanks to an "svn revert" on /tools. Included here.
Comment by Stephane Doyon (sdoyon) - Saturday, 17 November 2007, 02:45 GMT
Tried on my x5 and had no voice. Do I need particular tools, other
than rbspeexenc?

Would it be possible to summarize what it is rbspeexenc does differently
vs the standard speexenc?

There probably needs to be a special case when the voice is generated
with espeak: it's 22.05KHz, and speexenc appears to prefer it resampled
to 16KHz.
Comment by harry tu (bookshare) - Saturday, 17 November 2007, 05:33 GMT
Can I still use my mp3 talk clips?
Comment by Nils Wallménius (nls) - Saturday, 17 November 2007, 09:52 GMT
harry tu, no.
Comment by Michael Sevakis (MikeS) - Saturday, 17 November 2007, 10:38 GMT
Stephane,

The voice files I was using were made with eSpeak + rbspeexenc. rbspeexenc outputs raw speex data with no ogg or other container and is required for encoding. It will also be able to resample it to the proper rate (but won't convert stereo to mono). I recorded some talk clips at 44kHz, encoded them with it and had no trouble with them playing in the file browser.

By the way, which patch did you use? I've tested on four of my targets and, well, it's the same code for all of them. Basically a sure shot to it have work if everything was encoded properly.

Loading...