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

Unified Diff: third_party/WebKit/Source/modules/webgl/WebGL2RenderingContextBase.cpp

Issue 1566283003: Upgrade blink side ReadPixels size validation to consider ES3 pack parameters. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase 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
Index: third_party/WebKit/Source/modules/webgl/WebGL2RenderingContextBase.cpp
diff --git a/third_party/WebKit/Source/modules/webgl/WebGL2RenderingContextBase.cpp b/third_party/WebKit/Source/modules/webgl/WebGL2RenderingContextBase.cpp
index 9478f11f692f61e4fbb2de8e7cc50f06fa6f1954..dc6b2750e4e5492f44d137fed276aa0ad3fc29d4 100644
--- a/third_party/WebKit/Source/modules/webgl/WebGL2RenderingContextBase.cpp
+++ b/third_party/WebKit/Source/modules/webgl/WebGL2RenderingContextBase.cpp
@@ -3443,4 +3443,26 @@ const WebGLSamplerState* WebGL2RenderingContextBase::getTextureUnitSamplerState(
return WebGLRenderingContextBase::getTextureUnitSamplerState(target, unit);
}
+WebGLImageConversion::PixelStoreParams WebGL2RenderingContextBase::getPackPixelStoreParams()
+{
+ WebGLImageConversion::PixelStoreParams params;
+ params.alignment = m_packAlignment;
+ params.rowLength = m_packRowLength;
+ params.skipPixels = m_packSkipPixels;
+ params.skipRows = m_packSkipRows;
+ return params;
+}
+
+WebGLImageConversion::PixelStoreParams WebGL2RenderingContextBase::getUnpackPixelStoreParams()
+{
+ WebGLImageConversion::PixelStoreParams params;
+ params.alignment = m_unpackAlignment;
+ params.rowLength = m_unpackRowLength;
+ params.imageHeight = m_unpackImageHeight;
+ params.skipPixels = m_unpackSkipPixels;
+ params.skipRows = m_unpackSkipRows;
+ params.skipImages = m_unpackSkipImages;
+ return params;
+}
+
} // namespace blink

Powered by Google App Engine
This is Rietveld 408576698