Package org.red5.server.net.mrtmp

Examples of org.red5.server.net.mrtmp.MRTMPPacket$Header


        buffer.clear();
        buffer.put( video );
        buffer.flip();

        VideoData videoData = new VideoData( buffer );
        videoData.setTimestamp( (int) ts );

        kt++;

//        if ( kt < 10 ) {
//            logger.debug( "+++ " + videoData );
View Full Code Here


    log.debug("Name of CLient and Stream to be recorded: "+broadcastid);   
    //log.debug("Application.getInstance()"+Application.getInstance());
    log.debug("Scope "+conn);
    log.debug("Scope "+conn.getScope());
    // Get a reference to the current broadcast stream.
    ClientBroadcastStream stream = (ClientBroadcastStream) ScopeApplicationAdapter.getInstance()
        .getBroadcastStream(conn.getScope(), broadcastid);
    try {
      // Save the stream to disk.
      stream.saveAs(streamName, false);
    } catch (Exception e) {
      log.error("Error while saving stream: " + streamName, e);
    }
  }
View Full Code Here

      log.debug("Name of CLient and Stream to be recorded: "+broadcastid);   
      //log.debug("Application.getInstance()"+Application.getInstance());
      log.debug("Scope "+conn);
      log.debug("Scope "+conn.getScope());
      // Get a reference to the current broadcast stream.
      ClientBroadcastStream stream = (ClientBroadcastStream) ScopeApplicationAdapter.getInstance()
          .getBroadcastStream(conn.getScope(), broadcastid);
   
     
      // Save the stream to disk.
      if (isScreenData) {
        stream.addStreamListener(new StreamScreenListener(streamName, conn.getScope(), flvRecordingMetaDataId, isScreenData, isInterview));
      } else {
          
        log.debug("### stream "+stream);
        log.debug("### streamName "+streamName);
        log.debug("### conn.getScope() "+conn.getScope());
        log.debug("### flvRecordingMetaDataId "+flvRecordingMetaDataId);
        log.debug("### isScreenData "+isScreenData);
        log.debug("### isInterview "+isInterview);
       
        if (isInterview) {
         
          //Additionally record the Video Signal
          stream.addStreamListener(new StreamScreenListener("AV_"+streamName, conn.getScope(), flvRecordingMetaDataId, isScreenData, isInterview));
        }
       
        stream.addStreamListener(new StreamAudioListener(streamName, conn.getScope(), flvRecordingMetaDataId, isScreenData, isInterview));
      }
      //Just for Debug Purpose
      //stream.saveAs(streamName+"_DEBUG", false);
    } catch (Exception e) {
      log.error("Error while saving stream: " + streamName, e);
View Full Code Here

     
      if (streamToClose == null) {
        log.debug("Could not aquire Stream, maybe already closed");
      }
     
      ClientBroadcastStream stream = (ClientBroadcastStream) streamToClose;
      // Stop recording.
      stream.stopRecording();
     
    } catch (Exception err) {
      log.error("[stopRecordingShow]",err);
    }
  }
View Full Code Here

     
      if (streamToClose == null) {
        log.debug("Could not aquire Stream, maybe already closed");
      }
     
      ClientBroadcastStream stream = (ClientBroadcastStream) streamToClose;

      if (stream.getStreamListeners() != null) {
       
        for (Iterator<IStreamListener> iter = stream.getStreamListeners().iterator();iter.hasNext();) {
         
          IStreamListener iStreamListener = iter.next();
         
          ListenerAdapter listenerAdapter = (ListenerAdapter) iStreamListener;
         
          log.debug("Stream Closing ?? "+listenerAdapter.getFlvRecordingMetaDataId()+ " " +flvRecordingMetaDataId);
         
          if (listenerAdapter.getFlvRecordingMetaDataId().equals(flvRecordingMetaDataId)) {
            log.debug("Stream Closing :: "+flvRecordingMetaDataId);
            listenerAdapter.closeStream();
          }
         
        }
       
        for (IStreamListener iStreamListener : stream.getStreamListeners()) {
          stream.removeStreamListener(iStreamListener);
        }
     
      }
     
      // Just for Debugging
View Full Code Here

//        if ( kt < 10 ) {
//            logger.debug( "+++ " + videoData );
//            System.out.println( "+++ " + videoData);
//        }

        RTMPMessage rtmpMsg = new RTMPMessage();
        rtmpMsg.setBody( videoData );
        publishStreamData( publishStreamId, rtmpMsg );
    }
View Full Code Here

//        if ( kt < 10 ) {
//            logger.debug( "+++ " + videoData );
//            System.out.println( "+++ " + videoData);
//        }

        RTMPMessage rtmpMsg = new RTMPMessage();
        rtmpMsg.setBody( videoData );
        publishStreamData( publishStreamId, rtmpMsg );
    }
View Full Code Here

 
 
  public m2(){
    created=true;
   
    header=new Header();
    modelname=new ZeroTerminatedString("Test");
    anims=new AnimSequ[1];
    anims[0]=new AnimSequ();
    bone=new Bones[1];
    bone[0]=new Bones();
View Full Code Here

    int ofsTextures;
    int nVertices, ofsVertices,nBones,ofsBones;
    int texlength[];
    int texoffs[];
   
    header = new Header(buff);
   
   
    // check magic
    if(header.getMagic().compareTo("MD20") != 0) {
      throw new InvalidClassException("Invalid m2 Data.");
View Full Code Here

    //if(created){
      //running offset
      int ro=0;
      //Headersize+0x10Bytes for Name+AnimSequ+Bone+0x10 for bonelookup
      ByteBuffer tmp=doRebirth(calcSize());
      header=new Header();
      tmp.put(header.buff);
      fillLine(tmp);
      ro=tmp.position();
      header.setofsName(ro);
      header.setlName(modelname.toString().length()+1);//zeroterminated
View Full Code Here

TOP

Related Classes of org.red5.server.net.mrtmp.MRTMPPacket$Header

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.