There is an unused rowBytes parameter being passed along.
BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1636873002 Review URL: https://codereview.chromium.org/1636873002
This commit is contained in:
parent
e8c34974c4
commit
ed828001da
@ -157,7 +157,7 @@ void HelloWorldWindow::draw(SkCanvas* canvas) {
|
||||
if (kRaster_DeviceType == fType) {
|
||||
// need to send the raster bits to the (gpu) window
|
||||
SkImage* snap = fSurface->newImageSnapshot();
|
||||
size_t rowBytes;
|
||||
size_t rowBytes = 0;
|
||||
SkImageInfo info;
|
||||
const void* pixels = snap->peekPixels(&info, &rowBytes);
|
||||
fRenderTarget->writePixels(0, 0, snap->width(), snap->height(),
|
||||
|
@ -268,7 +268,7 @@ bool GrContext::writeSurfacePixels(GrSurface* surface,
|
||||
}
|
||||
|
||||
GrGpu::WritePixelTempDrawInfo tempDrawInfo;
|
||||
if (!fGpu->getWritePixelsInfo(surface, width, height, rowBytes, srcConfig, &drawPreference,
|
||||
if (!fGpu->getWritePixelsInfo(surface, width, height, srcConfig, &drawPreference,
|
||||
&tempDrawInfo)) {
|
||||
return false;
|
||||
}
|
||||
|
@ -268,7 +268,7 @@ bool GrGpu::getReadPixelsInfo(GrSurface* srcSurface, int width, int height, size
|
||||
|
||||
return true;
|
||||
}
|
||||
bool GrGpu::getWritePixelsInfo(GrSurface* dstSurface, int width, int height, size_t rowBytes,
|
||||
bool GrGpu::getWritePixelsInfo(GrSurface* dstSurface, int width, int height,
|
||||
GrPixelConfig srcConfig, DrawPreference* drawPreference,
|
||||
WritePixelTempDrawInfo* tempDrawInfo) {
|
||||
SkASSERT(drawPreference);
|
||||
@ -289,7 +289,7 @@ bool GrGpu::getWritePixelsInfo(GrSurface* dstSurface, int width, int height, siz
|
||||
}
|
||||
}
|
||||
|
||||
if (!this->onGetWritePixelsInfo(dstSurface, width, height, rowBytes, srcConfig, drawPreference,
|
||||
if (!this->onGetWritePixelsInfo(dstSurface, width, height, srcConfig, drawPreference,
|
||||
tempDrawInfo)) {
|
||||
return false;
|
||||
}
|
||||
|
@ -220,7 +220,7 @@ public:
|
||||
* that would allow a successful transfer of the src pixels to the dst. The passed width,
|
||||
* height, and rowBytes, must be non-zero and already reflect clipping to the dst bounds.
|
||||
*/
|
||||
bool getWritePixelsInfo(GrSurface* dstSurface, int width, int height, size_t rowBytes,
|
||||
bool getWritePixelsInfo(GrSurface* dstSurface, int width, int height,
|
||||
GrPixelConfig srcConfig, DrawPreference*, WritePixelTempDrawInfo*);
|
||||
|
||||
/**
|
||||
@ -532,7 +532,7 @@ private:
|
||||
virtual bool onGetReadPixelsInfo(GrSurface* srcSurface, int readWidth, int readHeight,
|
||||
size_t rowBytes, GrPixelConfig readConfig, DrawPreference*,
|
||||
ReadPixelTempDrawInfo*) = 0;
|
||||
virtual bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height, size_t rowBytes,
|
||||
virtual bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height,
|
||||
GrPixelConfig srcConfig, DrawPreference*,
|
||||
WritePixelTempDrawInfo*) = 0;
|
||||
|
||||
|
@ -279,7 +279,7 @@ void GrSWMaskHelper::toTexture(GrTexture *texture) {
|
||||
desc.fWidth = fPixels.width();
|
||||
desc.fHeight = fPixels.height();
|
||||
desc.fConfig = texture->config();
|
||||
|
||||
|
||||
// First see if we should compress this texture before uploading.
|
||||
switch (fCompressionMode) {
|
||||
case kNone_CompressionMode:
|
||||
|
@ -296,7 +296,7 @@ public:
|
||||
GrPixelConfig readConfig, DrawPreference*,
|
||||
ReadPixelTempDrawInfo*) override { return false; }
|
||||
|
||||
bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height, size_t rowBytes,
|
||||
bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height,
|
||||
GrPixelConfig srcConfig, DrawPreference*,
|
||||
WritePixelTempDrawInfo*) override { return false; }
|
||||
|
||||
|
@ -659,7 +659,7 @@ GrRenderTarget* GrGLGpu::onWrapBackendRenderTarget(const GrBackendRenderTargetDe
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
bool GrGLGpu::onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height,
|
||||
size_t rowBytes, GrPixelConfig srcConfig,
|
||||
GrPixelConfig srcConfig,
|
||||
DrawPreference* drawPreference,
|
||||
WritePixelTempDrawInfo* tempDrawInfo) {
|
||||
if (kIndex_8_GrPixelConfig == srcConfig || GrPixelConfigIsCompressed(dstSurface->config())) {
|
||||
|
@ -64,7 +64,7 @@ public:
|
||||
ReadPixelTempDrawInfo*) override;
|
||||
|
||||
bool onGetWritePixelsInfo(GrSurface* dstSurface, int width, int height,
|
||||
size_t rowBytes, GrPixelConfig srcConfig, DrawPreference*,
|
||||
GrPixelConfig srcConfig, DrawPreference*,
|
||||
WritePixelTempDrawInfo*) override;
|
||||
|
||||
bool initCopySurfaceDstDesc(const GrSurface* src, GrSurfaceDesc* desc) const override;
|
||||
|
Loading…
Reference in New Issue
Block a user