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

Side by Side Diff: media/formats/mp4/avc_unittest.cc

Issue 2640113004: Introduce Dolby Vision video codec and Demuxer support (Closed)
Patch Set: fix build break on Android Created 3 years, 9 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/formats/mp4/avc.cc ('k') | media/formats/mp4/box_definitions.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 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 <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 #include <string.h> 7 #include <string.h>
8 8
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/strings/string_split.h" 10 #include "base/strings/string_split.h"
(...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after
441 avc_config.pps_list[0].push_back(0x68); 441 avc_config.pps_list[0].push_back(0x68);
442 avc_config.pps_list[0].push_back(0x56); 442 avc_config.pps_list[0].push_back(0x56);
443 avc_config.pps_list[0].push_back(0x78); 443 avc_config.pps_list[0].push_back(0x78);
444 444
445 for (size_t i = 0; i < arraysize(test_cases); ++i) { 445 for (size_t i = 0; i < arraysize(test_cases); ++i) {
446 std::vector<uint8_t> buf; 446 std::vector<uint8_t> buf;
447 std::vector<SubsampleEntry> subsamples; 447 std::vector<SubsampleEntry> subsamples;
448 448
449 StringToAnnexB(test_cases[i].input, &buf, &subsamples); 449 StringToAnnexB(test_cases[i].input, &buf, &subsamples);
450 450
451 EXPECT_TRUE(AVC::InsertParamSetsAnnexB(avc_config, &buf, &subsamples)) 451 EXPECT_TRUE(AVC::InsertParamSetsAnnexB(avc_config, &buf, &subsamples, true))
452 << "'" << test_cases[i].input << "' insert failed."; 452 << "'" << test_cases[i].input << "' insert failed.";
453 EXPECT_TRUE(AVC::IsValidAnnexB(buf, subsamples)) 453 EXPECT_TRUE(AVC::IsValidAnnexB(buf, subsamples))
454 << "'" << test_cases[i].input << "' created invalid AnnexB."; 454 << "'" << test_cases[i].input << "' created invalid AnnexB.";
455 EXPECT_EQ(test_cases[i].expected, AnnexBToString(buf, subsamples)) 455 EXPECT_EQ(test_cases[i].expected, AnnexBToString(buf, subsamples))
456 << "'" << test_cases[i].input << "' generated unexpected output."; 456 << "'" << test_cases[i].input << "' generated unexpected output.";
457 } 457 }
458 } 458 }
459 459
460 } // namespace mp4 460 } // namespace mp4
461 } // namespace media 461 } // namespace media
OLDNEW
« no previous file with comments | « media/formats/mp4/avc.cc ('k') | media/formats/mp4/box_definitions.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698