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

Issue 2182633012: Add Matrix4x3 and tristimulus class to color utiliies. (Closed)

Created:
4 years, 4 months ago by hubbe
Modified:
4 years, 4 months ago
Reviewers:
ccameron
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Add Matrix4x3 and tristimulus class to color utiliies. The TriStim class represents a color in any color space, it will be used as input/output to the ColorTransform class. The Matrix4x3 class will be used both by the ColorTransform class and to store the primary color transofmration in the ColorSpace class if primary_ == PrimaryID::CUSTOM. BUG=622133

Patch Set 1 #

Patch Set 2 : added test #

Unified diffs Side-by-side diffs Delta from patch set Stats (+146 lines, -1 line) Patch
M ui/gfx/color_utils.h View 1 1 chunk +36 lines, -0 lines 0 comments Download
M ui/gfx/color_utils.cc View 1 2 chunks +83 lines, -1 line 0 comments Download
M ui/gfx/color_utils_unittest.cc View 1 1 chunk +27 lines, -0 lines 0 comments Download

Messages

Total messages: 9 (6 generated)
hubbe
4 years, 4 months ago (2016-07-27 21:38:57 UTC) #4
ccameron
I don't think that we should add these structures -- we already have a robust ...
4 years, 4 months ago (2016-07-27 21:57:05 UTC) #5
hubbe
4 years, 4 months ago (2016-07-27 22:03:32 UTC) #6
On 2016/07/27 21:57:05, ccameron wrote:
> I don't think that we should add these structures -- we already have a robust
> 4x4 matrix library in gfx::Transform aka SkMatrix44 -- we should use that, and
> explicitly set the bottom row to [0 0 0 1].
> 
> IMO gfx::ColorSpace should just have a
>   float custom_matrix[12];
> 
> And then gfx::ColorTransform can internally convert that into and manipulate
via
> SkMatrix44 (or gfx::Transform).

Ah, missed that one, will delete this CL soon then.

Powered by Google App Engine
This is Rietveld 408576698