2013-05-07 33 views
2

我需要流rtp生活到iphone。我的頻道在SDP文件中配置。當我從Flash播放器請求頻道時,我有一個插件,可以在檢測到請求後開始向Wowza發送流數據。這樣我就不需要發佈流。 當我嘗試從iPhone觀看時,由於未發佈流,導致出現錯誤。如果我從Flash播放器觀看頻道,然後嘗試從iPhone觀看,那麼它會工作,因爲該流是自動發佈的。如果我停止觀看Flash播放器,則該流將取消發佈,而不管與iphone的活動連接。Wowza:需要流rtp生活到iphone

請幫

這是我的application.xml

<Root> 
<Application> 
    <Connections> 
     <AutoAccept>true</AutoAccept> 
     <AllowDomains></AllowDomains> 
    </Connections> 
    <Streams> 
     <StreamType>rtp-live</StreamType> 
     <StorageDir>${com.wowza.wms.context.VHostConfigHome}/content</StorageDir> 
     <KeyDir>${com.wowza.wms.context.VHostConfigHome}/keys</KeyDir> 
     <LiveStreamPacketizers>cupertinostreamingpacketizer,smoothstreamingpacketizer,sanjosestreamingpacketizer</LiveStreamPacketizers> 
     <Properties> 
     </Properties> 
    </Streams> 
    <Transcoder> 
     <LiveStreamTranscoder></LiveStreamTranscoder> 
     <Templates>${SourceStreamName}.xml,transrate.xml</Templates>   <ProfileDir>${com.wowza.wms.context.VHostConfigHome}/transcoder/profiles</ProfileDir> 
     <TemplateDir>${com.wowza.wms.context.VHostConfigHome}/transcoder/templates</TemplateDir> 
     <Properties> 
     </Properties> 
    </Transcoder> 

    <DVR> 
     <Recorders></Recorders> 
     <Store></Store> 
     <WindowDuration>0</WindowDuration> 
     <StorageDir>${com.wowza.wms.context.VHostConfigHome}/dvr</StorageDir> 
     <ArchiveStrategy>append</ArchiveStrategy> 
     <Repeater> 
      <ChunkOriginURL></ChunkOriginURL> 
     </Repeater> 

     <Properties> 
     </Properties> 
    </DVR> 

    <HTTPStreamers>cupertinostreaming,smoothstreaming,sanjosestreaming</HTTPStreamers> 
    <SharedObjects> 
     <StorageDir></StorageDir> 
    </SharedObjects> 
    <Client> 
     <IdleFrequency>-1</IdleFrequency> 
     <Access> 
      <StreamReadAccess>*</StreamReadAccess> 
      <StreamWriteAccess>*</StreamWriteAccess> 
      <StreamAudioSampleAccess></StreamAudioSampleAccess> 
      <StreamVideoSampleAccess></StreamVideoSampleAccess> 
      <SharedObjectReadAccess>*</SharedObjectReadAccess> 
      <SharedObjectWriteAccess>*</SharedObjectWriteAccess> 
     </Access> 
    </Client> 
    <RTP> 
     <!-- RTP/Authentication/[type]Methods defined in Authentication.xml. Default setup includes; none, basic, digest --> 
     <Authentication> 
      <PublishMethod>digest</PublishMethod> 
      <PlayMethod>none</PlayMethod> 
     </Authentication> 
     <!-- RTP/AVSyncMethod. Valid values are: senderreport, systemclock, rtptimecode --> 
     <AVSyncMethod>senderreport</AVSyncMethod> 
     <MaxRTCPWaitTime>12000</MaxRTCPWaitTime> 
     <IdleFrequency>75</IdleFrequency> 
     <RTSPSessionTimeout>90000</RTSPSessionTimeout> 
     <RTSPMaximumPendingWriteBytes>0</RTSPMaximumPendingWriteBytes> 
     <RTSPBindIpAddress></RTSPBindIpAddress> 
     <RTSPConnectionIpAddress>0.0.0.0</RTSPConnectionIpAddress> 
     <RTSPOriginIpAddress>127.0.0.1</RTSPOriginIpAddress> 
     <IncomingDatagramPortRanges>*</IncomingDatagramPortRanges> 
     <!-- Properties defined here will override any properties defined in conf/RTP.xml for any depacketizers loaded by this application --> 
     <Properties> 
     </Properties> 
    </RTP> 
    <MediaCaster> 
     <!-- Properties defined here will override any properties defined in conf/MediaCasters.xml for any MediaCasters loaded by this applications --> 
     <Properties> 
      <Property> 
       <Name>forceInterleaved</Name> 
       <Value>true</Value> 
       <Type>Boolean</Type> 
      </Property>   
     </Properties> 
    </MediaCaster> 
    <MediaReader> 
     <!-- Properties defined here will override any properties defined in conf/MediaReaders.xml for any MediaReaders loaded by this applications --> 
     <Properties> 
     </Properties> 
    </MediaReader> 
    <MediaWriter> 
     <!-- Properties defined here will override any properties defined in conf/MediaWriter.xml for any MediaWriter loaded by this applications --> 
     <Properties> 
     </Properties> 
    </MediaWriter> 
    <LiveStreamPacketizer> 
     <!-- Properties defined here will override any properties defined in conf/LiveStreamPacketizers.xml for any LiveStreamPacketizers loaded by this applications -->   
     <Properties> 
     </Properties> 
    </LiveStreamPacketizer> 
    <HTTPStreamer> 
     <!-- Properties defined here will override any properties defined in conf/HTTPStreamers.xml for any HTTPStreamer loaded by this applications --> 
     <Properties> 
     </Properties> 
    </HTTPStreamer> 
    <Repeater> 
     <OriginURL></OriginURL> 
     <QueryString><![CDATA[]]></QueryString> 
    </Repeater> 
    <Modules> 
     <Module> 
      <Name>base</Name> 
      <Description>Base</Description> 
      <Class>com.wowza.wms.module.ModuleCore</Class> 
     </Module> 
     <Module> 
      <Name>properties</Name> 
      <Description>Properties</Description> 
      <Class>com.wowza.wms.module.ModuleProperties</Class> 
     </Module> 
     <Module> 
      <Name>logging</Name> 
      <Description>Client Logging</Description> 
      <Class>com.wowza.wms.module.ModuleClientLogging</Class> 
     </Module> 
     <Module> 
      <Name>flvplayback</Name> 
      <Description>FLVPlayback</Description> 
      <Class>com.wowza.wms.module.ModuleFLVPlayback</Class> 
     </Module> 
    </Modules> 
    <!-- Properties defined here will be added to the IApplication.getProperties() and IApplicationInstance.getProperties() collections --> 
    <Properties> 
    </Properties> 
</Application> 
</Root> 
+0

你的問題不是很清楚......「我有一個插件,一旦它檢測到請求就開始向Wowza發送數據流,所以它不適用於iPhone,因爲你從來沒有從這個插件調用iPhone,對吧? – fmodos 2013-05-07 07:23:11

+0

忽略該插件。我提到它是因爲當我使用它時,不需要發佈流。這就是我使用rtp-live的原因。 rtp-live會在有請求時自動發佈流。出於某種原因,當請求由iphone發起時,它不起作用。 – sergman 2013-05-07 07:46:28

回答

1

的流類型RTP活僅適用於閃存RTMP。

Flash RTMP clients only 

(可選)如果您的應用程序只會流爲Flash RTMP客戶, 在[安裝目錄] /conf/live/Application.xml,您可以設置 流/流類型屬性to: <StreamType>rtp-live</StreamType>

教程:http://www.wowza.com/forums/content.php?38

更改日e StreamType到它應該工作。

<StreamType>live</StreamType> 
+0

這是插件開始播放的地方。我不會將數據流式傳輸到wowza,而只是根據需要。我有200個頻道,並且Feed位於不同的服務器上。當有觀看頻道插件的請求發送命令到飼料服務器的地方開始流式傳輸到wowza。我知道它就像中繼器,但我們使用自己的協議在服務器之間進行流式傳輸。這就是我們需要rtp-live的原因。我可以發佈所有頻道,但隨後wowza會被他們沒有流的日誌所覆蓋。對於200個通道,這實際上會殺死這個過程。 – sergman 2013-05-07 17:40:11

+0

好吧,知道了......所以我看到的唯一解決方案是一個工作,你向服務器發送請求的地方開始從iPhone發佈流,它可以是一個http請求,你可以在服務器端處理它。 – fmodos 2013-05-07 19:54:13

+0

謝謝,您已閱讀我的想法。我認爲完全一樣的解決方案。我只需要保持當前連接的數量,以便在沒有人使用它時取消發佈流。非常感謝你。 – sergman 2013-05-07 22:44:18