Package net.sf.fmj.media

Examples of net.sf.fmj.media.PullSourceStreamInputStream


     
      // only first stream supported.
      if (streams.length > 1)
        logger.warning("only 1 stream supported, " + streams.length + " found");
     
      final InputStream is = new PullSourceStreamInputStream(streams[0]);
      xmlMovieSAXHandler = new XmlMovieSAXHandler();
      xmlMovieSAXParserThread = new XmlMovieSAXParserThread(xmlMovieSAXHandler, is);
      xmlMovieSAXParserThread.start()// TODO: stop when done
     
      Format[] formats = xmlMovieSAXHandler.readTracksInfo();
View Full Code Here


      super();
   
      // determine format and frame size.
      {
        final AudioInputStream aisForFormat;
        final PullSourceStreamInputStream pssisForFormat;
       
        pssisForFormat = new PullSourceStreamInputStream(pssForFormat);
        aisForFormat = AudioSystem.getAudioInputStream(markSupportedInputStream(pssisForFormat));
        this.javaSoundInputFormat = aisForFormat.getFormat();
        this.frameLength = aisForFormat.getFrameLength();
        this.format = JavaSoundUtils.convertFormat(javaSoundInputFormat);
       
        logger.fine("JavaSoundParser: java sound format: " + javaSoundInputFormat);
        logger.fine("JavaSoundParser: jmf format: " + format);
        logger.fine("JavaSoundParser: Frame length=" + frameLength);
       
        aisForFormat.close();
        pssisForFormat.close();
      }
     
     
      setPssForReadFrame(pssForReadFrame);
   
View Full Code Here

    // we can use this to set a new stream
    public void setPssForReadFrame(PullSourceStream pssForReadFrame) throws UnsupportedAudioFileException, IOException
    {
      this.pssForReadFrame = pssForReadFrame;
      this.pssisForReadFrame = new PullSourceStreamInputStream(pssForReadFrame);
      this.aisForReadFrame = AudioSystem.getAudioInputStream(markSupportedInputStream(pssisForReadFrame));
      this.totalBytesRead = 0;

    }
View Full Code Here

TOP

Related Classes of net.sf.fmj.media.PullSourceStreamInputStream

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.