DrawTargetD2D1::DrawSurface does not consider the case where the image is too large to create ID2D1Bitmap
Categories
(Core :: Graphics, defect)
Tracking
()
People
(Reporter: emk, Unassigned)
References
Details
See bug 1741767 comment 17 and onwards for details.
Comment 1•3 years ago
|
||
:Bas, :bobowen, can you comment to this bug?
Comment 2•3 years ago
|
||
(In reply to Sotaro Ikeda [:sotaro] from comment #1)
:Bas, :bobowen, can you comment to this bug?
I don't really have anything to add.
I don't know the reasons for the original assertion, but it was triggered by a test and found to be an existing issue.
Comment 3•3 years ago
|
||
This is just OptimizeSourceSurface. If it fails to upload, we just return the old DataSurface and everything works as intended. This gfxCriticalError should probably not be a critical error when it's just a size issue. The assertion is really just a side-affect of the fact we fire off a gfxCriticalError so we have some stuff in the logs.
Reporter | ||
Comment 4•3 years ago
|
||
I'm sorry I didn't make it clear enough. The actual assertion I hit is here:
https://searchfox.org/mozilla-central/rev/aecfc48870599adb0ffc077dd11e6e2d99820d38/gfx/2d/DrawTargetD2D1.cpp#245-247
We reach this code path because bitmap
is null because image->QueryInterface((ID2D1Bitmap**)...
fails because OptimizeSourceSurface
fallbacks to DataSurface
. I quoted only the last part in bug 1741767 comment 17.
So if I read the code comment and bug 1088235 correctly, some tests will fail on Windows 7 if the image is large enough. Thoughts?
Comment 5•3 years ago
|
||
(In reply to Masatoshi Kimura [:emk] from comment #4)
I'm sorry I didn't make it clear enough. The actual assertion I hit is here:
https://searchfox.org/mozilla-central/rev/aecfc48870599adb0ffc077dd11e6e2d99820d38/gfx/2d/DrawTargetD2D1.cpp#245-247We reach this code path because
bitmap
is null becauseimage->QueryInterface((ID2D1Bitmap**)...
fails becauseOptimizeSourceSurface
fallbacks toDataSurface
. I quoted only the last part in bug 1741767 comment 17.So if I read the code comment and bug 1088235 correctly, some tests will fail on Windows 7 if the image is large enough. Thoughts?
So this is specifically when the CreateImageBrush path is used -and- the thing being drawn needs the alpha channel to be ignored. Not sure when that situation occurs or if that gives issue on windows versions past Windows 7 other than the assertion firing.
Updated•3 years ago
|
Description
•