Index: remoting/protocol/video_stub.h |
diff --git a/remoting/protocol/video_stub.h b/remoting/protocol/video_stub.h |
index 59c231ea8403982000112429e0d91ebca77bf52f..548d3f5f6d027e9c9f258710093cb8cc465c8057 100644 |
--- a/remoting/protocol/video_stub.h |
+++ b/remoting/protocol/video_stub.h |
@@ -16,8 +16,22 @@ namespace protocol { |
class VideoStub { |
public: |
- virtual void ProcessVideoPacket(scoped_ptr<VideoPacket> video_packet, |
- const base::Closure& done) = 0; |
+ // For each packet VideoStub calls the specified ProgressCallback to |
+ // notify about packet progress. SENT state may be skipped, if the packet is |
+ // processed locally. If SupportsAcks() returns true then DONE progress |
+ // notification is emitted only after the acknowledgment has been received. |
+ enum class PacketProgress { |
+ SENT, |
Wez
2015/02/03 00:54:32
Do we really need the "SENT" state? It ends up mak
Sergey Ulanov
2015/02/09 19:14:54
Reverted this change now. Using VideoFeedbackStub
|
+ DONE, |
+ }; |
+ typedef base::Callback<void(PacketProgress progress)> ProgressCallback; |
+ |
+ virtual void ProcessVideoPacket( |
+ scoped_ptr<VideoPacket> video_packet, |
+ const ProgressCallback& progress_callback) = 0; |
Wez
2015/02/03 00:54:32
This complicates the VideoStub interface quite a b
Sergey Ulanov
2015/02/09 19:14:54
Reverted this change now. Using VideoFeedbackStub
|
+ |
+ // Indicates that the connection supports video packet acknowledgments. |
+ virtual bool SupportsAcks() { return false; } |
protected: |
VideoStub() {} |