Changeset 88
- Timestamp:
- 08/22/10 19:05:34 (18 months ago)
- Location:
- trunk
- Files:
-
- 15 edited
-
builders/androidapplestreaming/jni/Android.mk (modified) (1 diff)
-
sources/androidapplestreaming/src/api.cpp (modified) (5 diffs)
-
sources/androidapplestreaming/src/main.cpp (modified) (3 diffs)
-
sources/applications/applestreamingclient/include/clientcontext.h (modified) (2 diffs)
-
sources/applications/applestreamingclient/include/eventsink/baseeventsink.h (modified) (1 diff)
-
sources/applications/applestreamingclient/include/eventsink/rtmpeventsink.h (modified) (2 diffs)
-
sources/applications/applestreamingclient/include/eventsink/varianteventsink.h (modified) (1 diff)
-
sources/applications/applestreamingclient/src/clientcontext.cpp (modified) (5 diffs)
-
sources/applications/applestreamingclient/src/eventsink/baseeventsink.cpp (modified) (4 diffs)
-
sources/applications/applestreamingclient/src/eventsink/rtmpeventsink.cpp (modified) (2 diffs)
-
sources/applications/applestreamingclient/src/eventsink/varianteventsink.cpp (modified) (3 diffs)
-
sources/applications/applestreamingclient/src/jnihelpers.cpp (modified) (1 diff)
-
sources/applications/flvplayback/flex/src/com/rtmpd/flvplayback.mxml (modified) (1 diff)
-
sources/thelib/src/protocols/rtp/connectivity/outboundconnectivity.cpp (modified) (1 diff)
-
sources/thelib/src/protocols/rtp/streaming/outnetrtpudph264stream.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/builders/androidapplestreaming/jni/Android.mk
r56 r88 24 24 MODULES_DEFINES += -DHAS_PROTOCOL_TS 25 25 MODULES_DEFINES += -DHAS_PROTOCOL_VAR 26 #MODULES_DEFINES += -DHAS_PROTOCOL_RTMP26 MODULES_DEFINES += -DHAS_PROTOCOL_RTMP 27 27 #MODULES_DEFINES += -DHAS_PROTOCOL_LIVEFLV 28 28 #MODULES_DEFINES += -DHAS_MEDIA_MP4 -
trunk/sources/androidapplestreaming/src/api.cpp
r87 r88 76 76 configuration[CONF_APPLICATION_ALIASES].PushToArray("asc"); 77 77 configuration[CONF_APPLICATION_DEFAULT] = (bool)true; 78 configuration[CONF_APPLICATION_VALIDATEHANDSHAKE] = (bool) false;78 configuration[CONF_APPLICATION_VALIDATEHANDSHAKE] = (bool)true; 79 79 configuration[CONF_APPLICATION_KEYFRAMESEEK] = (bool)true; 80 80 configuration[CONF_APPLICATION_CLIENTSIDEBUFFER] = (int32_t) 15; … … 82 82 configuration[CONF_APPLICATION_MEDIAFOLDER] = "./"; 83 83 configuration[CONF_APPLICATION_GENERATE_META_FILES] = (bool)false; 84 configuration["rtspHost"] = format("rtsp://127.0.0.1:%d/", port); 84 85 AppleStreamingClientApplication *pApp = new AppleStreamingClientApplication( 85 86 configuration); … … 106 107 ASSERT("Invalid protocol chain: %s", CONF_PROTOCOL_INBOUND_RTSP); 107 108 } 108 TCPAcceptor *pAcceptor = new TCPAcceptor(ip, port, acceptorConfig, chain); 109 TCPAcceptor *pAcceptor = new TCPAcceptor(ip, 110 (uint16_t) acceptorConfig[CONF_PORT], acceptorConfig, chain); 109 111 if (!pAcceptor->StartAccept(pApp)) { 110 112 ASSERT("Unable to fire up acceptor"); … … 118 120 ASSERT("Invalid protocol chain: %s", CONF_PROTOCOL_INBOUND_BIN_VARIANT); 119 121 } 120 pAcceptor = new TCPAcceptor(ip, port + 1, acceptorConfig, chain); 122 pAcceptor = new TCPAcceptor(ip, (uint16_t) acceptorConfig[CONF_PORT], 123 acceptorConfig, chain); 121 124 if (!pAcceptor->StartAccept(pApp)) { 122 125 ASSERT("Unable to fire up acceptor"); … … 130 133 ASSERT("Invalid protocol chain: %s", CONF_PROTOCOL_INBOUND_XML_VARIANT); 131 134 } 132 pAcceptor = new TCPAcceptor(ip, port + 2, acceptorConfig, chain); 135 pAcceptor = new TCPAcceptor(ip, (uint16_t) acceptorConfig[CONF_PORT], 136 acceptorConfig, chain); 137 if (!pAcceptor->StartAccept(pApp)) { 138 ASSERT("Unable to fire up acceptor"); 139 } 140 141 //9. Create the RTMP acceptor 142 acceptorConfig[CONF_PORT] = (uint16_t) (1935); 143 acceptorConfig[CONF_PROTOCOL] = CONF_PROTOCOL_INBOUND_RTMP; 144 chain = ProtocolFactoryManager::ResolveProtocolChain(CONF_PROTOCOL_INBOUND_RTMP); 145 if (chain.size() == 0) { 146 ASSERT("Invalid protocol chain: %s", CONF_PROTOCOL_INBOUND_RTMP); 147 } 148 pAcceptor = new TCPAcceptor(ip, (uint16_t) acceptorConfig[CONF_PORT], 149 acceptorConfig, chain); 133 150 if (!pAcceptor->StartAccept(pApp)) { 134 151 ASSERT("Unable to fire up acceptor"); -
trunk/sources/androidapplestreaming/src/main.cpp
r87 r88 50 50 #ifdef ANDROID 51 51 CallBackInfo ci; 52 EnvRun("0.0.0.0", 554 , ci);52 EnvRun("0.0.0.0", 5544, ci); 53 53 #else 54 EnvRun("0.0.0.0", 554 );54 EnvRun("0.0.0.0", 5544); 55 55 #endif /* ANDROID */ 56 56 return NULL; … … 83 83 } 84 84 85 //#define MY_URL "http://mediadownloads.mlb.com/mlbam/2010/06/29/9505835_m3u8/128/dropf_9505835_100m_128K.m3u8" 86 //#define MY_SESSION_ID "" 87 //#define MY_KEY "" 88 85 #define MY_URL "http://mediadownloads.mlb.com/mlbam/2010/06/29/9505835_m3u8/128/dropf_9505835_100m_128K.m3u8" 86 #define MY_SESSION_ID "" 87 #define MY_KEY "" 89 88 90 89 //#define MY_URL "http://mlbvod-akc.mlb.com/mlbam/2010/04/08/MLB_GAME_VIDEO_LANPIT_HOME_20100408/master_wired.m3u8" … … 92 91 //#define MY_KEY "ugkuOk9Qy4HNS5uRxQcQXHfLuAI=" 93 92 94 #define MY_URL "http://mlbsegqa.mlb.com/mlbam/2010/08/17/MLB_GAME_VIDEO_DETNYA_HOME_20100817/master_mobile.m3u8" 95 #define MY_SESSION_ID "playback=HTTP_CLOUD_WIRED&contentId=7320085&appAccountName=mlb&eventId=14-263849-2010-04-08&ipid=11627706&sessionKey=vlPZfM8Rj1TaGDmMrtDSQh1MIWc%3D" 96 #define MY_KEY "Q8TZUMmOkyVgVSMotTCRMQ==" 93 //#define MY_URL "http://mlbsegqa.mlb.com/mlbam/2010/08/17/MLB_GAME_VIDEO_DETNYA_HOME_20100817/master_mobile.m3u8" 94 //#define MY_SESSION_ID "playback=HTTP_CLOUD_WIRED&contentId=7320085&appAccountName=mlb&eventId=14-263849-2010-04-08&ipid=11627706&sessionKey=vlPZfM8Rj1TaGDmMrtDSQh1MIWc%3D" 95 //#define MY_KEY "Q8TZUMmOkyVgVSMotTCRMQ==" 96 97 //#define MY_URL "http://mlbsegqa.mlb.com/mlbam/2010/08/17/MLB_GAME_VIDEO_DETNYA_HOME_20100817/master_mobile.m3u8" 98 //#define MY_SESSION_ID "playback=HTTP_CLOUD_MOBILE&contentId=10111969&appAccountName=mlb&eventId=14-265611-2010-08-18&ipid=23272205&sessionKey=JfPr0nOJ%2BfVzHc%2BfNV9umf9p6Yw%3D&country=us&postalCode=10292&platform=ANDROID" 99 //#define MY_KEY "7pG+lxgC/bRQ44iXCb0ydoVDCJA=" 100 101 //#define MY_URL "http://mlbsegqa.mlb.com/mlbam/2010/08/17/MLB_GAME_VIDEO_DETNYA_HOME_20100817/master_mobile.m3u8" 102 //#define MY_KEY "7pG+lxgC/bRQ44iXCb0ydoVDCJA=" 103 //#define MY_SESSION_ID "playback=HTTP_CLOUD_MOBILE&contentId=10111969&appAccountName=mlb&eventId=14-265611-2010-08-18&ipid=23272205&sessionKey=JfPr0nOJ%2BfVzHc%2BfNV9umf9p6Yw%3D&country=us&postalCode=10292&platform=ANDROID" 104 105 //#define MY_URL "http://mlbsegqa.mlb.com/mlbam/2010/08/17/MLB_GAME_VIDEO_DETNYA_HOME_20100817/master_mobile.m3u8" 106 //#define MY_KEY "fzi/ekWlN/nJY7M7zyODvnWvwCk=" 107 //#define MY_SESSION_ID "playback=HTTP_CLOUD_MOBILE&contentId=10111969&appAccountName=mlb&eventId=14-265611-2010-08-18&ipid=23272205&sessionKey=lCzgmwnNPsLrnlcqm8bZ8Fk6GEM%3D&country=us&postalCode=10292&platform=ANDROID" 108 109 110 97 111 98 112 //#define CONDENSED_CONN_STRING "base64:aHR0cDovL21sYnZvZC1ha2MubWxiLmNvbS9tbGJhbS8yMDEwLzA0LzA4L01MQl9HQU1FX1ZJREVPX0xBTlBJVF9IT01FXzIwMTAwNDA4L21hc3Rlcl93aXJlZC5tM3U4fHlNQmVFcEl6OEJEaUFYV0k0dUdIUm1UaHdIRT18cGxheWJhY2s9SFRUUF9DTE9VRF9XSVJFRCZjb250ZW50SWQ9NzMyMDA4NSZhcHBBY2NvdW50TmFtZT1tbGImZXZlbnRJZD0xNC0yNjM4NDktMjAxMC0wNC0wOCZpcGlkPTExNjI3NzA2JnNlc3Npb25LZXk9cUNveGRIaUlOY3FDbHlEcEZoU2dma3dJSWc0JTNE" -
trunk/sources/applications/applestreamingclient/include/clientcontext.h
r85 r88 61 61 uint32_t _currentItemIndex; 62 62 uint32_t _optimalBw; 63 uint32_t _lastUsedBw; 63 64 SpeedComputer *_pSpeedComputer; 64 65 uint32_t _scheduleTimerId; … … 69 70 StreamsManager *_pStreamsManager; 70 71 double _lastWallClock; 71 double _lastStreamClock;72 72 private: 73 73 ClientContext(); -
trunk/sources/applications/applestreamingclient/include/eventsink/baseeventsink.h
r58 r88 27 27 #define EVENT_SYNC_VARIANT MAKE_TAG3('V','A','R') 28 28 29 class ClientContext; 30 29 31 class BaseEventSink { 30 32 private: 31 33 uint64_t _type; 34 uint32_t _contextId; 32 35 public: 33 BaseEventSink(uint64_t type );36 BaseEventSink(uint64_t type, uint32_t contextId); 34 37 virtual ~BaseEventSink(); 35 38 36 39 uint64_t GetType(); 37 40 38 static BaseEventSink * GetInstance(uint64_t type );41 static BaseEventSink * GetInstance(uint64_t type, uint32_t contextId); 39 42 40 43 virtual bool SignalStreamRegistered(string streamName) = 0; 41 44 virtual bool SignalStreamUnRegistered(string streamName) = 0; 45 virtual bool SignalUpgradeBandwidth(uint32_t oldBw, uint32_t newBw) = 0; 46 virtual bool SignalDowngradeBandwidth(uint32_t oldBw, uint32_t newBw) = 0; 47 protected: 48 ClientContext *GetContext(); 42 49 }; 43 50 -
trunk/sources/applications/applestreamingclient/include/eventsink/rtmpeventsink.h
r47 r88 30 30 string _streamName; 31 31 public: 32 RTMPEventSink( );32 RTMPEventSink(uint32_t contextId); 33 33 virtual ~RTMPEventSink(); 34 34 … … 37 37 virtual bool SignalStreamRegistered(string streamName); 38 38 virtual bool SignalStreamUnRegistered(string streamName); 39 virtual bool SignalUpgradeBandwidth(uint32_t oldBw, uint32_t newBw); 40 virtual bool SignalDowngradeBandwidth(uint32_t oldBw, uint32_t newBw); 39 41 }; 40 42 -
trunk/sources/applications/applestreamingclient/include/eventsink/varianteventsink.h
r56 r88 28 28 private: 29 29 map<string, string> _streamNames; 30 string _rtspHost; 30 31 public: 31 VariantEventSink( );32 VariantEventSink(uint32_t contextId); 32 33 virtual ~VariantEventSink(); 33 34 34 35 virtual bool SignalStreamRegistered(string streamName); 35 36 virtual bool SignalStreamUnRegistered(string streamName); 36 37 virtual bool SignalUpgradeBandwidth(uint32_t oldBw, uint32_t newBw); 38 virtual bool SignalDowngradeBandwidth(uint32_t oldBw, uint32_t newBw); 37 39 vector<string> GetStreamNames(); 40 private: 41 #ifdef ANDROID 42 bool CallJava(Variant &message); 43 string GetRTSPHost(); 44 #endif 38 45 }; 39 46 -
trunk/sources/applications/applestreamingclient/src/clientcontext.cpp
r87 r88 44 44 _currentItemIndex = 0; 45 45 _optimalBw = 0; 46 _lastUsedBw = 0; 46 47 _pSpeedComputer = NULL; 47 48 _tsId = 0; … … 52 53 _pStreamsManager = NULL; 53 54 _lastWallClock = 0; 54 _lastStreamClock = 0;55 55 _avData.EnsureSize(_maxAVBufferSize * 3); 56 56 INFO("Context created: %d (%p)", _id, this); … … 103 103 pResult = new ClientContext(); 104 104 pResult->_applicationId = applicationId; 105 pResult->_pEventSink = BaseEventSink::GetInstance(masterProtocolType); 105 pResult->_pEventSink = BaseEventSink::GetInstance(masterProtocolType, 106 pResult->_id); 106 107 contextId = pResult->_id; 107 108 _contexts[pResult->_id] = pResult; … … 579 580 customParameters["itemUri"] = itemUri; 580 581 customParameters["bw"] = bw; 582 //replace(keyUri, "http://www.mlb.com", "https://qa.mlb.com"); 581 583 return FetchURI(keyUri, "key", customParameters); 582 584 } 583 585 584 586 bool ClientContext::FetchTS(string uri, uint32_t bw, string key, uint64_t iv) { 587 //1. Prepare custom parameters 585 588 Variant customParameters; 586 589 if (key == "") { … … 602 605 customParameters["iv"] = iv; 603 606 customParameters["bw"] = bw; 607 608 //2. setup last bw used 609 if (_lastUsedBw == 0) 610 _lastUsedBw = bw; 611 612 if (_lastUsedBw != bw) { 613 if (_pEventSink->GetType() == EVENT_SYNC_VARIANT) { 614 _avData.IgnoreAll(); 615 } 616 if (_lastUsedBw < bw) { 617 _pEventSink->SignalUpgradeBandwidth(_lastUsedBw, bw); 618 } else { 619 _pEventSink->SignalDowngradeBandwidth(_lastUsedBw, bw); 620 } 621 } 622 623 _lastUsedBw = bw; 624 625 604 626 return FetchURI(uri, "ts", customParameters); 605 627 } -
trunk/sources/applications/applestreamingclient/src/eventsink/baseeventsink.cpp
r31 r88 22 22 #include "protocols/protocoltypes.h" 23 23 #include "eventsink/varianteventsink.h" 24 #include "clientcontext.h" 24 25 25 BaseEventSink::BaseEventSink(uint64_t type ) {26 BaseEventSink::BaseEventSink(uint64_t type, uint32_t contextId) { 26 27 _type = type; 28 _contextId = contextId; 27 29 } 28 30 … … 34 36 } 35 37 36 BaseEventSink * BaseEventSink::GetInstance(uint64_t type ) {38 BaseEventSink * BaseEventSink::GetInstance(uint64_t type, uint32_t contextId) { 37 39 switch (type) { 38 40 #ifdef HAS_PROTOCOL_RTMP 39 41 case PT_INBOUND_RTMP: 40 42 { 41 return new RTMPEventSink( );43 return new RTMPEventSink(contextId); 42 44 } 43 45 #endif /* HAS_PROTOCOL_RTMP */ … … 46 48 case PT_BIN_VAR: 47 49 { 48 return new VariantEventSink( );50 return new VariantEventSink(contextId); 49 51 } 50 52 #endif /* HAS_PROTOCOL_VAR */ … … 56 58 } 57 59 } 60 61 ClientContext *BaseEventSink::GetContext() { 62 return ClientContext::GetContext(_contextId, 0, 0); 63 } -
trunk/sources/applications/applestreamingclient/src/eventsink/rtmpeventsink.cpp
r47 r88 24 24 #include "protocols/rtmp/messagefactories/messagefactories.h" 25 25 26 RTMPEventSink::RTMPEventSink( )27 : BaseEventSink(EVENT_SYNC_RTMP ) {26 RTMPEventSink::RTMPEventSink(uint32_t contextId) 27 : BaseEventSink(EVENT_SYNC_RTMP, contextId) { 28 28 _protocolId = 0; 29 29 _streamName = ""; … … 74 74 return true; 75 75 } 76 77 bool RTMPEventSink::SignalUpgradeBandwidth(uint32_t oldBw, uint32_t newBw) { 78 return true; 79 } 80 81 bool RTMPEventSink::SignalDowngradeBandwidth(uint32_t oldBw, uint32_t newBw) { 82 return true; 83 } 84 76 85 #endif /* HAS_PROTOCOL_RTMP */ -
trunk/sources/applications/applestreamingclient/src/eventsink/varianteventsink.cpp
r31 r88 21 21 #ifdef HAS_PROTOCOL_VAR 22 22 #include "eventsink/varianteventsink.h" 23 #include "clientcontext.h" 24 #include "applestreamingclientapplication.h" 25 #include "jnihelpers.h" 23 26 24 VariantEventSink::VariantEventSink( )25 : BaseEventSink(EVENT_SYNC_VARIANT ) {27 VariantEventSink::VariantEventSink(uint32_t contextId) 28 : BaseEventSink(EVENT_SYNC_VARIANT, contextId) { 26 29 } 27 30 … … 30 33 31 34 bool VariantEventSink::SignalStreamRegistered(string streamName) { 35 if (MAP_HAS1(_streamNames, streamName)) 36 return true; 32 37 _streamNames[streamName] = streamName; 38 #ifdef ANDROID 39 Variant message; 40 message["type"] = "streamNameRegistered"; 41 message["streamName"] = GetRTSPHost() + streamName; 42 return CallJava(message); 43 #else 33 44 return true; 45 #endif 34 46 } 35 47 36 48 bool VariantEventSink::SignalStreamUnRegistered(string streamName) { 37 49 _streamNames.erase(streamName); 50 #ifdef ANDROID 51 Variant message; 52 message["type"] = "streamNameUnRegistered"; 53 message["streamName"] = GetRTSPHost() + streamName; 54 return CallJava(message); 55 #else 38 56 return true; 57 #endif 58 } 59 60 bool VariantEventSink::SignalUpgradeBandwidth(uint32_t oldBw, uint32_t newBw) { 61 #ifdef ANDROID 62 Variant message; 63 message["type"] = "upgradeBandwidth"; 64 message["oldBw"] = (uint32_t) oldBw; 65 message["newBw"] = (uint32_t) newBw; 66 return CallJava(message); 67 #else 68 return true; 69 #endif 70 } 71 72 bool VariantEventSink::SignalDowngradeBandwidth(uint32_t oldBw, uint32_t newBw) { 73 #ifdef ANDROID 74 Variant message; 75 message["type"] = "downgradeBandwidth"; 76 message["oldBw"] = (uint32_t) oldBw; 77 message["newBw"] = (uint32_t) newBw; 78 return CallJava(message); 79 #else 80 return true; 81 #endif 39 82 } 40 83 … … 49 92 } 50 93 94 #ifdef ANDROID 95 96 bool VariantEventSink::CallJava(Variant& message) { 97 ClientContext *pContext = GetContext(); 98 if (pContext == NULL) { 99 FATAL("Unable to get context"); 100 return false; 101 } 102 AppleStreamingClientApplication *pApp = pContext->GetApplication(); 103 if (pApp == NULL) { 104 FATAL("Unable to get the application"); 105 return false; 106 } 107 CallBackInfo &ci = pApp->GetJavaCallBackInterface(); 108 FINEST("CallJava message:\n%s", STR(message.ToString())); 109 return ::CallJava(ci, message); 110 } 111 112 string VariantEventSink::GetRTSPHost() { 113 if (_rtspHost != "") 114 return _rtspHost; 115 ClientContext *pContext = GetContext(); 116 if (pContext == NULL) { 117 FATAL("Unable to get context"); 118 return false; 119 } 120 AppleStreamingClientApplication *pApp = pContext->GetApplication(); 121 _rtspHost = (string) pApp->GetConfiguration()["rtspHost"]; 122 return _rtspHost; 123 } 124 #endif 125 51 126 #endif /* HAS_PROTOCOL_VAR */ 52 127 -
trunk/sources/applications/applestreamingclient/src/jnihelpers.cpp
r85 r88 131 131 132 132 bool CallJava(CallBackInfo &ci, Variant ¶meters) { 133 if (ci.pEnv == NULL) { 134 WARN("No pEnv"); 135 return true; 136 } 137 if (ci.pInterface == NULL) { 138 WARN("No pInterface"); 139 return true; 140 } 133 141 ci.pEnv->PushLocalFrame(128); 134 142 if (ci.method == NULL) { -
trunk/sources/applications/flvplayback/flex/src/com/rtmpd/flvplayback.mxml
r2 r88 161 161 <mx:TextInput id="streamName" backgroundColor="#404040" width="100%" text="{_availableFlvs[dgFlvs.selectedIndex].flvName}"/> 162 162 <mx:Label text="Connecting string"/> 163 <mx:TextInput id="connectingString" text="rtmp:// localhost/flvplayback" backgroundColor="#404040" width="100%"/>163 <mx:TextInput id="connectingString" text="rtmp://10.0.2.1/flvplayback" backgroundColor="#404040" width="100%"/> 164 164 <mx:HBox width="100%"> 165 165 <mx:Button width="100%" label="{IsConnected?'Disconnect':'Connect'}" click="ConnectDisconnect();"/> -
trunk/sources/thelib/src/protocols/rtp/connectivity/outboundconnectivity.cpp
r87 r88 403 403 404 404 //6. RTP 405 // double rtpDouble; 406 // GETCLOCKS(rtpDouble); 407 // rtpDouble = (rtpDouble / CLOCKS_PER_SEC) * rate; 408 // uint32_t rtp = (uint32_t) rtpDouble; 409 // put_htonl(pDest + 16, rtp); 405 410 memcpy(pDest + 16, pSrc + 4, 4); 406 411 -
trunk/sources/thelib/src/protocols/rtp/streaming/outnetrtpudph264stream.cpp
r56 r88 185 185 totalLength -= 9; 186 186 } else { 187 if ((NALU_TYPE(pData[0]) != NALU_TYPE_SPS) 188 && (NALU_TYPE(pData[0]) != NALU_TYPE_PPS) 189 && (NALU_TYPE(pData[0]) != NALU_TYPE_SLICE) 187 if ( 188 // (NALU_TYPE(pData[0]) != NALU_TYPE_SPS) 189 // && (NALU_TYPE(pData[0]) != NALU_TYPE_PPS) 190 (NALU_TYPE(pData[0]) != NALU_TYPE_SLICE) 190 191 && (NALU_TYPE(pData[0]) != NALU_TYPE_IDR)) { 191 192 //FINEST("ignoring absoluteTimestamp: %.2f; %s", absoluteTimestamp, STR(NALUToString(pData[0]))); … … 194 195 } 195 196 196 if (processedLength == 0 && NALU_TYPE(pData[0]) == NALU_TYPE_IDR) {197 put_htons(_pSPS + 2, _videoCounter);198 _videoCounter++;199 put_htonl(_pSPS + 4, (uint32_t) (absoluteTimestamp * 90.0));200 put_htons(_pPPS + 2, _videoCounter);201 _videoCounter++;202 put_htonl(_pPPS + 4, (uint32_t) (absoluteTimestamp * 90.0));203 204 _pConnectivity->FeedVideoData(_pSPS, _SPSLen);205 _pConnectivity->FeedVideoData(_pPPS, _PPSLen);206 }197 // if (processedLength == 0 && NALU_TYPE(pData[0]) == NALU_TYPE_IDR) { 198 // put_htons(_pSPS + 2, _videoCounter); 199 // _videoCounter++; 200 // put_htonl(_pSPS + 4, (uint32_t) (absoluteTimestamp * 90.0)); 201 // put_htons(_pPPS + 2, _videoCounter); 202 // _videoCounter++; 203 // put_htonl(_pPPS + 4, (uint32_t) (absoluteTimestamp * 90.0)); 204 // 205 // _pConnectivity->FeedVideoData(_pSPS, _SPSLen); 206 // _pConnectivity->FeedVideoData(_pPPS, _PPSLen); 207 // } 207 208 208 209 uint32_t sentAmount = 0;
Note: See TracChangeset
for help on using the changeset viewer.
