Solved

How to stream mic audio through network?

Posted on 2004-10-01
9
1,539 Views
Last Modified: 2010-08-05
i want to stream mic-in audio through network
how to do it?
that i need to use?
0
Comment
Question by:selas
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
9 Comments
 
LVL 12

Accepted Solution

by:
Lee_Nover earned 500 total points
ID: 12206654
0
 
LVL 12

Expert Comment

by:Lee_Nover
ID: 12206660
lol .. 'you CAN check my example ..' :D
oh . the binaries are in the VoIP.zip file :) VoIP_src.zip are only the sources
0
 

Expert Comment

by:alc4emy5t
ID: 12245269
Well you could use indy IdTCPClient IdTCPServer and the readstream writestream functions

procedure SendToServer;
var
  Client: TIdTCPClient;
  AudioStream: TMemoryStream;
begin
  AudioStream := TMemoryStream.Create;
 
  While Playing do
  begin
    AudioStream.Position := 0;
    ....Code to put Audio into stream...

   Client := TIdTCPClient.Create(nil);
   Client.Host := SERVER_HOST;
   Client.Port := SERVER_PORT;

   Client.WriteStream(AudioStream, True, True);
  end;
  AudioStream.Free;
end;

procedure OnExecute(AThread: TIdThread);
var
  AudioStream: TMemoryStream;
  iSize: Integer;
begin
  AudioStream := TMemoryStream.Create;
 
  iSize := AThread.Connection.ReadInteger;
  AThread.Connection.ReadStream(AudioStream, iSize);
 
  ...Code the move the streamed audio into a buffer..
  AudioStream.Free;
end;

Its probably not an ideal solution, but would do the job. you could tell to write directly to a audio buffer of type TMemoryStream and when the buffer reaches a predetermined size the player started reading from the buffer until the end is reached or the buffer is empty and it needs to wait
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 12

Expert Comment

by:Lee_Nover
ID: 12248792
alc4emy5t: you haven't checked my example :P
0
 

Author Comment

by:selas
ID: 12346814
//   ....Code to put Audio into stream...

what code should be to add mic audio to stream?

and i get error on -> While Playing do
0
 
LVL 12

Expert Comment

by:Lee_Nover
ID: 13343085
my example for streaming audio is the exact thing he asked about .. a working example that's been used by many :)
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…

696 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