How to publish a local audio stream using NetStream?

As all we know, if we want to publish a stream to FMS or Red5, we can code like below:
var nc:NetConnection = new NetConnection();
nc.connect("rtmp://localhost/myApp");
var ns:NetStream = new NetStream(nc);
ns.attachAudio(Microphone);
ns.publish("audio", "live");
my problem is that we can pass an instance of Microphone to ns.attachAudio() only, if I want to attach a local audio stream,like playing a local sample.flv file to become a audio stream, how can I do?
this issue has been asked 7 years ago, see the post. but i can not find any solutions.
any tips will be appreciated. thx in advance.

how to watch my local network stream using java,help!http://www.ethereal.com - a third party program (but not using java)

Similar Messages

  • How to compress non-image object streams using maximum compression in acrobat x pro

    How to compress non-image object streams using maximum compression in acrobat x pro
    Please provide the screenshot if possible. Thanks!

    ZIP is the best compression for non-image streams, and it will almost certainly already have been used.

  • How can you use one NetStream to publish video and audio from another NetStream in AS3?

    Let's say one of your client programs in AS3 is able to receive live video and audio from a NetStream and play it on the screen.  How could you make it also take that video/audio stream that it's receiving, copy it over into another NetStream, and publish it elsewhere?  I need to know how to do with this regardless of whether RTMP, RTMFP, or some mixture is involved.  The reason why the stream needs to be relayed this way is a real long story, but it's necessary in this particular case. Thanks!

    RTMP is TCP, which has higher overhead and latency because it guarantees packets are delivered (handshaking, causing latency and overhead). It also doesn't allow you to share connections directly between clients forcing the server to do all the work.
    RTMFP uses UDP, which is a choice protocol for streaming video because it's the opposite. It's lossy which decreases latency and overhead from no retransmissions and most importantly (in some applications) allows you to connect directly from one Flash Player to another Flash Player (p2p) so the server overhead is dramatically reduced. The server is only required to negotiate the initial connection and then it's up to the clients to continue to facilitate that.
    How you code your one to many or many to many relationship broadcast network will be based entirely on which of those you choose.
    URLStream is very common to use in p2p. Here's an older Adobe article on p2p and an alternate quick old video tutorial (FP10) as a quick simple example of p2p over RTMFP you can view the source of.

  • How to merging two audio stream using jmf?

    I have received two rtp audio stream,i want to merging this to one but createMergingDataSource dou work well。please help 。

    You might use an alternative approach: Run exec task and use a external tool to do the encoding.
    You can for example use "The Swiss army knive of Sound" :) SoX: http://sox.sourceforge.net/
    I think from a performance point of view or to handle large files it would be even recommended in using such tools rather then encoding inside your application ... that might be different if you need to do the encoding in real-time ...
    Sebastian

  • How to publish and record video stream in h.264 format

    I'm a fresher. I want to publish and record video stream in h.264 and audio stream in AAC format .
    Does flash player support to publish video stream in h.264 format ?
    And which version of flash player and FMS could implement this function ?
    Thank you very much.

    The Flashplayer does not support h264 or AAC publishing. The Flashplayer supports only h.263 (sorenson spark) video, and Nellymoser Asao and Speex audio.
    If you want to publish h.264 you'll need to use Flash Media Live Encoder, or a third party encoder.

  • How do i save an audio file using quick time?

    How do i save a audio file from quick time. When I looked it up I was told to go to file on quick time and click on save as but my quick time has no save as to click on in file. What Now?

    How do i save a audio file from quick time. When I looked it up I was told to go to file on quick time and click on save as but my quick time has no save as to click on in file. What Now?
    You need to explin your workflow better.
    The "Save" action may be initiated by a "Share" or "Export" option depending on the app you are using. For instance, QT 7 Pro has "Save", "Save As...", "Share...", "Export...", and "Export for Web..." options depending on what you are specificly trying to do. On the other hand, QT X may have "Duplicate", "Export...", Export To", and/or "Share" options for various goals.
    Are you trying to record a new audio file using a mic, extract and save an audio track from a video, export audio from a video file, save an internet audio file that opened in the QT player, save an online audio file, etc?

  • How much bandwidth does iChat audio chat use?

    I have a friend who has a broadband connection via a 3G/Edge cell phone connection in Europe. She has to pay for bandwidth in chunks of 500mb. Anyone have any idea how much bandwidth audio chat uses on an hourly basis.

    It's complicated by how much data you can send in Video with Audio or Audio only or text chat and by what rate then can accept it.
    iChat normally sends Audio chats at about 25kbps up to about 48kbps
    After that is a question of ding the math.
    This will give the rate that is th Max. What you will not know is how much of that is actually data measured as Download over the service.
    10:38 PM Thursday; August 14, 2008

  • How do I narrate an audio book using Garageband 08

    Looking for instruction on how to narrate and record an audio book using Garageband. (Or should I be learning to use Logic?). Thanks

    Logic?? Beware!! If it's only about recording speech, you don't even need GB, any audio editor will do. But of course you can use Garageband: Create a real instrument, plug in your recording device (if you don't have any gear, preferably a good USB microphone) and hit "record".
    There's several ways you can organize your work: Save every chapter as a "song" to iTunes and organize them into a playlist. That corresponds to importing an audio book from a CD. Or save it as one big podcast with chapter markers (you might run into length problems). Or use software like AudiobookBuilder to turn your files into what an iPod regards as an audio book.

  • How to merge multiple live audio streams into a single stream in FMS?

    I need to merge multiple live audio streams into a single stream so that i can pass this stream as input to VOIP through a softphone.
    For this i tried the following approach:
    Created a new stream (str1) on FMS onAppStart and recorded the live streams (sent throgh microphone) in that new stream.
    Below is the code :
    application.onAppStart = function()
    application.myStream=Stream.get("foo");           
    application.myStream.record();
    application.onPublish = function (client,stream)
          var streamName = stream.name;
          application.myStream.play(streamName,-2,-1};
    The problem is that the Stream.play plays only 1 live stream at a time.As soon as a the 2nd live stream is sent to FMS then Stream.play stops playing the previous live stream.So,only the latest live stream is getting recorded.Whereas i need to record all the live streams in the new stream simultaneously.
    Any pointers regarding this are welcome.
    Thanks

    well i tried this once for one of my scripts and the final conclusion is its not possible to combine two streams into 1.....how would you time/encode the two voices......there is no know solution to this in flash. If you continue on despite me and find a solution please post it so we can explain to rest of world.

  • How to remove empty multiplexed audio stream (DV-PAL)?

    I am using Export > QuickTime Movie to export files that were originally captured in DV-PAL. I am using the "Current Settings" and "Make Movie Self Contained" selections. The files have 1 stereo sound track.
    When I view the exported files in the program MediaInfo (http://mediainfo.sourceforge.net/en) it's showing that I have an empty multiplexed audio stream in the file. This stream doesn't show up when I view the Properties in QuickTime however. Is there any way to remove the empty audio stream without re-encoding the video? I can't lose any quality with these videos. And yes, I am aware that DV-PAL typically includes a multiplexed audio stream.

    This is the window I get . . . . . no sign of audio.
    Also, with the sequence preset, although 32KHz can be set, there is only the choice of 8-bit, 16-bit and 32-bit.
    No sign of 12-bit.
    So which one should be used?

  • Audio streaming using DMS

    I have a large financial shop who wants to do audio streaming, ie bloomberg audio feeds to their clients. Do you think the DMS solution would be a fit here?
    2nd question: Can DMS stream audio to an IP Phone? Or would one need a CUAE like application for this?
    Any insight would be very well appreciated...
    thankyou, Lawence

    Are you talking about the video portal or digital signage?
    The answer for the video portal is "yes" Just use a windows *.wma file codec, and have the portal listen to its URL source or mount the file on the DMM for AoD playback.
    For a Digital Media Player for Digital signage, the answer would be No on the streaming in the true since of streaming audio.
    The DMP will play back the following audio codecs.
    Audio MPEG1 Layers 1 and 2
    MPEG4 AAC Low Complexity
    AC-3
    DMS cannot stream video to an IP phone, there is a one to one relationship between the DMM and the Video portal. The endpoints are either the video portal or a Digital Media Player.

  • How do I transmit an RTP stream using only a datasource?

    I've been following this tutorial: http://members.jcom.home.ne.jp/3117216601/jmf2guide/RTPPresenting.html
    And I have clients that can send me RTP audio streams, which are received in the update method.
    Now, update generates a NewReceiveStreamEvent. Which has a datasource that I can play.
    But what I want to do. Is have send the DataSource back to that client. (The ip address is unknown... but that shouldn't matter, as RTP is two-way).
    I want to send the DataSource back to the client, because later, we will be routing different clients, and who they can talk to and such. But I want to start with the basics.

    captfoss wrote:
    DerNalia wrote:
    But what I want to do. Is have send the DataSource back to that client. (The ip address is unknown... but that shouldn't matter, as RTP is two-way).RTP isn't two-way, RTP is one way... RTCP is two-way. The data transport is duplex, the QOS/control messages are duplex...
    So you do need to know the IP address of the client in order to send anything to him...
    I want to send the DataSource back to the client, because later, we will be routing different clients, and who they can talk to and such. But I want to start with the basics.You should just be able to turn around and give the DataSource that's receiving the RTP stream to an RTPManager and broadcast it back out... assuming you're not transcoding it out of its RTP format or anything.I don't have the IP address. So is this even possible without switching to RTCP? if so if you an example, that would be awesome. Also an example of two way communication with RTCP would be awesome too.
    Does RTCP used the same sort of structure that RTP does? like is there a DataSource that could be merged with other datasources, and sent back to where one of the datasources came frome?

  • How can I make local calls without using a country code when it's in my Contacts?

    The phone numbers in my Contacts all contain country codes because I do a lot of travelling.
    An example of this might be:
    +1 (229) 123-4567
    +44 (0)12 345 6789
    +31 (0)10 2345 6789
    I have an unlocked phone so when I travel, I usually pick up a local SIM and use that to make calls.
    The problem I have is that when I am abroad and select a phone number from my contact list it doesn' work. For example, if I select a contact with the number:
    +31 (0)10 2345 6789
    A voice-recording comes on saying that the number I had dialed was incorrect.
    But when I dial the number manually:
    010 2345 6789
    It works.
    In the US I do not have this problem because for some reason, the phone knows whether the +1 is needed or not. I'm sure if it uses it at all when you're in the US. When I dial internationally from within the US, the number dialing works fine.
    So this problem only occurs when I'm dialing locally in the country I'm in while travelling outside the US.
    Anyone have any idea of why this is happening and more importantly, what I need to do to fix this? I would hate to have go and change all my contact numbers and get rid of the country codes. If I ever have to call those numbers internationally, I'll need to manually add the country code back in.
    Very annoying!
    Advice anyone?

    If you include a country number, you have to drop the initial 0 from the area code. eg +31 10 2345 6789 instead of +31 (0)10 2345 6789

  • Audio Streaming with NetStream on LCDS or FDS

    Hi. I can't make audio streaming working on FDS neither on
    LCDS. I want to record audio on server.
    When trying to :
    quote:
    new NetStream(this.netConnection);
    i get
    quote:
    01:19:48,140 INFO [STDOUT] [Flex]
    Thread[RTMP-Worker-2,5,jboss]: Closing due to unhandled exception
    in reader thread: java.lang.IndexOutOfBoundsException: Index: 0,
    Size: 0
    at java.util.ArrayList.RangeCheck(Unknown Source)
    at java.util.ArrayList.get(Unknown Source)
    at
    flex.messaging.io.tcchunk.TCCommand.getArg(TCCommand.java:260)
    at
    flex.messaging.endpoints.rtmp.AbstractRTMPServer.dispatchMessage(AbstractRTMPServer.java: 821)
    at
    flex.messaging.endpoints.rtmp.NIORTMPConnection$RTMPReader.run(NIORTMPConnection.java:424 )
    at
    edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPo olExecutor.java:665)
    at
    edu.emory.mathcs.backport.java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolEx ecutor.java:690)
    at java.lang.Thread.run(Unknown Source)
    The same code works fine on RED5.
    What's wrong?
    RTMP channel definition is :
    quote:
    <channel-definition id="my-rtmp"
    class="mx.messaging.channels.RTMPChannel">
    <endpoint uri="rtmp://{server.name}:2040"
    class="flex.messaging.endpoints.RTMPEndpoint"/>
    <properties>
    <idle-timeout-minutes>20</idle-timeout-minutes>
    <client-to-server-maxbps>100K</client-to-server-maxbps>
    <server-to-client-maxbps>100K</server-to-client-maxbps>
    </properties>
    </channel-definition>

    There are seeral apps that play music over wifi or 3G
    Pandora, I(heart)music, Bing100, all free,

  • How to list all USB AUDIO DEVICES using PowerShell on Windows 7

    Hi all, 
    I'm starting today on the powershell programming world, and my first task is list all USB Headsets plugged on my computer, I wanna get the name of this devices like is shown on Windows Volume Control.
    My headset is a ZOX  DH-60, every time that I change the USB port, the name changes, like Headset ZOX DH-60, then Headset 2 ZOX DH-60, how could I get this name using powershell ? 
    Thanks,
    Best Regards
    Leonardo Lima

    Hi, 
    Nope... see my command and return
    Get-WmiObject Win32_PnPEntity | ? {$_.Service -eq 'usbaudio'} | Select * | Format-List
    __GENUS : 2
    __CLASS : Win32_PnPEntity
    __SUPERCLASS : CIM_LogicalDevice
    __DYNASTY : CIM_ManagedSystemElement
    __RELPATH : Win32_PnPEntity.DeviceID="USB\\VID_0D8C&PID_000E&MI_00\\8&149B33FB&0&0000"
    __PROPERTY_COUNT : 24
    __DERIVATION : {CIM_LogicalDevice, CIM_LogicalElement, CIM_ManagedSystemElement}
    __SERVER : HOBBIT
    __NAMESPACE : root\cimv2
    __PATH : \\HOBBIT\root\cimv2:Win32_PnPEntity.DeviceID="USB\\VID_0D8C&PID_000E&MI_00\\8&149B33FB&0&0000"
    Availability :
    Caption : Generic USB Audio Device
    ClassGuid : {4d36e96c-e325-11ce-bfc1-08002be10318}
    CompatibleID : {USB\Class_01&SubClass_01&Prot_00, USB\Class_01&SubClass_01, USB\Class_01}
    ConfigManagerErrorCode : 0
    ConfigManagerUserConfig : False
    CreationClassName : Win32_PnPEntity
    Description : Dispositivo de áudio USB
    DeviceID : USB\VID_0D8C&PID_000E&MI_00\8&149B33FB&0&0000
    ErrorCleared :
    ErrorDescription :
    HardwareID : {USB\VID_0D8C&PID_000E&REV_0100&MI_00, USB\VID_0D8C&PID_000E&MI_00}
    InstallDate :
    LastErrorCode :
    Manufacturer : (Áudio USB genérico)
    Name : Generic USB Audio Device
    PNPDeviceID : USB\VID_0D8C&PID_000E&MI_00\8&149B33FB&0&0000
    PowerManagementCapabilities :
    PowerManagementSupported :
    Service : usbaudio
    Status : OK
    StatusInfo :
    SystemCreationClassName : Win32_ComputerSystem
    SystemName : HOBBIT
    Scope : System.Management.ManagementScope
    Path : \\HOBBIT\root\cimv2:Win32_PnPEntity.DeviceID="USB\\VID_0D8C&PID_000E&MI_00\\8&149B33FB&0&0000"
    Options : System.Management.ObjectGetOptions
    ClassPath : \\HOBBIT\root\cimv2:Win32_PnPEntity
    Properties : {Availability, Caption, ClassGuid, CompatibleID...}
    SystemProperties : {__GENUS, __CLASS, __SUPERCLASS, __DYNASTY...}
    Qualifiers : {dynamic, Locale, provider, UUID}
    Site :
    Container :
    __GENUS : 2
    __CLASS : Win32_PnPEntity
    __SUPERCLASS : CIM_LogicalDevice
    __DYNASTY : CIM_ManagedSystemElement
    __RELPATH : Win32_PnPEntity.DeviceID="USB\\VID_074D&PID_3556&MI_00\\8&285F78A6&0&0000"
    __PROPERTY_COUNT : 24
    __DERIVATION : {CIM_LogicalDevice, CIM_LogicalElement, CIM_ManagedSystemElement}
    __SERVER : HOBBIT
    __NAMESPACE : root\cimv2
    __PATH : \\HOBBIT\root\cimv2:Win32_PnPEntity.DeviceID="USB\\VID_074D&PID_3556&MI_00\\8&285F78A6&0&0000"
    Availability :
    Caption : ZOX DH-60
    ClassGuid : {4d36e96c-e325-11ce-bfc1-08002be10318}
    CompatibleID : {USB\Class_01&SubClass_01&Prot_00, USB\Class_01&SubClass_01, USB\Class_01}
    ConfigManagerErrorCode : 0
    ConfigManagerUserConfig : False
    CreationClassName : Win32_PnPEntity
    Description : Dispositivo de áudio USB
    DeviceID : USB\VID_074D&PID_3556&MI_00\8&285F78A6&0&0000
    ErrorCleared :
    ErrorDescription :
    HardwareID : {USB\VID_074D&PID_3556&REV_0006&MI_00, USB\VID_074D&PID_3556&MI_00}
    InstallDate :
    LastErrorCode :
    Manufacturer : (Áudio USB genérico)
    Name : ZOX DH-60
    PNPDeviceID : USB\VID_074D&PID_3556&MI_00\8&285F78A6&0&0000
    PowerManagementCapabilities :
    PowerManagementSupported :
    Service : usbaudio
    Status : OK
    StatusInfo :
    SystemCreationClassName : Win32_ComputerSystem
    SystemName : HOBBIT
    Scope : System.Management.ManagementScope
    Path : \\HOBBIT\root\cimv2:Win32_PnPEntity.DeviceID="USB\\VID_074D&PID_3556&MI_00\\8&285F78A6&0&0000"
    Options : System.Management.ObjectGetOptions
    ClassPath : \\HOBBIT\root\cimv2:Win32_PnPEntity
    Properties : {Availability, Caption, ClassGuid, CompatibleID...}
    SystemProperties : {__GENUS, __CLASS, __SUPERCLASS, __DYNASTY...}
    Qualifiers : {dynamic, Locale, provider, UUID}
    Site :
    Container :
    __GENUS : 2
    __CLASS : Win32_PnPEntity
    __SUPERCLASS : CIM_LogicalDevice
    __DYNASTY : CIM_ManagedSystemElement
    __RELPATH : Win32_PnPEntity.DeviceID="USB\\VID_074D&PID_3556&MI_00\\8&3B19294B&0&0000"
    __PROPERTY_COUNT : 24
    __DERIVATION : {CIM_LogicalDevice, CIM_LogicalElement, CIM_ManagedSystemElement}
    __SERVER : HOBBIT
    __NAMESPACE : root\cimv2
    __PATH : \\HOBBIT\root\cimv2:Win32_PnPEntity.DeviceID="USB\\VID_074D&PID_3556&MI_00\\8&3B19294B&0&0000"
    Availability :
    Caption : ZOX DH-60
    ClassGuid : {4d36e96c-e325-11ce-bfc1-08002be10318}
    CompatibleID : {USB\Class_01&SubClass_01&Prot_00, USB\Class_01&SubClass_01, USB\Class_01}
    ConfigManagerErrorCode : 0
    ConfigManagerUserConfig : False
    CreationClassName : Win32_PnPEntity
    Description : Dispositivo de áudio USB
    DeviceID : USB\VID_074D&PID_3556&MI_00\8&3B19294B&0&0000
    ErrorCleared :
    ErrorDescription :
    HardwareID : {USB\VID_074D&PID_3556&REV_0006&MI_00, USB\VID_074D&PID_3556&MI_00}
    InstallDate :
    LastErrorCode :
    Manufacturer : (Áudio USB genérico)
    Name : ZOX DH-60
    PNPDeviceID : USB\VID_074D&PID_3556&MI_00\8&3B19294B&0&0000
    PowerManagementCapabilities :
    PowerManagementSupported :
    Service : usbaudio
    Status : OK
    StatusInfo :
    SystemCreationClassName : Win32_ComputerSystem
    SystemName : HOBBIT
    Scope : System.Management.ManagementScope
    Path : \\HOBBIT\root\cimv2:Win32_PnPEntity.DeviceID="USB\\VID_074D&PID_3556&MI_00\\8&3B19294B&0&0000"
    Options : System.Management.ObjectGetOptions
    ClassPath : \\HOBBIT\root\cimv2:Win32_PnPEntity
    Properties : {Availability, Caption, ClassGuid, CompatibleID...}
    SystemProperties : {__GENUS, __CLASS, __SUPERCLASS, __DYNASTY...}
    Qualifiers : {dynamic, Locale, provider, UUID}
    Site :
    Container :

Maybe you are looking for