Expose Skia scaler internals for use by downscale-during-decode

RESOLVED FIXED in mozilla38

Status

()

defect
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: seth, Assigned: seth)

Tracking

(Blocks 1 bug)

unspecified
mozilla38
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

Downscale-during-decode needs to work in a streaming fashion, which the public Skia scaler API (the one we use for high-quality scaling) doesn't support. To implement downscale-during-decode, we need to expose some internal features of the Skia scaler API.
Here's the patch. This patch shouldn't change any functionality; it just moves
internal Skia code that we need for downscale-during-decode into header files
and otherwise makes it public. Purely refactoring.
Attachment #8546979 - Flags: review?(tnikkel)
Comment on attachment 8546979 [details] [diff] [review]
Expose Skia scaler internals for use by downscale-during-decode

rubber stamp this. Jeff can do post landing review.
Attachment #8546979 - Flags: review?(tnikkel)
Attachment #8546979 - Flags: review?(jmuizelaar)
Attachment #8546979 - Flags: review+
sorry had to back this out for bustage like https://treeherder.mozilla.org/logviewer.html#?job_id=5344852&repo=mozilla-inbound
Flags: needinfo?(seth)
Attachment #8546979 - Flags: review?(jmuizelaar) → review+
Attachment #8546979 - Attachment is obsolete: true
Should be ready to go now. Pushed:

https://hg.mozilla.org/integration/mozilla-inbound/rev/e00afa8044c3
Flags: needinfo?(seth)
https://hg.mozilla.org/mozilla-central/rev/e00afa8044c3
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla38
Comment on attachment 8550071 [details] [diff] [review]
Expose Skia scaler internals for use by downscale-during-decode

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

::: gfx/2d/image_operations.h
@@ +183,5 @@
> +    return 0.0f;  // Outside of the window.
> +  if (x > -std::numeric_limits<float>::epsilon() &&
> +      x < std::numeric_limits<float>::epsilon())
> +    return 1.0f;  // Special case the discontinuity at the origin.
> +  float xpi = x * static_cast<float>(M_PI);

Missing #include "mozilla/Constants.h"
Depends on: 1125588
You need to log in before you can comment on or make changes to this bug.