OSDN Git Service

RIO-8829: Fix issue where an RTSP server returns a start NPT that is non-zero despite...
authorPacketVideo CM <engbuild@pv.com>
Sat, 27 Mar 2010 02:09:13 +0000 (19:09 -0700)
committerPacketVideo CM <engbuild@pv.com>
Sat, 27 Mar 2010 02:09:13 +0000 (19:09 -0700)
Change-Id: Ib568a92c7d272105636c9e1f6ddf8e03c69d2052

engines/2way/src/pv_2way_sdkinfo.h
engines/author/src/pv_author_sdkinfo.h
engines/player/src/pv_player_sdkinfo.h
nodes/streaming/streamingmanager/plugins/rtspunicast/src/pvmf_sm_fsp_rtsp_unicast.cpp

index 2052128..5bb3a02 100644 (file)
@@ -21,7 +21,7 @@
 // This header file is automatically generated at build-time
 // *** OFFICIAL RELEASE INFO -- Will not auto update
 
-#define PV2WAY_ENGINE_SDKINFO_LABEL "1327856"
-#define PV2WAY_ENGINE_SDKINFO_DATE 0x20100317
+#define PV2WAY_ENGINE_SDKINFO_LABEL "1329629"
+#define PV2WAY_ENGINE_SDKINFO_DATE 0x20100318
 
 #endif //PV_2WAY_SDKINFO_H_INCLUDED
index 1d0ba01..38c0c2b 100644 (file)
@@ -21,7 +21,7 @@
 // This header file is automatically generated at build-time
 // *** OFFICIAL RELEASE INFO -- Will not auto update
 
-#define PVAUTHOR_ENGINE_SDKINFO_LABEL "1327856"
-#define PVAUTHOR_ENGINE_SDKINFO_DATE 0x20100317
+#define PVAUTHOR_ENGINE_SDKINFO_LABEL "1329629"
+#define PVAUTHOR_ENGINE_SDKINFO_DATE 0x20100318
 
 #endif //PV_AUTHOR_SDKINFO_H_INCLUDED
index 705e81a..8a9ff2c 100644 (file)
@@ -21,7 +21,7 @@
 // This header file is automatically generated at build-time
 // *** OFFICIAL RELEASE INFO -- Will not auto update
 
-#define PVPLAYER_ENGINE_SDKINFO_LABEL "1327856"
-#define PVPLAYER_ENGINE_SDKINFO_DATE 0x20100317
+#define PVPLAYER_ENGINE_SDKINFO_LABEL "1329629"
+#define PVPLAYER_ENGINE_SDKINFO_DATE 0x20100318
 
 #endif //PV_PLAYER_SDKINFO_H_INCLUDED
index 6228d77..71b17e1 100644 (file)
@@ -3664,12 +3664,16 @@ void PVMFSMRTSPUnicastNode::DoSetDataSourcePosition(PVMFSMFSPBaseNodeCommand& aC
             }
 
             /*
-             * SetDataSource from a prepared state could mean two things:
-             *  - In Play-Stop-Play usecase engine does a SetDataSourcePosition
-             *    to get the start media TS to set its playback clock
-             *  - Engine is trying to do a play with a non-zero start offset
+             * We will always try to move the sm node to started state(and therefore do buffering etc)
+             * in the impl of the SetDataSourcePosition
+             * We will do this even if iRepositionRequestedStartNPTInMS is zero.
+             * Reason - It might be possible that user request the streaming session from 0 npt
+             * but, due to some reasons, server is able to stream from the x npt and does
+             * specify it in the Range header of Play response.
+             * This "x" npt need to be communicated to the engine in the completion of
+             * SetDataSourcePosition command.
              */
-            if (iRepositionRequestedStartNPTInMS < iSessionStopTime && iRepositionRequestedStartNPTInMS > iSessionStartTime)
+            if ((iRepositionRequestedStartNPTInMS < iSessionStopTime) && (iRepositionRequestedStartNPTInMS >= iSessionStartTime))
             {
                 // we need to use part of the logic of repositioning to start
                 // streaming from a non-zero offset. Enabled only for 3gpp streaming
@@ -3685,11 +3689,12 @@ void PVMFSMRTSPUnicastNode::DoSetDataSourcePosition(PVMFSMFSPBaseNodeCommand& aC
                 MoveCmdToCurrentQueue(aCmd);
                 return;
             }
-
-            *iActualRepositionStartNPTInMSPtr = iSessionStartTime;
-            GetActualMediaTSAfterSeek();
-            PVMF_SM_RTSP_LOG_COMMAND_SEQ((0, "PVMFSMRTSPUnicastNode::SetDataSourcePosition() - CmdComplete"));
-            CommandComplete(iInputCommands, aCmd, PVMFSuccess);
+            else
+            {
+                PVLOGGER_LOGMSG(PVLOGMSG_INST_HLDBG, iLogger, PVLOGMSG_ERR, (0, "PVMFSMRTSPUnicastNode::DoSetDataSourcePosition - Invalid value of iRepositionRequestedStartNPTInMS [%u] -- should have been between [%u] - [%u]", iRepositionRequestedStartNPTInMS, iSessionStartTime, iSessionStopTime));
+                CommandComplete(iInputCommands, aCmd, PVMFErrArgument);
+                return;
+            }
         }
         else if ((iInterfaceState == EPVMFNodeStarted) || (iInterfaceState == EPVMFNodePaused))
         {