Solved

How to record sound?

Posted on 1998-12-11
11
226 Views
Last Modified: 2012-05-04
I want to record sound from mic add some effect and give it out in real time... What interface should I use? Where can I find further information about it?
I tried DirectSound. Playing works, but couldn't find out how to record sounds... (is it possible? How?)
0
Comment
Question by:losty
  • 3
  • 3
  • 2
  • +2
11 Comments
 
LVL 1

Expert Comment

by:The_Brain
ID: 1179949
it is possible, I just have never had to use it yet.  How do you think you get your programs which record wavs?
0
 
LVL 2

Expert Comment

by:trillo
ID: 1179950
The Brain: The existence of programs that record wav's doesn't mean that it's possible. Actually, that's completely wrong, because in a standard way, you can't record and play at the same time (which is what losty is asking). SoundRecorder, for example, records and plays wav files but not simultaneously, first one, then the other action.

Anyway, it's possible using DirectX technology. Let me see if I can help you, losty.
0
 
LVL 1

Expert Comment

by:The_Brain
ID: 1179951
Darn, good point.  But yet ovious, you can't record and play at the same instance or the same program.  Strange though, I can play and record at the same time using different instances of wav play...
0
Announcing the Most Valuable Experts of 2016

MVEs are more concerned with the satisfaction of those they help than with the considerable points they can earn. They are the types of people you feel privileged to call colleagues. Join us in honoring this amazing group of Experts.

 

Author Comment

by:losty
ID: 1179952
The Brain: Winamp V2.xx supports DirectSound as an Output device. If you use it you can play with multiple instances.
And most Internet Phoning utils use full duplex... that means that you can record and play at the same time...
It is possible... but what interface should i use? I tried DirectSound first, because you can play from multiple instances ... why not record and play instead of play two times ...
but... the next prob: how can i record with direct sound?
0
 
LVL 1

Expert Comment

by:andla
ID: 1179953
I would be happy if somebody posted a small codesnippet. :-)

Your sincerely
Andla
0
 
LVL 23

Accepted Solution

by:
chensu earned 100 total points
ID: 1179954
DirectX 5 and above support DirectSoundCapture. Look into the DirectSound Tutorials - Tutorial 2: Sound Capture in the DirectX SDK documentation. "This tutorial shows how to implement DirectSoundCapture to capture a sound (typically from the microphone input) and write it to a wave file." Get the DirectX 6.0 SDK because "The DirectSound documentation has been expanded to include new overviews and tutorials.".
0
 
LVL 1

Expert Comment

by:andla
ID: 1179955
losty>> When i downloaded directx SDK i did not find small samples how it works. Everything was mixed like spaghetti. The tutorial did not give much help either.
0
 

Author Comment

by:losty
ID: 1179956
andla & chensu: I currently downloading the DirectX Foundation SDKs (15 MB + 10 MB Base Components ...  i'm on 28.8 ... thanx Microsoft!) because these were the only DirectX SDKs I could find... DirectX 6.0 SDKs are only available on CD and since i live in germany i'll have to wait about 4 weeks (thnx MS again)
(hey, do you know, where i could get them (or parts of it) on the inet anyway?). I searched MFC's Info View for DirectSoundCapture, but can't find anything... I think it's because the Info Viewer has only infos about DirectX 2 or 3.
0
 
LVL 1

Expert Comment

by:andla
ID: 1179957
losty>> Have you tryed Altavista? Perhaps (i don't know) there is an other site that support 6.0.
If you are using MSVC 4.X 5.X-> the infoviewer does not give info on DirectX. The docs is only avaible in DirectX SDK package. About time to transfer i feel very happy. I have a ISDN 128 about 4.5 times faster that your modem.
"Do braucht ein sneller modem"

Gruss gott!!
0
 
LVL 23

Expert Comment

by:chensu
ID: 1179958
You may read the online DirectX SDK documentation. Go to http://msdn.microsoft.com/developer/ and register it. Thus you can access the MSDN Library Online. (http://msdn.microsoft.com/isapi/goprem.asp?TARGET=/msdn/library/?FinishURL=/msdn/library/default.htm)

But since you are using a 28.8 modem, you may have to wait for the CDs.
0
 

Author Comment

by:losty
ID: 1179959
Oki..
I finally got a book about Direct X ... I have not completely read it, but it seams like it has something to do with DirectSoundCapture...
I'll just give you the points ;)

CU LC!
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
PDF library for Delphi 2 119
FMX enumerated colours 2 98
Setting nameservers after res_init fails doing res_query 2 94
Arduino EDI - Programming language 3 90
Errors will happen. It is a fact of life for the programmer. How and when errors are detected have a great impact on quality and cost of a product. It is better to detect errors at compile time, when possible and practical. Errors that make their wa…
In days of old, returning something by value from a function in C++ was necessarily avoided because it would, invariably, involve one or even two copies of the object being created and potentially costly calls to a copy-constructor and destructor. A…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.

813 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

14 Experts available now in Live!

Get 1:1 Help Now