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

Side by Side Diff: Source/platform/graphics/gpu/DrawingBuffer.h

Issue 749653002: WebGL: clarify which Front or Back buffer is used by each API. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase to ToT Created 6 years 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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2010, Google Inc. All rights reserved. 2 * Copyright (c) 2010, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after
156 virtual void mailboxReleased(const WebExternalTextureMailbox&, bool lostReso urce = false) override; 156 virtual void mailboxReleased(const WebExternalTextureMailbox&, bool lostReso urce = false) override;
157 157
158 enum SourceBuffer { Front, Back }; 158 enum SourceBuffer { Front, Back };
159 // Destroys the TEXTURE_2D binding for the owned context 159 // Destroys the TEXTURE_2D binding for the owned context
160 bool copyToPlatformTexture(WebGraphicsContext3D*, Platform3DObject texture, GLenum internalFormat, 160 bool copyToPlatformTexture(WebGraphicsContext3D*, Platform3DObject texture, GLenum internalFormat,
161 GLenum destType, GLint level, bool premultiplyAlpha, bool flipY, SourceB uffer); 161 GLenum destType, GLint level, bool premultiplyAlpha, bool flipY, SourceB uffer);
162 162
163 void setPackAlignment(GLint param); 163 void setPackAlignment(GLint param);
164 164
165 void paintRenderingResultsToCanvas(ImageBuffer*); 165 void paintRenderingResultsToCanvas(ImageBuffer*);
166 PassRefPtr<Uint8ClampedArray> paintRenderingResultsToImageData(int&, int&); 166 PassRefPtr<Uint8ClampedArray> paintRenderingResultsToImageData(int&, int&, S ourceBuffer);
167 167
168 protected: // For unittests 168 protected: // For unittests
169 DrawingBuffer( 169 DrawingBuffer(
170 PassOwnPtr<WebGraphicsContext3D>, 170 PassOwnPtr<WebGraphicsContext3D>,
171 PassOwnPtr<Extensions3DUtil>, 171 PassOwnPtr<Extensions3DUtil>,
172 bool multisampleExtensionSupported, 172 bool multisampleExtensionSupported,
173 bool packedDepthStencilExtensionSupported, 173 bool packedDepthStencilExtensionSupported,
174 bool discardFramebufferSupported, 174 bool discardFramebufferSupported,
175 PreserveDrawingBuffer, 175 PreserveDrawingBuffer,
176 WebGraphicsContext3D::Attributes requestedAttributes, 176 WebGraphicsContext3D::Attributes requestedAttributes,
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
304 // used to resize the Canvas. 304 // used to resize the Canvas.
305 SkBitmap m_resizingBitmap; 305 SkBitmap m_resizingBitmap;
306 306
307 // Used to flip a bitmap vertically. 307 // Used to flip a bitmap vertically.
308 Vector<uint8_t> m_scanline; 308 Vector<uint8_t> m_scanline;
309 }; 309 };
310 310
311 } // namespace blink 311 } // namespace blink
312 312
313 #endif // DrawingBuffer_h 313 #endif // DrawingBuffer_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698