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

Side by Side Diff: chromecast/media/cma/backend/audio_video_pipeline_device_unittest.cc

Issue 1490613005: media config: expand is_encrypted to a struct. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: one more tweak in chromecast/common Created 5 years 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 <vector> 5 #include <vector>
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 245 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 base::FilePath file_path = GetTestDataFilePath(filename); 256 base::FilePath file_path = GetTestDataFilePath(filename);
257 base::MemoryMappedFile video_stream; 257 base::MemoryMappedFile video_stream;
258 CHECK(video_stream.Initialize(file_path)) << "Couldn't open stream file: " 258 CHECK(video_stream.Initialize(file_path)) << "Couldn't open stream file: "
259 << file_path.MaybeAsASCII(); 259 << file_path.MaybeAsASCII();
260 buffers = H264SegmenterForTest(video_stream.data(), video_stream.length()); 260 buffers = H264SegmenterForTest(video_stream.data(), video_stream.length());
261 261
262 // TODO(erickung): Either pull data from stream or make caller specify value 262 // TODO(erickung): Either pull data from stream or make caller specify value
263 video_config.codec = kCodecH264; 263 video_config.codec = kCodecH264;
264 video_config.profile = kH264Main; 264 video_config.profile = kH264Main;
265 video_config.additional_config = NULL; 265 video_config.additional_config = NULL;
266 video_config.is_encrypted = false; 266 video_config.encryption_scheme = EncryptionScheme(false);
halliwell 2016/01/13 03:29:41 Good example of why this constructor isn't clear.
dougsteed 2016/02/09 22:58:53 Done.
267 } else { 267 } else {
268 base::FilePath file_path = GetTestDataFilePath(filename); 268 base::FilePath file_path = GetTestDataFilePath(filename);
269 DemuxResult demux_result = FFmpegDemuxForTest(file_path, false /* audio */); 269 DemuxResult demux_result = FFmpegDemuxForTest(file_path, false /* audio */);
270 buffers = demux_result.frames; 270 buffers = demux_result.frames;
271 video_config = DecoderConfigAdapter::ToCastVideoConfig( 271 video_config = DecoderConfigAdapter::ToCastVideoConfig(
272 kPrimary, demux_result.video_config); 272 kPrimary, demux_result.video_config);
273 } 273 }
274 274
275 MediaPipelineBackend::VideoDecoder* decoder = backend->CreateVideoDecoder(); 275 MediaPipelineBackend::VideoDecoder* decoder = backend->CreateVideoDecoder();
276 CHECK(decoder); 276 CHECK(decoder);
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
476 TEST_F(AudioVideoPipelineDeviceTest, WebmPlayback) { 476 TEST_F(AudioVideoPipelineDeviceTest, WebmPlayback) {
477 scoped_ptr<base::MessageLoop> message_loop(new base::MessageLoop()); 477 scoped_ptr<base::MessageLoop> message_loop(new base::MessageLoop());
478 478
479 ConfigureForFile("bear-640x360.webm"); 479 ConfigureForFile("bear-640x360.webm");
480 Start(); 480 Start();
481 message_loop->Run(); 481 message_loop->Run();
482 } 482 }
483 483
484 } // namespace media 484 } // namespace media
485 } // namespace chromecast 485 } // namespace chromecast
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698