| | | Forum Newbie
       
Group: Forum Members Last Login: 10/7/2008 5:23:02 PM Posts: 3, Visits: 10 |
| | Hello, Does anyone have any ideas how you can code an application in VB that displays a visual representation (e.g. moving bars) of audio inputted to the computer on the line in port? If possible as well, could it change colours depending on the volume level? Red if below a certain value - quiet - amber for medium and green for when the volume is at an acceptable level. If anyone has any ideas, I would be grateful if you could let me know! This is the kind of thing I mean by 'moving bars' if you are unsure: 
Thanks a lot, JHedges |
| | | | 
Forum God
       
Group: Forum Members Last Login: Today @ 8:45:13 AM Posts: 349, Visits: 1,705 |
| | | | | Forum Newbie
       
Group: Forum Members Last Login: 10/7/2008 5:23:02 PM Posts: 3, Visits: 10 |
| Thanks for making me welcome CDRIVE - I have had a look at the links and will have a delve through, if anyone can post some code by itself that can do the job I would be very grateful!
Cheers,
JHedges |
| | | | 
Forum God
       
Group: Forum Members Last Login: Yesterday @ 4:36:16 PM Posts: 1,463, Visits: 3,400 |
| Welcome to A1vbcode JHedges.  JHedges (10/7/2008)
Hello, Does anyone have any ideas how you can code an application in VB that displays a visual representation (e.g. moving bars) of audio inputted to the computer on the line in port? I don't know about representing audio input but making moving bars depending upon a variable isn't a problem. You would just use a Shape and set the FillColor to what ever you want to show. When the variable is a certain value change the FillColor to suit. You would vary the Width of the Shape depending upon the variable a bit like a progressbar. 
Keith http://www.martin2k.co.uk/forums/ I've been programming with VB for 12 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning. |
| | | | Forum Newbie
       
Group: Forum Members Last Login: 10/7/2008 5:23:02 PM Posts: 3, Visits: 10 |
| Hiya Keith,
That is very useful... thanks ever so much! I will do it as you described - only thing I need to find out now is how to represent the audio input, like you say.
All help will be greatly appreciated.
Cheers,
JHedges |
| | | | 
Forum God
       
Group: Forum Members Last Login: Yesterday @ 4:36:16 PM Posts: 1,463, Visits: 3,400 |
| JHedges (10/7/2008)
only thing I need to find out now is how to represent the audio input, like you say.
Yes that is your main problem. What I would suggest is you do a search on PSC thats the best web site for all types of VB apps. I'm sure someone as made something. 
Keith http://www.martin2k.co.uk/forums/ I've been programming with VB for 12 years. Started with VB4 16bit Pro, VB5 Pro, VB6 Pro/Enterprise and now VB3 Pro. But I'm no expert, I'm still learning. |
| | | | 
Forum God
       
Group: Forum Members Last Login: Today @ 8:45:13 AM Posts: 349, Visits: 1,705 |
| JHedges (10/7/2008) Thanks for making me welcome CDRIVE - I have had a look at the links and will have a delve through, if anyone can post some code by itself that can do the job I would be very grateful!
Cheers,
JHedges J, the link that I gave you contains another link to a complete app. 'Direct Sound' inputs sound from either your Mic jack or Media Player. Actually, it gets it off your sound card. It then displays the audio on a virtual oscilloscope. It's not difficult to find the sub within the app where you can extract the 'amplitude' variable (a Long or Integer.. don't remember which) that follows the audio amplitude. This variable can be used to change the size and colors of your rectangles. Programming is 50% imagination, that includes the ability to see someone else's app and realize that it contains 90% of the code that you're looking for. 
"So much to learn. So little time to do it. Wise men know it's later than one thinks"! ***Vote here to make Keith a Moderator*** http://www.a1vbcode.com/vbforums/FindPost23630.aspx |
| |
|
|