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

Side by Side Diff: ui/gfx/color_transform_unittest.cc

Issue 2342963003: Support ARIB STD B67, aka hybrid-log gamma (HLG) transfer function. (Closed)
Patch Set: nit Created 4 years, 3 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 | « ui/gfx/color_transform.cc ('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 (c) 2016 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2016 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 "base/logging.h" 5 #include "base/logging.h"
6 #include "testing/gtest/include/gtest/gtest.h" 6 #include "testing/gtest/include/gtest/gtest.h"
7 #include "ui/gfx/color_space.h" 7 #include "ui/gfx/color_space.h"
8 #include "ui/gfx/color_transform.h" 8 #include "ui/gfx/color_transform.h"
9 #include "ui/gfx/icc_profile.h" 9 #include "ui/gfx/icc_profile.h"
10 #include "ui/gfx/transform.h" 10 #include "ui/gfx/transform.h"
(...skipping 15 matching lines...) Expand all
26 }; 26 };
27 27
28 ColorSpace::TransferID all_transfers[] = { 28 ColorSpace::TransferID all_transfers[] = {
29 ColorSpace::TransferID::BT709, ColorSpace::TransferID::GAMMA22, 29 ColorSpace::TransferID::BT709, ColorSpace::TransferID::GAMMA22,
30 ColorSpace::TransferID::GAMMA28, ColorSpace::TransferID::SMPTE170M, 30 ColorSpace::TransferID::GAMMA28, ColorSpace::TransferID::SMPTE170M,
31 ColorSpace::TransferID::SMPTE240M, ColorSpace::TransferID::LINEAR, 31 ColorSpace::TransferID::SMPTE240M, ColorSpace::TransferID::LINEAR,
32 ColorSpace::TransferID::LOG, ColorSpace::TransferID::LOG_SQRT, 32 ColorSpace::TransferID::LOG, ColorSpace::TransferID::LOG_SQRT,
33 ColorSpace::TransferID::IEC61966_2_4, ColorSpace::TransferID::BT1361_ECG, 33 ColorSpace::TransferID::IEC61966_2_4, ColorSpace::TransferID::BT1361_ECG,
34 ColorSpace::TransferID::IEC61966_2_1, ColorSpace::TransferID::BT2020_10, 34 ColorSpace::TransferID::IEC61966_2_1, ColorSpace::TransferID::BT2020_10,
35 ColorSpace::TransferID::BT2020_12, ColorSpace::TransferID::SMPTEST2084, 35 ColorSpace::TransferID::BT2020_12, ColorSpace::TransferID::SMPTEST2084,
36 ColorSpace::TransferID::ARIB_STD_B67,
36 // This one is weird as the non-linear numbers are not between 0 and 1. 37 // This one is weird as the non-linear numbers are not between 0 and 1.
37 // TODO(hubbe): Test this separately. 38 // TODO(hubbe): Test this separately.
38 // ColorSpace::TransferID::SMPTEST428_1, 39 // ColorSpace::TransferID::SMPTEST428_1,
39 }; 40 };
40 41
41 ColorSpace::MatrixID all_matrices[] = { 42 ColorSpace::MatrixID all_matrices[] = {
42 ColorSpace::MatrixID::RGB, ColorSpace::MatrixID::BT709, 43 ColorSpace::MatrixID::RGB, ColorSpace::MatrixID::BT709,
43 ColorSpace::MatrixID::UNSPECIFIED, ColorSpace::MatrixID::RESERVED, 44 ColorSpace::MatrixID::UNSPECIFIED, ColorSpace::MatrixID::RESERVED,
44 ColorSpace::MatrixID::FCC, ColorSpace::MatrixID::BT470BG, 45 ColorSpace::MatrixID::FCC, ColorSpace::MatrixID::BT470BG,
45 ColorSpace::MatrixID::SMPTE170M, ColorSpace::MatrixID::SMPTE240M, 46 ColorSpace::MatrixID::SMPTE170M, ColorSpace::MatrixID::SMPTE240M,
(...skipping 478 matching lines...) Expand 10 before | Expand all | Expand 10 after
524 testing::ValuesIn(all_ranges))); 525 testing::ValuesIn(all_ranges)));
525 526
526 INSTANTIATE_TEST_CASE_P( 527 INSTANTIATE_TEST_CASE_P(
527 C, 528 C,
528 ColorSpaceTest, 529 ColorSpaceTest,
529 testing::Combine(testing::ValuesIn(all_primaries), 530 testing::Combine(testing::ValuesIn(all_primaries),
530 testing::Values(ColorSpace::TransferID::BT709), 531 testing::Values(ColorSpace::TransferID::BT709),
531 testing::ValuesIn(all_matrices), 532 testing::ValuesIn(all_matrices),
532 testing::ValuesIn(all_ranges))); 533 testing::ValuesIn(all_ranges)));
533 } // namespace 534 } // namespace
OLDNEW
« no previous file with comments | « ui/gfx/color_transform.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698