| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef REMOTING_HOST_RECORD_SESSION_H_ | 5 #ifndef REMOTING_HOST_RECORD_SESSION_H_ |
| 6 #define REMOTING_HOST_RECORD_SESSION_H_ | 6 #define REMOTING_HOST_RECORD_SESSION_H_ |
| 7 | 7 |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 97 private: | 97 private: |
| 98 void DoStart(); | 98 void DoStart(); |
| 99 void DoPause(); | 99 void DoPause(); |
| 100 void DoStartRateControl(); | 100 void DoStartRateControl(); |
| 101 void DoPauseRateControl(); | 101 void DoPauseRateControl(); |
| 102 | 102 |
| 103 void DoCapture(); | 103 void DoCapture(); |
| 104 void DoFinishEncode(); | 104 void DoFinishEncode(); |
| 105 void DoEncode(); | 105 void DoEncode(); |
| 106 void DoSendUpdate( | 106 void DoSendUpdate( |
| 107 chromotocol_pb::UpdateStreamPacketHeader* header, | 107 UpdateStreamPacketHeader* header, |
| 108 scoped_refptr<media::DataBuffer> encoded_data, | 108 scoped_refptr<media::DataBuffer> encoded_data, |
| 109 bool begin_update, | 109 bool begin_update, |
| 110 bool end_update); | 110 bool end_update); |
| 111 void DoSendInit(scoped_refptr<ClientConnection> client, | 111 void DoSendInit(scoped_refptr<ClientConnection> client, |
| 112 int width, int height); | 112 int width, int height); |
| 113 void DoGetInitInfo(scoped_refptr<ClientConnection> client); | 113 void DoGetInitInfo(scoped_refptr<ClientConnection> client); |
| 114 void DoSetRate(double rate); | 114 void DoSetRate(double rate); |
| 115 void DoSetMaxRate(double max_rate); | 115 void DoSetMaxRate(double max_rate); |
| 116 void DoAddClient(scoped_refptr<ClientConnection> client); | 116 void DoAddClient(scoped_refptr<ClientConnection> client); |
| 117 void DoRemoveClient(scoped_refptr<ClientConnection> client); | 117 void DoRemoveClient(scoped_refptr<ClientConnection> client); |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 bool rate_control_started_; | 161 bool rate_control_started_; |
| 162 | 162 |
| 163 // Stores the data and information of the last capture done. | 163 // Stores the data and information of the last capture done. |
| 164 // These members are written on capture thread and read on encode thread. | 164 // These members are written on capture thread and read on encode thread. |
| 165 // It is guranteed the read happens after the write. | 165 // It is guranteed the read happens after the write. |
| 166 DirtyRects capture_dirty_rects_; | 166 DirtyRects capture_dirty_rects_; |
| 167 const uint8* capture_data_[3]; | 167 const uint8* capture_data_[3]; |
| 168 int capture_data_strides_[3]; | 168 int capture_data_strides_[3]; |
| 169 int capture_width_; | 169 int capture_width_; |
| 170 int capture_height_; | 170 int capture_height_; |
| 171 chromotocol_pb::PixelFormat capture_pixel_format_; | 171 PixelFormat capture_pixel_format_; |
| 172 | 172 |
| 173 // The following members are accessed on the encode thread. | 173 // The following members are accessed on the encode thread. |
| 174 // Output parameter written by Encoder to carry encoded data. | 174 // Output parameter written by Encoder to carry encoded data. |
| 175 chromotocol_pb::UpdateStreamPacketHeader encoded_data_header_; | 175 UpdateStreamPacketHeader encoded_data_header_; |
| 176 scoped_refptr<media::DataBuffer> encoded_data_; | 176 scoped_refptr<media::DataBuffer> encoded_data_; |
| 177 | 177 |
| 178 // True if we have started receiving encoded data from the Encoder. | 178 // True if we have started receiving encoded data from the Encoder. |
| 179 bool encode_stream_started_; | 179 bool encode_stream_started_; |
| 180 | 180 |
| 181 // Output parameter written by Encoder to notify the end of encoded data | 181 // Output parameter written by Encoder to notify the end of encoded data |
| 182 // stream. | 182 // stream. |
| 183 bool encode_done_; | 183 bool encode_done_; |
| 184 | 184 |
| 185 DISALLOW_COPY_AND_ASSIGN(SessionManager); | 185 DISALLOW_COPY_AND_ASSIGN(SessionManager); |
| 186 }; | 186 }; |
| 187 | 187 |
| 188 } // namespace remoting | 188 } // namespace remoting |
| 189 | 189 |
| 190 #endif // REMOTING_HOST_RECORD_SESSION_H_ | 190 #endif // REMOTING_HOST_RECORD_SESSION_H_ |
| OLD | NEW |