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

Side by Side Diff: Source/platform/graphics/ImageBuffer.cpp

Issue 400543004: Rename WebCore namespace to blink in Platform (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « Source/platform/graphics/ImageBuffer.h ('k') | Source/platform/graphics/ImageBufferClient.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2008, Google Inc. All rights reserved. 2 * Copyright (c) 2008, Google Inc. All rights reserved.
3 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org> 3 * Copyright (C) 2009 Dirk Schulze <krit@webkit.org>
4 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved. 4 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved.
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions are 7 * modification, are permitted provided that the following conditions are
8 * met: 8 * met:
9 * 9 *
10 * * Redistributions of source code must retain the above copyright 10 * * Redistributions of source code must retain the above copyright
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
52 #include "public/platform/WebExternalTextureMailbox.h" 52 #include "public/platform/WebExternalTextureMailbox.h"
53 #include "public/platform/WebGraphicsContext3D.h" 53 #include "public/platform/WebGraphicsContext3D.h"
54 #include "public/platform/WebGraphicsContext3DProvider.h" 54 #include "public/platform/WebGraphicsContext3DProvider.h"
55 #include "third_party/skia/include/effects/SkTableColorFilter.h" 55 #include "third_party/skia/include/effects/SkTableColorFilter.h"
56 #include "wtf/MathExtras.h" 56 #include "wtf/MathExtras.h"
57 #include "wtf/text/Base64.h" 57 #include "wtf/text/Base64.h"
58 #include "wtf/text/WTFString.h" 58 #include "wtf/text/WTFString.h"
59 59
60 using namespace std; 60 using namespace std;
61 61
62 namespace WebCore { 62 namespace blink {
63 63
64 PassOwnPtr<ImageBuffer> ImageBuffer::create(PassOwnPtr<ImageBufferSurface> surfa ce) 64 PassOwnPtr<ImageBuffer> ImageBuffer::create(PassOwnPtr<ImageBufferSurface> surfa ce)
65 { 65 {
66 if (!surface->isValid()) 66 if (!surface->isValid())
67 return nullptr; 67 return nullptr;
68 return adoptPtr(new ImageBuffer(surface)); 68 return adoptPtr(new ImageBuffer(surface));
69 } 69 }
70 70
71 PassOwnPtr<ImageBuffer> ImageBuffer::create(const IntSize& size, OpacityMode opa cityMode) 71 PassOwnPtr<ImageBuffer> ImageBuffer::create(const IntSize& size, OpacityMode opa cityMode)
72 { 72 {
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
414 Vector<char> encodedImage; 414 Vector<char> encodedImage;
415 if (!encodeImage(imageData, mimeType, quality, &encodedImage)) 415 if (!encodeImage(imageData, mimeType, quality, &encodedImage))
416 return "data:,"; 416 return "data:,";
417 417
418 Vector<char> base64Data; 418 Vector<char> base64Data;
419 base64Encode(encodedImage, base64Data); 419 base64Encode(encodedImage, base64Data);
420 420
421 return "data:" + mimeType + ";base64," + base64Data; 421 return "data:" + mimeType + ";base64," + base64Data;
422 } 422 }
423 423
424 } // namespace WebCore 424 } // namespace blink
OLDNEW
« no previous file with comments | « Source/platform/graphics/ImageBuffer.h ('k') | Source/platform/graphics/ImageBufferClient.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698