Using a canvas with a bitmap as a drawImage source does not work. |
||
Issue descriptionOS: Linux, probably others too What steps will reproduce the problem? (1) Load a bitmap to srcCanvas using srcContext.transferFromImageBitmap(image). (2) Draw srcCanvas on dstCanvas using dstContext.drawImage(srcCanvas, 0, 0). What is the expected output? The destination canvas must be a copy of the source canvas. What do you see instead? The destination canvas is empty.
,
Aug 23 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/08fd30c773f566dc38208615abb801911808e215 commit 08fd30c773f566dc38208615abb801911808e215 Author: junov <junov@chromium.org> Date: Tue Aug 23 01:07:30 2016 Ensure ImageBuffer is never used with ImageBitmapRenderingContext When an HTMLCanvasElement has an ImageBitmapRenderingContext, calling buffer() will return a buffer that is blank, which is not the desired result, and triggers the lazy creation of an persistent buffer that was never used. This change adds a DCHECK to catch improper uses, such ase the use case addressed by https://codereview.chromium.org/2267653005/ BUG= 639841 Review-Url: https://codereview.chromium.org/2262363002 Cr-Commit-Position: refs/heads/master@{#413614} [modify] https://crrev.com/08fd30c773f566dc38208615abb801911808e215/third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp
,
Aug 23 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/4d29ebec048d83aac139ec5edcbe22d107351b7b commit 4d29ebec048d83aac139ec5edcbe22d107351b7b Author: zakerinasab <zakerinasab@chromium.org> Date: Tue Aug 23 14:22:48 2016 Adding proper check for canvas type to HTMLCanvasElement::getSourceImageForCanvas() such that drawImage can correctly draw canvases with bitmap images. BUG= 639841 Review-Url: https://codereview.chromium.org/2267653005 Cr-Commit-Position: refs/heads/master@{#413731} [add] https://crrev.com/4d29ebec048d83aac139ec5edcbe22d107351b7b/third_party/WebKit/LayoutTests/fast/canvas/imagebitmap/transferFromImageBitmap-drawImage.html [modify] https://crrev.com/4d29ebec048d83aac139ec5edcbe22d107351b7b/third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp [modify] https://crrev.com/4d29ebec048d83aac139ec5edcbe22d107351b7b/third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.h [modify] https://crrev.com/4d29ebec048d83aac139ec5edcbe22d107351b7b/third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.h
,
Aug 23 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/061450ece090f8f8ad550cbe470dec03fbe5b487 commit 061450ece090f8f8ad550cbe470dec03fbe5b487 Author: xidachen <xidachen@chromium.org> Date: Tue Aug 23 14:54:02 2016 Revert of Resolving drawImage issue with canvases that contain bitmap images (patchset #3 id:60001 of https://codereview.chromium.org/2267653005/ ) Reason for revert: Causing this DCHECK: m_context->getContextType() != CanvasRenderingContext::ContextImageBitmap on this test: transferFromImageBitmap-drawImage.html Original issue's description: > Adding proper check for canvas type to > HTMLCanvasElement::getSourceImageForCanvas() such that > drawImage can correctly draw canvases with bitmap images. > > BUG= 639841 > > Committed: https://crrev.com/4d29ebec048d83aac139ec5edcbe22d107351b7b > Cr-Commit-Position: refs/heads/master@{#413731} TBR=junov@chromium.org,zakerinasab@chromium.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG= 639841 Review-Url: https://codereview.chromium.org/2269073002 Cr-Commit-Position: refs/heads/master@{#413737} [delete] https://crrev.com/9e2e0f5824975f43ad9374ea5e97100b77925fc1/third_party/WebKit/LayoutTests/fast/canvas/imagebitmap/transferFromImageBitmap-drawImage.html [modify] https://crrev.com/061450ece090f8f8ad550cbe470dec03fbe5b487/third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp [modify] https://crrev.com/061450ece090f8f8ad550cbe470dec03fbe5b487/third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.h [modify] https://crrev.com/061450ece090f8f8ad550cbe470dec03fbe5b487/third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.h
,
Aug 23 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/d161245684a7adab144318deec691ad6fdc6251e commit d161245684a7adab144318deec691ad6fdc6251e Author: zakerinasab <zakerinasab@chromium.org> Date: Tue Aug 23 20:44:11 2016 Adding proper check for canvas type to HTMLCanvasElement::getSourceImageForCanvas() such that drawImage can correctly draw canvases with bitmap images. BUG= 639841 Committed: https://crrev.com/4d29ebec048d83aac139ec5edcbe22d107351b7b Review-Url: https://codereview.chromium.org/2267653005 Cr-Original-Commit-Position: refs/heads/master@{#413731} Cr-Commit-Position: refs/heads/master@{#413828} [add] https://crrev.com/d161245684a7adab144318deec691ad6fdc6251e/third_party/WebKit/LayoutTests/fast/canvas/imagebitmap/transferFromImageBitmap-drawImage.html [modify] https://crrev.com/d161245684a7adab144318deec691ad6fdc6251e/third_party/WebKit/Source/core/html/HTMLCanvasElement.cpp [modify] https://crrev.com/d161245684a7adab144318deec691ad6fdc6251e/third_party/WebKit/Source/core/html/canvas/CanvasRenderingContext.h [modify] https://crrev.com/d161245684a7adab144318deec691ad6fdc6251e/third_party/WebKit/Source/modules/imagebitmap/ImageBitmapRenderingContext.h
,
Aug 24 2016
|
||
►
Sign in to add a comment |
||
Comment 1 by junov@chromium.org
, Aug 22 2016