| Index: cc/resources/resource_format.cc
|
| diff --git a/cc/resources/resource_format.cc b/cc/resources/resource_format.cc
|
| index 45581b800f140f3b6725a6bae4959686e66f03d0..a0cb0836738ad268df8d6554e6515d41374e0228 100644
|
| --- a/cc/resources/resource_format.cc
|
| +++ b/cc/resources/resource_format.cc
|
| @@ -13,6 +13,10 @@ SkColorType ResourceFormatToSkColorType(ResourceFormat format) {
|
| case RGBA_8888:
|
| case BGRA_8888:
|
| return kN32_SkColorType;
|
| + case ATC:
|
| + case ATC_IA:
|
| + case DXT1:
|
| + case DXT5:
|
| case ETC1:
|
| case ALPHA_8:
|
| case LUMINANCE_8:
|
| @@ -25,4 +29,17 @@ SkColorType ResourceFormatToSkColorType(ResourceFormat format) {
|
| return kN32_SkColorType;
|
| }
|
|
|
| +bool IsFormatCompressed(ResourceFormat format) {
|
| + switch (format) {
|
| + case ATC:
|
| + case ATC_IA:
|
| + case DXT1:
|
| + case DXT5:
|
| + case ETC1:
|
| + return true;
|
| + default:
|
| + return false;
|
| + }
|
| +}
|
| +
|
| } // namespace cc
|
|
|