Closed
Bug 1111836
Opened 10 years ago
Closed 9 years ago
Store ColorTransform values in 3 fields instead of 8
Categories
(Firefox Graveyard :: Shumway, defect)
Firefox Graveyard
Shumway
Tracking
(Not tracked)
RESOLVED
INCOMPLETE
People
(Reporter: till, Unassigned)
References
Details
I just realize that we could store colorTransforms in three (u)int32s: one uint32 for the offsets, two int32s for the channels, with red and green in the upper/lower bits of the one, and blue and alpha in those of the other. Given that we have quite a few of these around, that might be pretty nice.
Even if this scheme isn't worth implementing because of the retrieval costs for the offsets, we can at least go to 5 fields by combining the multipliers into one uint32.
Updated•10 years ago
|
Blocks: shumway-1.0
Updated•10 years ago
|
Comment 1•9 years ago
|
||
We can't do this in the ColorTransform class because you can have fractional offsets:
trace(new ColorTransform(0, 0, 0, 0, 1.5, 1.5, 1.5, 1.5))
traces: (redMultiplier=0, greenMultiplier=0, blueMultiplier=0, alphaMultiplier=0, redOffset=1.5, greenOffset=1.5, blueOffset=1.5, alphaOffset=1.5)
However:
a.transform.colorTransform = new ColorTransform(0, 0, 0, 0, 1.5, 1.5, 1.5, 1.5);
trace(a.transform.colorTransform);
traces: (redMultiplier=0, greenMultiplier=0, blueMultiplier=0, alphaMultiplier=0, redOffset=1, greenOffset=1, blueOffset=1, alphaOffset=1)
So, we can probably do this optimization in the remoting code.
Assignee | ||
Updated•9 years ago
|
Product: Firefox → Firefox Graveyard
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → INCOMPLETE
You need to log in
before you can comment on or make changes to this bug.
Description
•