Results 1 to 3 of 3
  1. #1
    Splat is offline Member
    Join Date
    Oct 2009
    Posts
    21
    Rep Power
    0

    Default Can I connect InputStream to OutputStream

    I have two threads running (or plan to have) and want to know if I can connect a virtual pipe between them using InputStream and OutputStream? Is there some stream-like object that I can write to from one thread and then read from the same object from another thread? If not, what is the recommended way of doing this? The data is basically PCM_UNSIGNED 16 bit integers read in from a microphone line.

    Thanks in advance.
    Glenn.

  2. #2
    masijade is offline Senior Member
    Join Date
    Jun 2008
    Posts
    2,571
    Rep Power
    8

    Default

    See PipedInputStream and PipedOutputStream

  3. #3
    Splat is offline Member
    Join Date
    Oct 2009
    Posts
    21
    Rep Power
    0

    Default

    Yep, that works great, thanks. Now I have connected my microphone to my speakers, hooray :D

Similar Threads

  1. Problems writing to an outputstream
    By higashij in forum Java Servlet
    Replies: 1
    Last Post: 09-12-2009, 07:15 PM
  2. Outputstream not streaming.
    By dantestein in forum Networking
    Replies: 2
    Last Post: 03-14-2009, 07:36 AM
  3. Replies: 2
    Last Post: 07-28-2008, 07:32 PM
  4. Converting InputStream to OutputStream
    By Java Tip in forum Java Tip
    Replies: 1
    Last Post: 01-11-2008, 10:13 PM
  5. HashMap to share OutputStream
    By gabriel in forum Advanced Java
    Replies: 1
    Last Post: 08-06-2007, 05:47 PM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •