Support tiled drawing of blob images in Gecko

RESOLVED FIXED in Firefox 57

Status

()

RESOLVED FIXED
a year ago
a year ago

People

(Reporter: jrmuizel, Assigned: jrmuizel)

Tracking

unspecified
mozilla57
Points:
---

Firefox Tracking Flags

(firefox57 fixed)

Details

Attachments

(1 attachment)

(Assignee)

Description

a year ago
We'll need this for having sane invalidation.
(Assignee)

Comment 1

a year ago
Created attachment 8897096 [details] [diff] [review]
Add Tiling support to Moz2DImageRenderer

This add support for tiling to Moz2DImageRenderer by storing the tiling information and then using DrawTargetTiled to do the drawing.
Assignee: nobody → jmuizelaar
Attachment #8897096 - Flags: review?(nical.bugzilla)
Comment on attachment 8897096 [details] [diff] [review]
Add Tiling support to Moz2DImageRenderer

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

::: gfx/webrender_bindings/src/bindings.rs
@@ +667,5 @@
>      let mut resources = ResourceUpdates::new();
>      resources.add_image(image_key,
>                          descriptor.into(),
>                          ImageData::new_blob_image(copied_bytes),
> +                        Some(128));

Is this for testing only or do you plan to tile all blob images (128 seems quite small)?
(Assignee)

Comment 3

a year ago
(In reply to Nicolas Silva [:nical] from comment #2)
> Comment on attachment 8897096 [details] [diff] [review]
> Add Tiling support to Moz2DImageRenderer
> 
> Review of attachment 8897096 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> ::: gfx/webrender_bindings/src/bindings.rs
> @@ +667,5 @@
> >      let mut resources = ResourceUpdates::new();
> >      resources.add_image(image_key,
> >                          descriptor.into(),
> >                          ImageData::new_blob_image(copied_bytes),
> > +                        Some(128));
> 
> Is this for testing only or do you plan to tile all blob images (128 seems
> quite small)?

Mostly it's an arbitrary choice for testing. That being said, since we're using a texture atlas in the end it's conceivable that small tile sizes might work well.
Sounds like a pref to me :)
Comment on attachment 8897096 [details] [diff] [review]
Add Tiling support to Moz2DImageRenderer

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

I guess we can adjust the tile size later. It'd be great if you added a pref for this as Milan suggested.
Attachment #8897096 - Flags: review?(nical.bugzilla) → review+

Comment 6

a year ago
Pushed by jmuizelaar@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/3e9b7e7116b7
Support tiled drawing of blob images in Gecko.

Comment 7

a year ago
bugherder
https://hg.mozilla.org/mozilla-central/rev/3e9b7e7116b7
Status: NEW → RESOLVED
Last Resolved: a year ago
status-firefox57: --- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla57
You need to log in before you can comment on or make changes to this bug.