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

Unified Diff: dm/DM.cpp

Issue 1635443002: Revert of Prototype of RAW decoding in Skia. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « DEPS ('k') | gyp/android_deps.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dm/DM.cpp
diff --git a/dm/DM.cpp b/dm/DM.cpp
index 6f7c7a7b9480dc76a352659e54361f0bf89d5dca..25a12637887c8ecfc403c93ec1dac66948f321f9 100644
--- a/dm/DM.cpp
+++ b/dm/DM.cpp
@@ -503,20 +503,6 @@
return false;
}
-static bool is_raw(const SkString& file) {
- static const char* const exts[] = {
- "arw", "cr2", "dng", "nef", "nrw", "orf", "raf", "rw2", "pef", "srw",
- "ARW", "CR2", "DNG", "NEF", "NRW", "ORF", "RAF", "RW2", "PEF", "SRW",
- };
-
- for (uint32_t i = 0; i < SK_ARRAY_COUNT(exts); i++) {
- if (file.endsWith(exts[i])) {
- return true;
- }
- }
- return false;
-}
-
static void gather_srcs() {
for (const skiagm::GMRegistry* r = skiagm::GMRegistry::Head(); r; r = r->next()) {
push_src("gm", "", new GMSrc(r->factory()));
@@ -535,8 +521,6 @@
static const char* const exts[] = {
"bmp", "gif", "jpg", "jpeg", "png", "webp", "ktx", "astc", "wbmp", "ico",
"BMP", "GIF", "JPG", "JPEG", "PNG", "WEBP", "KTX", "ASTC", "WBMP", "ICO",
- "arw", "cr2", "dng", "nef", "nrw", "orf", "raf", "rw2", "pef", "srw",
- "ARW", "CR2", "DNG", "NEF", "NRW", "ORF", "RAF", "RW2", "PEF", "SRW",
};
for (int i = 0; i < FLAGS_images.count(); i++) {
const char* flag = FLAGS_images[i];
@@ -545,9 +529,7 @@
SkOSFile::Iter it(flag, exts[j]);
for (SkString file; it.next(&file); ) {
SkString path = SkOSPath::Join(flag, file.c_str());
- if (!is_raw(file)) {
- push_src("image", "decode", new ImageSrc(path)); // Decode entire image
- }
+ push_src("image", "decode", new ImageSrc(path)); // Decode entire image
push_codec_srcs(path);
if (brd_supported(exts[j])) {
push_brd_srcs(path);
@@ -556,9 +538,7 @@
}
} else if (sk_exists(flag)) {
// assume that FLAGS_images[i] is a valid image if it is a file.
- if (!is_raw(SkString(flag))) {
- push_src("image", "decode", new ImageSrc(flag)); // Decode entire image.
- }
+ push_src("image", "decode", new ImageSrc(flag)); // Decode entire image.
push_codec_srcs(flag);
push_brd_srcs(flag);
}
« no previous file with comments | « DEPS ('k') | gyp/android_deps.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698