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

Side by Side Diff: media/cast/test/sender.cc

Issue 279833003: Cast: Add missing enum and PacketEvent field to cast_messages. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 7 months 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
« no previous file with comments | « media/cast/logging/logging_defines.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 // Test application that simulates a cast sender - Data can be either generated 5 // Test application that simulates a cast sender - Data can be either generated
6 // or read from a file. 6 // or read from a file.
7 7
8 #include <queue> 8 #include <queue>
9 9
10 #include "base/at_exit.h" 10 #include "base/at_exit.h"
(...skipping 727 matching lines...) Expand 10 before | Expand all | Expand 10 after
738 738
739 DISALLOW_COPY_AND_ASSIGN(SendProcess); 739 DISALLOW_COPY_AND_ASSIGN(SendProcess);
740 }; 740 };
741 741
742 } // namespace cast 742 } // namespace cast
743 } // namespace media 743 } // namespace media
744 744
745 namespace { 745 namespace {
746 void UpdateCastTransportStatus( 746 void UpdateCastTransportStatus(
747 media::cast::transport::CastTransportStatus status) { 747 media::cast::transport::CastTransportStatus status) {
748 VLOG(21) << "Transport status: " << status; 748 VLOG(1) << "Transport status: " << status;
749 } 749 }
750 750
751 void LogRawEvents( 751 void LogRawEvents(
752 const scoped_refptr<media::cast::CastEnvironment>& cast_environment, 752 const scoped_refptr<media::cast::CastEnvironment>& cast_environment,
753 const std::vector<media::cast::PacketEvent>& packet_events) { 753 const std::vector<media::cast::PacketEvent>& packet_events) {
754 VLOG(1) << "Got packet events from transport, size: " << packet_events.size(); 754 VLOG(1) << "Got packet events from transport, size: " << packet_events.size();
755 for (std::vector<media::cast::PacketEvent>::const_iterator it = 755 for (std::vector<media::cast::PacketEvent>::const_iterator it =
756 packet_events.begin(); 756 packet_events.begin();
757 it != packet_events.end(); 757 it != packet_events.end();
758 ++it) { 758 ++it) {
759 cast_environment->Logging()->InsertPacketEvent(it->timestamp, 759 cast_environment->Logging()->InsertPacketEvent(it->timestamp,
760 it->type, 760 it->type,
761 it->media_type,
761 it->rtp_timestamp, 762 it->rtp_timestamp,
762 it->frame_id, 763 it->frame_id,
763 it->packet_id, 764 it->packet_id,
764 it->max_packet_id, 765 it->max_packet_id,
765 it->size); 766 it->size);
766 } 767 }
767 } 768 }
768 769
769 void InitializationResult(media::cast::CastInitializationStatus result) { 770 void InitializationResult(media::cast::CastInitializationStatus result) {
770 bool end_result = result == media::cast::STATUS_AUDIO_INITIALIZED || 771 bool end_result = result == media::cast::STATUS_AUDIO_INITIALIZED ||
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after
1010 base::Passed(&audio_stats_subscriber), 1011 base::Passed(&audio_stats_subscriber),
1011 base::Passed(&offset_estimator)), 1012 base::Passed(&offset_estimator)),
1012 base::TimeDelta::FromSeconds(logging_duration_seconds)); 1013 base::TimeDelta::FromSeconds(logging_duration_seconds));
1013 1014
1014 send_process->Start(cast_sender->audio_frame_input(), 1015 send_process->Start(cast_sender->audio_frame_input(),
1015 cast_sender->video_frame_input()); 1016 cast_sender->video_frame_input());
1016 1017
1017 io_message_loop.Run(); 1018 io_message_loop.Run();
1018 return 0; 1019 return 0;
1019 } 1020 }
OLDNEW
« no previous file with comments | « media/cast/logging/logging_defines.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698