Connect pacer/padding to SuspendBelowMinBitrate

The suspend function must not be engaged unless padding is also enabled.
This CL makes the connection so that the pacer and padding is enabled
when SuspendBelowMinBitrate is.

Had to change the unit test to make it aware of the padding packets.

BUG=2606
R=mflodman@webrtc.org, pbos@webrtc.org, stefan@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/4089004

git-svn-id: http://webrtc.googlecode.com/svn/trunk/webrtc@5153 4adac7df-926f-26a2-2b94-8c16560cd09d
diff --git a/video_engine/vie_codec_impl.cc b/video_engine/vie_codec_impl.cc
index 94e4d7c..364862f 100644
--- a/video_engine/vie_codec_impl.cc
+++ b/video_engine/vie_codec_impl.cc
@@ -724,7 +724,18 @@
                  "%s: No encoder %d", __FUNCTION__, video_channel);
     return;
   }
-  return vie_encoder->SuspendBelowMinBitrate();
+  vie_encoder->SuspendBelowMinBitrate();
+  ViEChannel* vie_channel = cs.Channel(video_channel);
+  if (!vie_channel) {
+    WEBRTC_TRACE(kTraceError, kTraceVideo,
+                 ViEId(shared_data_->instance_id(), video_channel),
+                 "%s: No channel %d", __FUNCTION__, video_channel);
+    return;
+  }
+  // Must enable pacing when enabling SuspendBelowMinBitrate. Otherwise, no
+  // padding will be sent when the video is suspended so the video will be
+  // unable to recover.
+  vie_channel->SetTransmissionSmoothingStatus(true);
 }
 
 bool ViECodecImpl::CodecValid(const VideoCodec& video_codec) {