Closed Bug 969580 Opened 10 years ago Closed 10 years ago

Cached images should be discarded when our Direct2D device dies

Categories

(Core :: Graphics: ImageLib, defect)

x86_64
Windows 8.1
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla30

People

(Reporter: bas.schouten, Assigned: bas.schouten)

Details

Attachments

(2 files)

When our Direct2D device dies we may still have VectorImages in the SurfaceCache that contain Drawables holding on to D2D drawtargets belonging to the old D2D device. In the future other images may also have drawables which hold on only to now invalid GPU memory. We should simply discard the entire surface cache in the event of a device malfunction.
Attachment #8372515 - Flags: review?(seth) → review+
Comment on attachment 8372516 [details] [diff] [review]
Part 2: Discard the entire SurfaceCache when Direct2D fails.

Review of attachment 8372516 [details] [diff] [review]:
-----------------------------------------------------------------

Looks like a good fix for this specific problem.

It seems like, in the long term, we are going to start accumulating more cases where we need to do this. Maybe in the future it'd make sense to make this an event that various subsystems could listen for.
Attachment #8372516 - Flags: review?(seth) → review+
https://hg.mozilla.org/mozilla-central/rev/ba45c5c19ce8
https://hg.mozilla.org/mozilla-central/rev/d08cf861ff7a
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla30
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: