XBMC Community Forum  

Go Back   XBMC Community Forum > Development > XBMC Development

XBMC Development Developers forums for XBMC related development. Programmers/Coders only!
No end-user support, no bug reports, and no feature/function requests here!
Please, add platform prefix for suggestions that are not platform-independent!:
Thread prefixes; "[LINUX]", "[LIVE]", "[MAC]", "[WINDOWS]", and "[XBOX]"

Reply
 
Thread Tools Search this Thread Display Modes
Old 2004-01-15, 08:08   #1
fankey
Junior Member
 
Join Date: Nov 2003
Posts: 5
fankey is on a distinguished road
Default DSP (APU control) development - audio filters/effects source library coded

i also posted this to the xbmp forums...

i've uploaded my source files using the end user upload page - xbmc_dsp.zip. i didn't get a chance to clean up or document the code yet, so if anyone wants to continue the work they should probably email me so i can explain what's going on. hopefully i have some time to continue to work on it along with the help of others.

i never got it completely working because i got stuck trying to figure out how to do the gui end of things. i also wasn't entirely sure what direction to go with it.

here's a quick rundown of what's in there. i know the style/class names don't match the rest of the code, but it's hard to break old habits.

filter_bank.fx - dsp builder source file of 5 stereo biquad filters
filter_bank.bin - dsp image file ( generated by dsp builder )
filter_bank.h - header file of dsp coefficients ( generated by dsp builder )
dsp.h/cpp - implements dsp::manager_t
guiwindowdsp.cpp - the start of my attempt to implement a dsp control panel

dsp builder ( included in the xdk ) allows you to graphically create a dsp processing chain. the result of the dsp builder compile is a dsp executable image ( *.bin ) and a header file which exposes the dsp coefficients. to download a dsp image you use the lpdirectsound8->downloadeffectsimage
method. one downloaded you can use the seteffectdata method to set a filter parameter. since the parameters exposed are the raw biquad parameters, some amound of parameter coefficent crunching is required to actually use the filters - the filter_t class along with lp_filter_t ( low pass filter ), hp_filter_t ( high pass filter ), and parametric_filter_t ( parametric filter ) help with this process.

generating the coefficients is a little tricky, especially since the documentation is apparently incorrect. i experimentally determined that the mapping of the biquad coefficients was incorrect. this may have been fixed in a later xdk, but i had to implement the following remapping -

dwfiltera1 = coef.b0
dwfiltera2 = coef.b1
dwfilterb0 = coef.b2
dwfilterb1 = coef.a1
dwfilterb2 = coef.a0

if you want to give it a go, good luck! let me know what kind of result you find.
fankey is offline   Reply With Quote
Old 2004-01-15, 14:00   #2
Gamester17
Team-XBMC Project Manager
 
Gamester17's Avatar
 
Join Date: Sep 2003
Location: Sweden
Posts: 10,582
Gamester17 will become famous soon enough
Thumbs up

great and very cool! developers who want to play around and try to implement fankey's code can fould it here: xbmc dsp v1.0
__________________
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
Gamester17 is offline   Reply With Quote
Old 2004-02-11, 02:55   #3
thebeast
Senior Member
 
Join Date: Oct 2003
Location: EU, Denmark, Copenhagen
Posts: 194
thebeast is on a distinguished road
Default

just to spur interest, i thought i'd ask you guys, what will this mean if this was integrated and worked, for the user and for the developer?
thebeast is offline   Reply With Quote
Old 2004-02-12, 06:27   #4
fankey
Junior Member
 
Join Date: Nov 2003
Posts: 5
fankey is on a distinguished road
Default

Quote:
Originally Posted by (thebeast @ feb. 11 2004,00:55)
just to spur interest, i thought i'd ask you guys, what will this mean if this was integrated and worked, for the user and for the developer?
it would allow for audio processing to be done ( eqs, effects, gains, etc. ) without any main cpu processing hit. the dsp should be powerful enough to to quite alot of processing. it looks like you could fit 32 bands of parametric eq, for example. most receivers have this sort of thing built in, but it would allow for you to eq ( and possibly time align ) speakers without a fancy receiver.
fankey is offline   Reply With Quote
Old 2004-02-12, 15:52   #5
Butcher
Team-XBMC Developer
 
Join Date: Dec 2003
Posts: 765
Butcher is on a distinguished road
Default

will take a look at it if no one else has...
__________________
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Butcher is offline   Reply With Quote
Old 2004-02-12, 16:32   #6
Gamester17
Team-XBMC Project Manager
 
Gamester17's Avatar
 
Join Date: Sep 2003
Location: Sweden
Posts: 10,582
Gamester17 will become famous soon enough
Thumbs up

Quote:
Originally Posted by (butcher @ feb. 12 2004,13:52)
will take a look at it if no one else has...
good stuff! yeah, if i understod fankey correcly he currently doesn't have much time to work on it but can still help out
__________________
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.
Gamester17 is offline   Reply With Quote
Old 2004-02-13, 03:29   #7
thebeast
Senior Member
 
Join Date: Oct 2003
Location: EU, Denmark, Copenhagen
Posts: 194
thebeast is on a distinguished road
Thumbs up

Quote:
Originally Posted by (fankey @ feb. 12 2004,05:27)
Quote:
Originally Posted by (thebeast @ feb. 11 2004,00:55)
just to spur interest, i thought i'd ask you guys, what will this mean if this was integrated and worked, for the user and for the developer?
it would allow for audio processing to be done ( eqs, effects, gains, etc. ) without any main cpu processing hit. the dsp should be powerful enough to to quite alot of processing. it looks like you could fit 32 bands of parametric eq, for example. most receivers have this sort of thing built in, but it would allow for you to eq ( and possibly time align ) speakers without a fancy receiver.
interesting. so this would mean the increase in "main cpu" time would leave room for the main cpu to do something else? what should this freed cpu time be spent on, or should i wait for an answer, only when (if) this is integrated? ;)

- could it mean, xbmc could have more memory free also?

- could it mean, xbmc will have more cpu to do video filtering?

- what could it be used for?? :)
thebeast is offline   Reply With Quote
Old 2004-02-13, 03:57   #8
Butcher
Team-XBMC Developer
 
Join Date: Dec 2003
Posts: 765
Butcher is on a distinguished road
Default

at the moment we don't have any audio processing, so this would allow XBMC to do what it currently does, but with additional audio processing on top "for free".
__________________
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Butcher is offline   Reply With Quote
Old 2004-02-13, 04:05   #9
thebeast
Senior Member
 
Join Date: Oct 2003
Location: EU, Denmark, Copenhagen
Posts: 194
thebeast is on a distinguished road
Exclamation

i'm all for it. i would like nothing more, if only my xbox was quieter. butcher, have you by any chance modded your xbox with a quieter fan? :-)

i'm very much into using my xbox to listen to music, if you haven't guessed this already. how will audio processing support need to be extended in xbmc? (possibly relating to xbmp experience?) in small steps?
thebeast is offline   Reply With Quote
Old 2004-02-13, 04:24   #10
Butcher
Team-XBMC Developer
 
Join Date: Dec 2003
Posts: 765
Butcher is on a distinguished road
Default

stock fan for me, i just turn up the speakers.
__________________
Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


Butcher is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
DeFX audio plug-in module for XBMC? (is it GPL open source in C) quetzalcoatl XBMC Feature Suggestions 0 2006-09-16 02:43
No audio from analog source Callduck XBMC for Xbox Specific Support 0 2005-01-31 20:04
Great looking skin, needs to be coded meistaiwan Skin Development 1 2005-01-27 15:46
TTF-Fonts in XBMC-GUI/interface coded bigandy XBMC Development 11 2004-08-24 15:54
Audio volume control jpsdr XBMC for Xbox Specific Support 0 2004-04-20 14:10


All times are GMT +2. The time now is 07:03.


Protected by Akismet, We recommend WordPress blogs
Copyright © 2008, XBMC Project