Click here to Skip to main content
15,893,663 members
Please Sign up or sign in to vote.
2.00/5 (1 vote)
See more:
Hello Im trying to implement an audio editor and im having problems with displaying the sound as a waveform. Do u know where can i find a code that allows me to do so.
Thanks in advance guys
Posted

1 solution

I don't know of any control that wil ldo this for you.

What you'd have to do is sample your audio for the time you want to display, keeping in mind that you can only display as many pixels as the display is wide, so you don't have to get the max values for the entire audio stream. You only need as many samples as you can show.

Get the max values in the stream, then it's a matter of scaling those to your display surface and drawing a line.

You can find examples all over the place. Google Results[^]
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900