Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(92)

Side by Side Diff: remoting/protocol/protobuf_video_writer.cc

Issue 4313001: Rename classes for Chromoting: (Closed) Base URL: http://git.chromium.org/git/chromium.git
Patch Set: Resolve merge conflicts Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « remoting/protocol/protobuf_video_writer.h ('k') | remoting/protocol/protocol_test_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "remoting/protocol/protobuf_video_writer.h" 5 #include "remoting/protocol/protobuf_video_writer.h"
6 6
7 #include "remoting/protocol/chromotocol_connection.h"
8 #include "remoting/protocol/rtp_writer.h" 7 #include "remoting/protocol/rtp_writer.h"
8 #include "remoting/protocol/session.h"
9 #include "remoting/protocol/util.h" 9 #include "remoting/protocol/util.h"
10 10
11 namespace remoting { 11 namespace remoting {
12 12
13 ProtobufVideoWriter::ProtobufVideoWriter() { } 13 ProtobufVideoWriter::ProtobufVideoWriter() { }
14 14
15 ProtobufVideoWriter::~ProtobufVideoWriter() { } 15 ProtobufVideoWriter::~ProtobufVideoWriter() { }
16 16
17 void ProtobufVideoWriter::Init(ChromotocolConnection* connection) { 17 void ProtobufVideoWriter::Init(protocol::Session* session) {
18 buffered_writer_ = new BufferedSocketWriter(); 18 buffered_writer_ = new BufferedSocketWriter();
19 // TODO(sergeyu): Provide WriteFailedCallback for the buffered writer. 19 // TODO(sergeyu): Provide WriteFailedCallback for the buffered writer.
20 buffered_writer_->Init(connection->video_channel(), NULL); 20 buffered_writer_->Init(session->video_channel(), NULL);
21 } 21 }
22 22
23 void ProtobufVideoWriter::SendPacket(const VideoPacket& packet) { 23 void ProtobufVideoWriter::SendPacket(const VideoPacket& packet) {
24 buffered_writer_->Write(SerializeAndFrameMessage(packet)); 24 buffered_writer_->Write(SerializeAndFrameMessage(packet));
25 } 25 }
26 26
27 int ProtobufVideoWriter::GetPendingPackets() { 27 int ProtobufVideoWriter::GetPendingPackets() {
28 return buffered_writer_->GetBufferChunks(); 28 return buffered_writer_->GetBufferChunks();
29 } 29 }
30 30
31 31
32 void ProtobufVideoWriter::Close() { 32 void ProtobufVideoWriter::Close() {
33 buffered_writer_->Close(); 33 buffered_writer_->Close();
34 } 34 }
35 35
36 } // namespace remoting 36 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/protocol/protobuf_video_writer.h ('k') | remoting/protocol/protocol_test_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698