Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 // This file contains structures used to represent SkBitmaps in Mojo. | |
| 6 module skia; | |
| 7 | |
| 8 // Mirror of SkColorType. | |
| 9 enum ColorType { | |
| 10 UNKNOWN, | |
| 11 ALPHA_8, | |
| 12 RGB_565, | |
| 13 ARGB_4444, | |
| 14 RGBA_8888, | |
| 15 BGRA_8888, | |
| 16 INDEX_8, | |
| 17 GRAY_8, | |
| 18 }; | |
| 19 | |
| 20 // Mirror of SkAlphaType. | |
| 21 enum AlphaType { | |
| 22 UNKNOWN, | |
| 23 OPAQUE, | |
| 24 PREMUL, | |
| 25 UNPREMUL, | |
| 26 }; | |
| 27 | |
| 28 // Mirror of SkColorProfileType. | |
| 29 enum ColorProfileType { | |
| 30 LINEAR, | |
| 31 SRGB, | |
| 32 }; | |
| 33 | |
| 34 struct Image { | |
|
Ken Rockot(use gerrit already)
2015/03/25 22:43:43
nit: Should this maybe be Bitmap? And bitmap.mojom
| |
| 35 ColorType color_type; | |
| 36 AlphaType alpha_type; | |
| 37 ColorProfileType profile_type; | |
| 38 | |
| 39 uint32 width; | |
| 40 uint32 height; | |
| 41 | |
| 42 array<uint8> pixel_data; | |
| 43 }; | |
| OLD | NEW |