OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2010 Apple Inc. All rights reserved. |
3 * Copyright (C) 2010 Google Inc. All rights reserved. | 3 * Copyright (C) 2010 Google Inc. All rights reserved. |
4 * Copyright (C) 2010 Mozilla Corporation. All rights reserved. | 4 * Copyright (C) 2010 Mozilla Corporation. 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 | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 11 matching lines...) Expand all Loading... |
22 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY | 22 * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY |
23 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 23 * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
25 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 25 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
26 */ | 26 */ |
27 | 27 |
28 #include "config.h" | 28 #include "config.h" |
29 | 29 |
30 #include "core/platform/graphics/GraphicsContext3D.h" | 30 #include "core/platform/graphics/GraphicsContext3D.h" |
31 | 31 |
32 #include "core/platform/graphics/Extensions3D.h" | |
33 #include "core/platform/graphics/GraphicsContext.h" | 32 #include "core/platform/graphics/GraphicsContext.h" |
34 #include "core/platform/graphics/Image.h" | |
35 #include "core/platform/graphics/ImageBuffer.h" | 33 #include "core/platform/graphics/ImageBuffer.h" |
36 #include "core/platform/graphics/gpu/DrawingBuffer.h" | 34 #include "core/platform/graphics/gpu/DrawingBuffer.h" |
37 #include "core/platform/image-decoders/ImageDecoder.h" | 35 #include "core/platform/image-decoders/ImageDecoder.h" |
38 #include "platform/CheckedInt.h" | 36 #include "platform/CheckedInt.h" |
39 #include "platform/graphics/ImageObserver.h" | 37 #include "platform/graphics/ImageObserver.h" |
40 #include "third_party/skia/include/gpu/GrContext.h" | 38 #include "third_party/skia/include/gpu/GrContext.h" |
41 #include "third_party/skia/include/gpu/gl/GrGLInterface.h" | 39 #include "third_party/skia/include/gpu/gl/GrGLInterface.h" |
42 #include "wtf/CPU.h" | 40 #include "wtf/CPU.h" |
43 #include "wtf/OwnPtr.h" | |
44 #include "wtf/PassOwnPtr.h" | |
45 #include "wtf/text/CString.h" | 41 #include "wtf/text/CString.h" |
46 #include "wtf/text/StringHash.h" | 42 #include "wtf/text/StringHash.h" |
47 #include "wtf/text/WTFString.h" | |
48 | 43 |
49 #include "public/platform/Platform.h" | 44 #include "public/platform/Platform.h" |
50 #include "public/platform/WebGraphicsContext3D.h" | 45 #include "public/platform/WebGraphicsContext3D.h" |
51 #include "public/platform/WebGraphicsContext3DProvider.h" | 46 #include "public/platform/WebGraphicsContext3DProvider.h" |
52 | 47 |
53 namespace WebCore { | 48 namespace WebCore { |
54 | 49 |
55 namespace { | 50 namespace { |
56 | 51 |
57 void getDrawingParameters(DrawingBuffer* drawingBuffer, blink::WebGraphicsContex
t3D* graphicsContext3D, | 52 void getDrawingParameters(DrawingBuffer* drawingBuffer, blink::WebGraphicsContex
t3D* graphicsContext3D, |
(...skipping 883 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
941 for (unsigned i = 0; i < count; i++) { | 936 for (unsigned i = 0; i < count; i++) { |
942 uint8* rowA = framebuffer + i * rowBytes; | 937 uint8* rowA = framebuffer + i * rowBytes; |
943 uint8* rowB = framebuffer + (height - i - 1) * rowBytes; | 938 uint8* rowB = framebuffer + (height - i - 1) * rowBytes; |
944 memcpy(scanline, rowB, rowBytes); | 939 memcpy(scanline, rowB, rowBytes); |
945 memcpy(rowB, rowA, rowBytes); | 940 memcpy(rowB, rowA, rowBytes); |
946 memcpy(rowA, scanline, rowBytes); | 941 memcpy(rowA, scanline, rowBytes); |
947 } | 942 } |
948 } | 943 } |
949 | 944 |
950 } // namespace WebCore | 945 } // namespace WebCore |
OLD | NEW |