XNA Creators Club Online
Page 1 of 1 (10 items)
Sort Posts: Previous Next

problem with making a sound visualizer

Last post 04-14-2008 1:10 PM by Bjoern Graf. 9 replies.
  • 01-29-2008 11:51 PM

    problem with making a sound visualizer

    Hello Everyone,

    I'm creating a sound visualizer with a particle system.

    My question is whether there's a way to get real-time auditory information such as Decibel for each frequency; so far i was only be able to find to set or get data funcionts related to overall pitch and volume instead of specific frame.

    If there isn't any, then i hope we have this for next release because this feature would be critical for all those music themed games. Surely,my long term goal is creating sort of Rez spin-off.

     

  • 01-30-2008 12:25 AM In reply to

    Re: problem with making a sound visualizer

    I do not think there is anything built in to go to that level yet, you might have to dig deeper into the Xact classes. Remember if you do find something that you would like added and it is not there that you can post suggestions on the connect site.
  • 01-30-2008 1:22 PM In reply to

    Re: problem with making a sound visualizer

    One idea would be to write a content pipeline add-in to preprocess the original WAV files and store the information in a different file that you can read at runtime.

    There is no way to get the information you want from XACT - you would need to use something more raw like XAudio or DSound - but then that won't be XNA GS/360 compatible.


    The ZBuffer - News and information for XNA and Managed DirectX
  • 01-30-2008 6:03 PM In reply to

    Re: problem with making a sound visualizer

    And... to do that kind of sound signal analysis, you would have to use hard math - Fourier's transforms. Toys not for boys. :)

    ZMan or anyone else who knows answer: I was thinking about writing some easy managed wrapper for XAudio2, using simple P/Invokes without hard marshalling(just basic types).
    I would call and steer my c++ dll from my xna app with p/Invoke.
    The question is: will that simply work? Of course I understand that it's not supported in XNA GS... I just wanna know if this will work on xbox 360.
    I don't have one - can't check it by myself but I can't find answer why it wouldn't work.
    If someone is more interested I could write such test in no time.
  • 01-30-2008 6:04 PM In reply to

    Re: problem with making a sound visualizer

    Nope - wont work on the 360. I'm not even sure if Xaudio 2 is on the 360 yet - but even if it was you can't PInvoke to native assemblies.

    The ZBuffer - News and information for XNA and Managed DirectX
  • 01-30-2008 6:40 PM In reply to

    Re: problem with making a sound visualizer

    Hmm, thanks for answer.
    I guess an only way is:

    "It turned out that it was possible for us to support unsafe code and pointers even inside a secure sandbox on Xbox!"

    But it's not for me. :)
  • 01-30-2008 7:02 PM In reply to

    Re: problem with making a sound visualizer

    Unsafe code and pointers is still .Net code - thats why its supported.

    PInvoking to other DLLs is going outside of .Net and if you watch Shawns talk from gamefest you will see that the way they interop to the DirectX on the 360 is very different to the way we PInvoke on windows.


    The ZBuffer - News and information for XNA and Managed DirectX
  • 04-12-2008 10:58 AM In reply to

    Re: problem with making a sound visualizer

    I have recently been using the FMOD API for a similar project with XNA. It works on both platforms - Windows and the 360 - and allows you to access and even manipulate that kind of information.
  • 04-14-2008 12:30 PM In reply to

    Re: problem with making a sound visualizer

    Callisto:
    It works on both platforms - Windows and the 360


    Really?

    FMOD works with the native XDK, but I'm pretty sure you cannot use it from managed XNA Framework code.
    XNA Framework Developer - blog - homepage
  • 04-14-2008 1:10 PM In reply to

    Re: problem with making a sound visualizer

    Shawn Hargreaves:
    FMOD works with the native XDK, but I'm pretty sure you cannot use it from managed XNA Framework code.

    Well, FMOD has a managed wrapper (an ugly one, if I may add this irrelevant bit of information) but as the 360 stuff is subject to payment I doubt they distribute it for free, which makes it impossible to test with a limited budget :]

    We are boki. The rest is known.
    The not so known part of the rest: It is Björn or Bjoern, but never Bjorn.
    Vote: Allow use of non-ASCII characters in names and titles
Page 1 of 1 (10 items) Previous Next
var gDomain='m.webtrends.com'; var gDcsId='dcschd84w10000w4lw9hcqmsz_8n3x'; var gTrackEvents=1; var gFpc='WT_FPC'; /*<\/scr"+"ipt>");} /*]]>*/
DCSIMG