Closed Bug 949819 Opened 6 years ago Closed 6 years ago

Move remaining ReadPixels and GetTexImage helpers out of GLContext

Categories

(Core :: Graphics, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla29

People

(Reporter: bjacob, Assigned: bjacob)

References

Details

(Whiteboard: [qa-])

Attachments

(1 file)

No description provided.
Attachment #8346962 - Flags: review?(jgilbert)
Comment on attachment 8346962 [details] [diff] [review]
remaining-readpixels-helpers

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

::: gfx/gl/GLReadTexImageHelper.cpp
@@ +219,5 @@
> +
> +    while (row != rowEnd) {
> +      row[0] ^= row[2];
> +      row[2] ^= row[0];
> +      row[0] ^= row[2];

Gross. This should definitely be std::swap.
Attachment #8346962 - Flags: review?(jgilbert) → review+
Ah, heh, yeah,  but I'm just moving code around here. But yes, I agree, the compiler knows better if we tell it we want to swap.

http://hg.mozilla.org/integration/mozilla-inbound/rev/8160a1833ea1
Assignee: nobody → bjacob
Target Milestone: --- → mozilla29
https://hg.mozilla.org/mozilla-central/rev/8160a1833ea1
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Whiteboard: [qa-]
You need to log in before you can comment on or make changes to this bug.